summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/termplotlib/gnuplot-subprocess.patch
diff options
context:
space:
mode:
authorMaximilian Bosch <maximilian@mbosch.me>2022-10-03 13:57:21 +0200
committerMaximilian Bosch <maximilian@mbosch.me>2023-03-29 09:50:25 +0200
commit019f605cd74e7476685195d3957f7066cff19e0a (patch)
tree1efb5407d61eb3e029f3ae29fcac3cbd79ceef77 /pkgs/development/python-modules/termplotlib/gnuplot-subprocess.patch
parentb2a1ac4e9935fd4eed863156c2e117496b12a4cc (diff)
gcc: exclude malformed `sys/mount.h` from fixed headers directory
Previously, builds such as `cmake` would fail with errors like this: In file included from /nix/store/injyphmxqgi028skp28fsmdvbdb57nvl-glibc-2.36-48-dev/include/linux/fs.h:19, from /build/cmake-3.24.2/Utilities/cmlibarchive/libarchive/archive_read_disk_posix.c:56: /nix/store/injyphmxqgi028skp28fsmdvbdb57nvl-glibc-2.36-48-dev/include/linux/mount.h:95:6: error: redeclaration of 'enum fsconfig_command' 95 | enum fsconfig_command { | ^~~~~~~~~~~~~~~~ The reason behind that is that the kernel exports `linux/mount.h` via kernel headers APIs that are also defined in `sys/mount.h` from glibc. To avoid clashes, safeguards were implemented in glibc to prevent this from happening[1][2]. However, these `#ifndef`-safeguards are removed by `fixincludes` during gcc's build and the (broken) result is subsequently copied into `include-fixed/sys/mount.h` which is added to each build via the cc-wrapper. To work around this, I decided to simply drop the file: it also exists in glibc's output and our gcc12 doesn't seem to expose this anymore anyways. [1] Commit bb1e8b0ca99b5cbedfae3e6245528a87d95ff3e2 [2] Commit 3bd3c612e98a53ce60ed972f5cd2b90628b3cba5
Diffstat (limited to 'pkgs/development/python-modules/termplotlib/gnuplot-subprocess.patch')
0 files changed, 0 insertions, 0 deletions