Merge pull request #138320 from NixOS/backport-138305-to-release-21.05
[Backport release-21.05] cc-wrapper: Add support for -mthumb / -marm
This commit is contained in:
commit
dba5c42f73
@ -458,6 +458,9 @@ stdenv.mkDerivation {
|
|||||||
+ optionalString (targetPlatform ? gcc.mode) ''
|
+ optionalString (targetPlatform ? gcc.mode) ''
|
||||||
echo "-mmode=${targetPlatform.gcc.mode}" >> $out/nix-support/cc-cflags-before
|
echo "-mmode=${targetPlatform.gcc.mode}" >> $out/nix-support/cc-cflags-before
|
||||||
''
|
''
|
||||||
|
+ optionalString (targetPlatform ? gcc.thumb) ''
|
||||||
|
echo "-m${if targetPlatform.gcc.thumb then "thumb" else "arm"}" >> $out/nix-support/cc-cflags-before
|
||||||
|
''
|
||||||
+ optionalString (targetPlatform ? gcc.tune &&
|
+ optionalString (targetPlatform ? gcc.tune &&
|
||||||
isGccArchSupported targetPlatform.gcc.tune) ''
|
isGccArchSupported targetPlatform.gcc.tune) ''
|
||||||
echo "-mtune=${targetPlatform.gcc.tune}" >> $out/nix-support/cc-cflags-before
|
echo "-mtune=${targetPlatform.gcc.tune}" >> $out/nix-support/cc-cflags-before
|
||||||
|
Loading…
x
Reference in New Issue
Block a user