Andrew Childs
8b59d52ca3
cc-wrapper: use legacy -mmacosx-version-min for gcc
...
See https://github.com/NixOS/nixpkgs/pull/105026#discussion_r587169144
2021-04-11 09:47:10 +09:00
Andrew Childs
362cb82b75
cc-wrapper: specify default -mmacos-version-min
...
This avoids contamination via MACSOX_DEPLOYMENT_TARGET when cross
compiling.
2021-04-11 09:47:10 +09:00
John Ericson
6979a72840
Merge pull request #112449 from angerman/angerman/response-files
...
Add response file support when compiling with clang
2021-03-06 11:24:32 -05:00
Jan Tojnar
6d1958ad2d
Merge branch 'staging-next' into staging
2021-03-04 22:16:45 +01:00
s1341
aee60bef7a
android_prebuilt: Fix eval
2021-03-04 18:17:39 +00:00
Andrew Childs
fc0456bed1
cc-wrapper: set -arch on darwin
2021-03-02 17:21:08 +09:00
Walter Franzini
eabb56ac6c
identify musl32 using x86_32 instead of i686
2021-02-12 21:11:16 +01:00
Walter Franzini
87e35291a5
disable stackprotector on target platform musl32
2021-02-12 11:06:29 +01:00
Moritz Angermann
11b4d6c633
responsie file logic
2021-02-09 09:46:47 +08:00
Ben Siraphob
aa8868c7cc
pkgs/build-support: stdenv.lib -> lib
2021-01-24 19:07:54 -08:00
John Ericson
0710308402
clang, cc-wrapper: Move --gcc-toolchain
logic into CC wrapper
...
Take 2, after #94582 had to be reverted.
This reverts commit ac03cfa3c5
.
2021-01-24 15:49:32 -05:00
John Ericson
9c213398b3
lib: Clean up how linux and gcc config is specified
...
Second attempt of 8929989614589ee3acd070a6409b2b9700c92d65; see that
commit for details.
This reverts commit 0bc275e634
.
2021-01-23 10:01:28 -05:00
Jonathan Ringer
0bc275e634
Revert "lib: Clean up how linux and gcc config is specified"
...
This is a stdenv-rebuild, and should not be merged
into master
This reverts commit 8929989614
.
2021-01-22 14:07:06 -08:00
John Ericson
8929989614
lib: Clean up how linux and gcc config is specified
...
The `platform` field is pointless nesting: it's just stuff that happens
to be defined together, and that should be an implementation detail.
This instead makes `linux-kernel` and `gcc` top level fields in platform
configs. They join `rustc` there [all are optional], which was put there
and not in `platform` in anticipation of a change like this.
`linux-kernel.arch` in particular also becomes `linuxArch`, to match the
other `*Arch`es.
The next step after is this to combine the *specific* machines from
`lib.systems.platforms` with `lib.systems.examples`, keeping just the
"multiplatform" ones for defaulting.
2021-01-21 22:44:09 -05:00
Steven Pease
b766673c6f
Move disabling of gccForLibs for iOS to build-support cc-wrapper
2021-01-20 10:14:46 -08:00
John Ericson
fb875dcf6f
Merge pull request #107507 from LibreCybernetics/add-zen-info
...
lib.systems: update processor architecture info
2020-12-24 10:23:10 -05:00
Fabián Heredia Montiel
2a9ac172c1
lib.systems: update processor architecture info
2020-12-23 18:57:59 -06:00
Florian Klink
07c4056179
gnats: format hardened flag isn't supported
...
When invoking a simple Ada program with `gcc` from `gnats10`, the
following warnings are shown:
```
$ gcc -c conftest.adb
gnat1: warning: command-line option ‘-Wformat=1’ is valid for C/C++/ObjC/ObjC++ but not for Ada
gnat1: warning: command-line option ‘-Wformat-security’ is valid for C/C++/ObjC/ObjC++ but not for Ada
gnat1: warning: ‘-Werror=’ argument ‘-Werror=format-security’ is not valid for Ada
$ echo $?
0
```
This is only spammy when compiling Ada programs inside a Nix derivation,
but certain configure scripts (such as the ./configure script from the
gcc that's built by coreboot's `make crossgcc` command) fail entirely
when getting that warning output.
https://nixos.wiki/wiki/Coreboot currently suggests manually running
> NIX_HARDENING_ENABLE="${NIX_HARDENING_ENABLE/ format/}" make crossgcc
… but actually teaching the nixpkgs-provided cc wrapper that `format`
isn't supported as a hardening flag seems to be the more canonical way
to do this in nixpgks.
After this, Ada programs still compile:
```
$ gcc -c conftest.adb
$ echo $?
0
```
And the compiler output is empty.
2020-12-23 01:51:14 +01:00
Matthew Bauer
989b403c7f
Merge pull request #96318 from matthewbauer/provide-patchelf-in-native-stdenv
...
stdenv/native: provide patchelf on linux
2020-10-30 13:32:13 -05:00
Matthew Bauer
4830967736
Fix cc-wrapper in native stdenv
2020-08-26 14:36:26 -05:00
Frederik Rietdijk
d59c57f8a6
Merge pull request #92412 from matthewbauer/blas-cross
...
Blas/Lapack cross fixes
2020-08-15 08:55:57 +02:00
John Ericson
b5f7ed6846
Merge pull request #91293 from Ericson2314/cxx-wrapper-debt-part-2
...
treewide: Get rid of `cc.gcc`
2020-08-02 20:42:20 -04:00
John Ericson
92f96f47b0
treewide: Get rid of cc.gcc
...
Instead, we have a new `gccForLibs`, which has the appropriate
definition for e.g. avoiding `x86_32` linking problems.
2020-08-02 17:12:05 +00:00
Jörg Thalheim
96092dc936
stdenv: make -nostdinc work as intended
...
Right now we add glibc to search path also -nostdinc was provided,
which breaks projects providing their own gcc.
2020-07-23 08:39:46 +01:00
Matthew Bauer
f42aa7e1d7
cc-wrapper: set FC when langFortran is on
...
We need to set FC so that CMake and other tools can find the fortran
compiler. Also we need to limit the hardening flags since fortify and
format don’t work with fortran.
Fixes #88449
2020-07-06 00:22:19 -04:00
John Ericson
704daf7a6e
{bintools,cc}-wrapper: Ensure nix-support/*-flags files exist
...
This will unbreak firefox and a few other packages which try to grab
some of the libcxx flags.
2020-06-30 18:26:37 +00:00
John Ericson
1085403acd
{cc,bintools}-wrapper: Comments no longer spliced
...
This means we can freely keep the comments up to date without the
penalty of a mass rebuild.
2020-06-30 15:04:10 +00:00
John Ericson
f3f7612a40
C++ Compilers: Systematize handling of standard libraries
2020-06-22 04:24:44 +00:00
Vladimír Čunát
e88e14ec8d
Merge branch 'master' into staging-next
...
A few thousand rebuilds per platform have arrived in the meantime.
2020-09-11 14:24:13 +02:00
John Ericson
5fd27509cf
Merge pull request #97387 from Ericson2314/fix-android-prebuilt
...
cc-wrapper: Fix for prebuilt android
2020-09-08 20:24:50 -04:00
John Ericson
204dc3a88b
cc-wrapper: Fix for prebuilt android
...
We don't want to use Nix-built GCC's libs with prebuilt clang in this
case.
2020-09-07 15:08:11 -04:00
Frederik Rietdijk
5ceea5705a
Revert "utils.bash: also "fix" cc-wrapper and pkg-config-wrapper"
...
Follow up to the revert in e560459c5b
.
This reverts commit 1936b11f63
.
2020-09-07 16:31:59 +02:00
Frederik Rietdijk
1936b11f63
utils.bash: also "fix" cc-wrapper and pkg-config-wrapper
2020-09-07 07:19:26 +02:00
John Ericson
1965a241fc
Merge pull request #61019 from volth/gcc.arch-amd
...
platform.gcc.arch: support for AMD CPUs
2020-09-01 22:31:16 -04:00
volth
cf7b63df5b
gcc.arch: refactor, move tables under lib/
2020-08-05 11:18:26 +00:00
volth
463db72e63
platform.gcc.arch: support for AMD CPUs
2020-08-05 02:32:48 +00:00
Frederik Rietdijk
d578248611
Merge staging-next into staging
2020-05-24 10:10:06 +02:00
Stefan Frijters
fc9b93d2fc
gdc: init at 9.3.0
2020-05-19 23:06:52 +02:00
John Ericson
1ac5398589
*-wrapper; Switch from infixSalt
to suffixSalt
...
I hate the thing too even though I made it, and rather just get rid of
it. But we can't do that yet. In the meantime, this brings us more
inline with autoconf and will make it slightly easier for me to write a
pkg-config wrapper, which we need.
2020-05-12 00:44:44 -04:00
Lars Jellema
8e79583510
gnat: init at 9.3.0
2020-04-20 14:41:22 +02:00
John Ericson
204d710405
treewide: Get rid of -dumpmachine in favor of static info
2020-04-13 19:26:19 -04:00
John Ericson
19a0b38cbe
Merge pull request #82882 from obsidiansystems/armv6-embedded
...
Misc fixes for armv6 bare metal cross
2020-03-19 10:38:22 -04:00
John Ericson
bc054004ac
cc-wrapper, clang: libstdcxxHook
should a propagated build input
...
Lumping it in with the target platform libraries was incorrect, and
caused eval failures when gcc couldn't be built for the target platform.
2020-03-18 11:28:52 -04:00
Vladimír Čunát
1d9c10c8de
stdenv cc-wrapper: deal with edge-case regressions
...
Regression introduced in PR #81191 80729b6787
. The file does not exist
somewhere during bootstrap of pkgsStatic.busybox which is used in nix
(by default).
I tested the builds.
2020-03-10 11:09:26 +01:00
John Ericson
5c4dd08a03
Merge pull request #81191 from clkamp/stdenv-multi-line-libc-cflags
...
stdenv: Fix gcc multi line libc-cflags
2020-03-07 21:28:33 -05:00
Christian Lütke-Stetzkamp
80729b6787
stdenv: Fix gcc multi line libc-cflags
...
which broke at least libstdc++5.
Closes #79761
2020-03-06 10:34:57 +01:00
Ben Wolsieffer
e1831ebea3
gcc: move target-specific runtime libraries to separate output
2020-03-04 16:12:36 -05:00
John Ericson
cfd013813e
Merge pull request #74090 from obsidiansystems/ghcjs-cross-without-cc
...
stdenv, haskell: bonafied GHCJS cross compilation without stdenv.cc
2019-12-30 16:40:43 -08:00
Matthew Bauer
162a935d3c
Merge pull request #74226 from bhpdt/fix/idirafter-stdenv
...
stdenv: Fix gcc -idirafter shell glob in cc-wrapper
2019-12-02 13:41:28 -05:00
David Wood
4d26c18306
cc-wrapper: expose wrapper script as overridable attribute ( #65813 )
2019-11-27 14:15:56 -05:00