-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
Closed
Labels
0.kind: regressionSomething that worked before working no longerSomething that worked before working no longer6.topic: llvm/clangIssues related to llvmPackages, clangStdenv and relatedIssues related to llvmPackages, clangStdenv and related
Milestone
Description
Issue description
cc-wrapper's add-flags.sh sets NIX+CXXSTDLIB_COMPILE to an empty value. Because of this, fallback in cc-wrapper.sh doesn't work:
NIX_x86_64_unknown_linux_gnu_CFLAGS_COMPILE+=" ${NIX_x86_64_unknown_linux_gnu_CXXSTDLIB_COMPILE:--isystem /nix/store/rww78vdn2rkayrnqsjl8ib5iq2vfm3sw-gcc-6.4.0/include/c++/6.4.0 -isystem /nix/store/rww78vdn2rkayrnqsjl8ib5iq2vfm3sw-gcc-6.4.0/include/c++/6.4.0/x86_64-unknown-linux-gnu}"
Steps to reproduce
nixpkgs git:(master) ✗ nix-build -A clang
/nix/store/mwhqir1mj7l9n79amfq0gmwlw9pc6afh-clang-wrapper-4.0.1
nixpkgs git:(master) ✗ result/bin/clang++ -std=c++11 test.cpp
test.cpp:1:10: fatal error: 'iostream' file not found
#include <iostream>
^~~~~~~~~~
1 error generated.
Technical details
- Nixpkgs version: (run
nix-instantiate --eval '<nixpkgs>' -A lib.nixpkgsVersion) e458c44
cc @Ericson2314 . I'm unsure how to fix it -- we can use ${foo:-default} substitution for the fallback instead but it will then incorrectly handle empty case (when someone really wants us to not add those flags).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
0.kind: regressionSomething that worked before working no longerSomething that worked before working no longer6.topic: llvm/clangIssues related to llvmPackages, clangStdenv and relatedIssues related to llvmPackages, clangStdenv and related