problems building llvm

Issues related to applications and software problems
Post Reply
masber
Posts: 1
Joined: 2019/11/07 05:20:40

problems building llvm

Post by masber » 2019/11/07 05:25:55

Hi,

I am trying to build llvm on my centos 7

Code: Select all

[luffy@r640-1-12-mlx build]$ which cmake
/usr/local/bin/cmake
[luffy@r640-1-12-mlx build]$ cmake --version
cmake version 3.15.5

CMake suite maintained and supported by Kitware (kitware.com/cmake).
[luffy@r640-1-12-mlx build]$ which gcc
/usr/local/bin/gcc
[luffy@r640-1-12-mlx build]$ gcc --version
gcc (GCC) 9.2.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[luffy@r640-1-12-mlx build]$ which g++
/usr/local/bin/g++
[luffy@r640-1-12-mlx build]$ g++ --version
g++ (GCC) 9.2.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[luffy@r640-1-12-mlx build]$
[luffy@r640-1-12-mlx build]$ echo $CC
/usr/local/bin/gcc
[luffy@r640-1-12-mlx build]$ echo $CXX
/usr/local/bin/g++

[luffy@r640-1-12-mlx build]$ make -j 75
...
[ 25%] Copying clang's openmp_wrappers/__clang_openmp_math.h...
[ 25%] Copying clang's openmp_wrappers/cmath...
[ 25%] Building arm_neon.h...
[ 26%] Building arm_fp16.h...
[ 26%] Building arm_mve.h...
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by ../../../../bin/clang-tblgen)
make[2]: *** [tools/clang/lib/Headers/arm_neon.h] Error 1
make[2]: *** Waiting for unfinished jobs....
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by ../../../../bin/clang-tblgen)
make[2]: *** [tools/clang/lib/Headers/arm_fp16.h] Error 1
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by ../../../../bin/clang-tblgen)
../../../../bin/clang-tblgen: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by ../../../../bin/clang-tblgen)
make[2]: *** [tools/clang/lib/Headers/arm_mve.h] Error 1
make[1]: *** [tools/clang/lib/Headers/CMakeFiles/clang-resource-headers.dir/all] Error 2
[ 26%] Built target llvm-tblgen
make: *** [all] Error 2
What this error means and how to get it fixed so I can build my software?

thank you very much

User avatar
TrevorH
Site Admin
Posts: 33216
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: problems building llvm

Post by TrevorH » 2019/11/07 14:44:27

There are so many unsupported things in your post that I don't really know where to start. All of this lot is not from us and is unsupported:

/usr/local/bin/cmake
/usr/local/bin/gcc
/usr/local/bin/g++

If you want newer packages on CentOS 7 than the ones we ship in base/updates then look at the other repos like SCL.

Code: Select all

llvm-toolset-7.0-cmake.x86_64                                            3.6.2-11.el7                                    centos-sclo-rh
devtoolset-8-gcc.x86_64                                      8.3.1-3.1.el7                                               centos-sclo-rh
devtoolset-8-gcc-c++.x86_64                                  8.3.1-3.1.el7                                               centos-sclo-rh
We do not support random things you build yourself. If you do that then you are entirely on your own.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

chemal
Posts: 776
Joined: 2013/12/08 19:44:49

Re: problems building llvm

Post by chemal » 2019/11/07 15:54:54

To complement this: devtoolset-8 and cmake3 from epel build llvm on C7 just fine.

Post Reply