diff options
| author | Sergei Trofimovich <slyich@gmail.com> | 2023-01-10 07:43:51 +0000 |
|---|---|---|
| committer | Sergei Trofimovich <slyich@gmail.com> | 2023-01-10 07:54:13 +0000 |
| commit | 8c80bd08b7e39229947d55104d1871f5066437d9 (patch) | |
| tree | be008800957650eaa021f14021a00b5e1af2ec9d /pkgs/development/python-modules/python-mapnik/python-mapnik_std_optional.patch | |
| parent | 3f305fab725e14a7ee079441616c989168ad0970 (diff) | |
build-support/cc-wrapper: pass in non-existent --sysroot= to untangle from libc
I would like to add an extra `gcc` build step during linux bootstrap
(https://github.com/NixOS/nixpkgs/issues/208412). This makes it early
bootstrap compiler linked and targeted against `bootstrapTools` `glibc`
including it's headers.
Without this change `gcc`'s spec files always prefer `bootstrapTools` `glibc`
for header search path (passed in as --with-native-system-header-dir=). We'can't
override it with:
- `-I` option as it gets stacked before gcc-specific headers, we need to keep
glibc headers after gcc as gcc cleans namespace up for C standard by using
#include_next and by undefining system macros.
- `-idirafter` option as it gets appended after existing `glibc`-includes
This `--sysroot=/nix/store/does/not/exist` hack allows us to remove existing
`glibc` headers and add new ones with `-idirafter`.
We use `cc-cflags-before` instead of `libc-cflags` to allow user to define
their own `--sysroot=` (like `firefox` does).
To keep it working prerequisite cross-symlink in gcc.libs is required:
https://github.com/NixOS/nixpkgs/pull/209153
Diffstat (limited to 'pkgs/development/python-modules/python-mapnik/python-mapnik_std_optional.patch')
0 files changed, 0 insertions, 0 deletions
