On 10/28/19 4:58 PM, Bruce Dubbs via blfs-support wrote:
On 10/28/19 4:15 PM, Trent via blfs-support wrote:

On 10/28/19 3:41 PM, Bruce Dubbs via blfs-support wrote:
On 10/28/19 3:02 PM, Trent via blfs-support wrote:

On 10/26/19 4:12 PM, Trent via blfs-support wrote:

So here is the referenced link on this.

http://www.linuxfromscratch.org/blfs/view/stable-systemd/general/llvm.html

I am building it from the recommendation for Mesa-19.1.4

The first time I ran the build, it did not give useful information. The second time it did give more information, but not useful enough for any searches I tried.

"g++: fatal error: Killed signal terminated program cc1plus" saying the compiler crashed?

Here is the output from second run.


[8/1352] Building CXX object tools/clang/lib/ASTMatch...CMakeFiles/clangDynamicASTMatchers.dir/Registry.cpp.o FAILED: tools/clang/lib/ASTMatchers/Dynamic/CMakeFiles/clangDynamicASTMatchers.dir/Registry.cpp.o /usr/bin/g++  -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Itools/clang/lib/ASTMatchers/Dynamic -I../tools/clang/lib/ASTMatchers/Dynamic -I../tools/clang/include -Itools/clang/include -I/usr/include/libxml2 -Iinclude -I../include -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-maybe-uninitialized -Wno-class-memaccess -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -fdiagnostics-color -ffunction-sections -fdata-sections -fno-common -Woverloaded-virtual -fno-strict-aliasing -O3 -DNDEBUG-fno-exceptions -MD -MT tools/clang/lib/ASTMatchers/Dynamic/CMakeFiles/clangDynamicASTMatchers.dir/Registry.cpp.o -MF tools/clang/lib/ASTMatchers/Dynamic/CMakeFiles/clangDynamicASTMatchers.dir/Registry.cpp.o.d -o tools/clang/lib/ASTMatchers/Dynamic/CMakeFiles/clangDynamicASTMatchers.dir/Registry.cpp.o -c ../tools/clang/lib/ASTMatchers/Dynamic/Registry.cpp
g++: fatal error: Killed signal terminated program cc1plus
compilation terminated.

[13/1352] Building CXX object tools/clang/lib/Sema/CMakeFiles/clangSema.dir/SemaExpr.cpp.o

ninja: build stopped: subcommand failed.



Trent





After some research, I was finally able to find the build log ( CMakeFiles/CMakeError.log)



Run Build Command(s):/usr/bin/ninja cmTC_4c78c && [1/2] Building CXX object CMakeFiles/cmTC_4c78c.dir/src.cxx.o
FAILED: CMakeFiles/cmTC_4c78c.dir/src.cxx.o
/usr/bin/g++    -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -Wextra -Wno-unused-parameter>
g++: error: unrecognized command line option '-Wthread-safety'
g++: error: unrecognized command line option '-Wthread-safety'
ninja: build stopped: subcommand failed.


Anyone know anything about this unrecognized command?

I'm not familiar with it but doing some searching it appears to be clang only. Are you exporting CC=gcc CXX=g++?  Tests probably shouldn't be run with those set.

  -- Bruce


I am doing as shown in the link ( http://www.linuxfromscratch.org/blfs/view/stable-systemd/general/llvm.html ):


=====================================================================

CC=gcc CXX=g++             \
cmake -DCMAKE_INSTALL_PREFIX=/usr                       \
       -DLLVM_ENABLE_FFI=ON                              \
       -DCMAKE_BUILD_TYPE=Release                        \
       -DLLVM_BUILD_LLVM_DYLIB=ON                        \
       -DLLVM_LINK_LLVM_DYLIB=ON \ -DLLVM_ENABLE_RTTI=ON \
       -DLLVM_TARGETS_TO_BUILD="host;AMDGPU;BPF"         \
       -DLLVM_BUILD_TESTS=ON                             \
       -Wno-dev -G Ninja .. &&
ninja

=====================================================================


Should I remove the DLLVM_BUILD_TESTS=ON, or set it to OFF?

You can do that, but it shouldn't be necessary.  My instruction is the same as above.  I have no reference to cmTC_ in my log.

  -- Bruce


It did not make any difference.

What about compiling Clang directly and changing to:


CC=clang CXX=clang++


Trent


--
http://lists.linuxfromscratch.org/listinfo/blfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Reply via email to