Merge pull request '`zig cc`: fix CPU model and features not being passed to the assembler' (#36383) from alexrp/zig:cc-asm-cpu-info into master
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/36383
2 files changed, 19 insertions(+), 0 deletions(-)
src
test
src/Compilation.zig+2
| ... | ... | @@ -6667,6 +6667,8 @@ pub fn addCCArgs( |
| 6667 | 6667 | |
| 6668 | 6668 | // Only compiled files support these flags. |
| 6669 | 6669 | switch (ext) { |
| 6670 | .assembly, |
| 6671 | .assembly_with_cpp, |
| 6670 | 6672 | .c, |
| 6671 | 6673 | .h, |
| 6672 | 6674 | .cpp, |
test/tests.zig+17
| ... | ... | @@ -455,6 +455,23 @@ const module_test_targets = blk: { |
| 455 | 455 | .abi = .none, |
| 456 | 456 | }, |
| 457 | 457 | }, |
| 458 | .{ |
| 459 | .target = .{ |
| 460 | .cpu_arch = .loongarch32, |
| 461 | .os_tag = .linux, |
| 462 | .abi = .gnu, |
| 463 | }, |
| 464 | .link_libc = true, |
| 465 | }, |
| 466 | .{ |
| 467 | .target = .{ |
| 468 | .cpu_arch = .loongarch32, |
| 469 | .os_tag = .linux, |
| 470 | .abi = .gnusf, |
| 471 | }, |
| 472 | .link_libc = true, |
| 473 | .extra_target = true, |
| 474 | }, |
| 458 | 475 | |
| 459 | 476 | .{ |
| 460 | 477 | .target = .{ |