···
···
13
-
# *NOT* from LLVM 9!
14
+
# *NOT* from LLVM 13!
# The compiler used to compile Cling may affect the runtime include and lib
# directories it expects to be run with. Cling builds against (a fork of) Clang,
# so we prefer to use Clang as the compiler as well for consistency.
···
134
-
# Runtime flags for the C++ standard library
136
-
if useLLVMLibcxx then
139
-
"${lib.getDev llvmPackages_13.libcxx}/include/c++/v1"
141
-
"${llvmPackages_13.libcxx}/lib"
143
-
"${llvmPackages_13.libcxx}/lib/libc++${stdenv.hostPlatform.extensions.sharedLibrary}"
148
-
"${gcc-unwrapped}/include/c++/${gcc-unwrapped.version}"
150
-
"${gcc-unwrapped}/include/c++/${gcc-unwrapped.version}/${stdenv.hostPlatform.config}"
# The flags passed to the wrapped cling should
# a) prevent it from searching for system include files and libs, and
# b) provide it with the include files and libs it needs (C and C++ standard library plus
···
"${lib.getLib unwrapped}/lib/clang/${llvmPackages_13.clang.version}/include"
157
+
++ lib.optionals useLLVMLibcxx [
159
+
"${lib.getDev llvmPackages_13.libcxx}/include/c++/v1"
161
+
"${llvmPackages_13.libcxx}/lib"
163
+
"${llvmPackages_13.libcxx}/lib/libc++${stdenv.hostPlatform.extensions.sharedLibrary}"
165
+
++ lib.optionals (!useLLVMLibcxx) [
167
+
"${gcc-unwrapped}/include/c++/${gcc-unwrapped.version}"
169
+
"${gcc-unwrapped}/include/c++/${gcc-unwrapped.version}/${stdenv.hostPlatform.config}"
172
+
# System libc on Linux
173
+
# On Darwin, this is an empty directory, so we need a separate include with
174
+
# apple-sdk (see below)
"${lib.getDev stdenv.cc.libc}/include"
"${lib.getDev unwrapped}/include"
182
+
++ lib.optionals stdenv.hostPlatform.isDarwin [
183
+
# On Darwin, we need the system includes
185
+
"${apple-sdk}/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include"