-
Notifications
You must be signed in to change notification settings - Fork 12.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'__config_site' file not found #57104
Comments
this still isn't fixed in 15.0.2? |
I see this problem when running lldb tests from the test suite on a linux system. Copying __config_site into the main include dir helps getting everything to work (Horrible workaround, but indicates this is the only problem affecting the system). |
I think this is a Clang problem -- the Clang driver for that target isn't looking into the right directory. @petrhosek Any clue about this? Shouldn't the driver for all targets now be looking into the per-target include dir? |
Clang should add that include path automatically, see llvm-project/clang/lib/Driver/ToolChains/Gnu.cpp Lines 3073 to 3076 in 13b8362
I think the issue here is the triple. You pass I'd also point out that you're only building the 32-bit ARM backend because you pass I'm not sure what's the right behavior in this case, maybe Clang should complain that the |
Same issue, when I only pass --target=arm-linux-gnueabihf without -march and -cpu. The /usr/local/include/arm-linux-gnueabihf/c++/v1 is not in the search path. /usr/local/bin/clang++ --target=arm-linux-gnueabihf -D_FILE_OFFSET_BITS=64 -v -stdlib=libc++ -fcolor-diagnostics -Wall -Wpedantic -Werror -Wconversion -std=gnu++20 -MD -MT homenet/test/helloworld/CMakeFiles/helloworld.dir/main.cpp.o -MF homenet/test/helloworld/CMakeFiles/helloworld.dir/main.cpp.o.d -o homenet/test/helloworld/CMakeFiles/helloworld.dir/main.cpp.o -c /home/airion/projects/homenet/myhomenet/homenet/test/helloworld/main.cpp |
Also having with problem, with LLVM 16 dev and Fedora Rawhide on x86_x64-linux-gnu I built from source using: $ cmake -S llvm -B build -G Ninja \
-DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" \
-DLLVM_ENABLE_RUNTIMES="compiler-rt;libcxx;libcxxabi" \
-DLLVM_USE_LINKER=mold \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=clang \
-DCMAKE_CXX_COMPILER=clang++
$ cd build
$ cmake --build . --target install |
With setting -DLLVM_RUNTIME_TARGETS="arm-unknown-linux-gnueabihf" it has finally worked! :-) Here the unknown is important! The __config_site file is then created in /usr/local/include/arm-unknown-linux-gnueabihf/c++/v1 and is later on found when compiling a program with --target=arm-unknown-linux-gnueabihf. |
Yes, normalizing triples in |
issue with __config_site still open llvm/llvm-project#57104
This might fix the issue that ninja failed to find __config_site See: llvm/llvm-project#57104 (comment)
I was also seeing this issue when running The following patch fixed the issue for me:
I don't know if this is the right way to fix this, but there are some mismatches regarding
|
I'm running into this trying to build a release artifact for 14.0.6 on a Redhat-8.4 machine. Anyone have a suggested work around?
|
I cannot reproduce this on a Rocky 8.8 machine (as I don't have access to old versions such as 8.4), but for me it errors in a different place:
That said, you will have to investigate where |
I don't know how or why I was able to build the artifact but by only installing the following from a clean RHEL-8.4 VM I was able to build an artifact
|
Adding
|
@llvm/issue-subscribers-clang-driver |
I've got |
If you specify a Question is, why is the source build of LLVM result in the |
Using a self-build clang 14.0.6, setup for cross compiling for arm-linux-gnueabihf, leads to the compilation error:
/usr/local/bin/../include/c++/v1/__config:13:10: fatal error: '__config_site' file not found
I build clang 14.0.6 by:
When I use
-I/usr/local/include/arm-linux-gnueabihf/c++/v1
the compilation works, however I would expect that clang could find that target non-agnostic file without explicitly setting the include directory, by using the value of the-target
option.CXXFLAGS
is set to--target=arm-linux-gnueabihf -march=armv8-a -mcpu=cortex-a72 -mfpu=neon-fp-armv8 -mfloat-abi=hard -stdlib=libc++
.Here the full verbose compilation output, which fails:
The text was updated successfully, but these errors were encountered: