Skip to content
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

open64/osprey/targdir/targ_info/targ_si_gen Segmentation fault #21

Open
rice7th opened this issue Jun 17, 2023 · 52 comments
Open

open64/osprey/targdir/targ_info/targ_si_gen Segmentation fault #21

rice7th opened this issue Jun 17, 2023 · 52 comments
Labels
build faild failed to build open64

Comments

@rice7th
Copy link

rice7th commented Jun 17, 2023

As the title implies, I can't build Open64 because of targ_si_gen's segmentation fault

My OS is Void Linux x86_64. I am building with host, target and build as x86_64-pc-linux-gnu

@rice7th
Copy link
Author

rice7th commented Jun 17, 2023

Config command: ./configure --disable-multilib --enable-gnu3 --build x86_64-pc-linux-gnu --host x86_64-pc-linux-gnu --target x86_64-pc-linux-gnu

@shinmingliu
Copy link
Collaborator

I built open64 on ubuntu 20.04. To build, need to install the following:
cmake, bison, flex, g++-riscv64-linux-gnu, openjdk-9-jdk
get gradle to build Java front end:
wget https://services.gradle.org/distributions/gradle-6.5.1-bin.zip -P /tmp
unzip -d /opt/gradle /tmp/gradle-6.5.1-bin.zip
get llvm-14, detail skipped
define a few env. variables; create install location and build directory; configure
imageimage

Finally, inside ~/build directory, I do
make; make install

@rice7th
Copy link
Author

rice7th commented Jun 27, 2023

@shinmingliu That might be useful, but why exactly do you need g++ on riscv64?

@rice7th
Copy link
Author

rice7th commented Jun 27, 2023

Also tried on Arch Linux. No luck.

@rice7th
Copy link
Author

rice7th commented Jun 28, 2023

EDIT @shinmingliu I was dumb and put the wrong command. Today I tried it and it actually started building Open64!.. Until make: *** [Makefile:406: build] Error 2 Which is kind of a cryptic error. I am investigating right now but it seems a bit weird nonetheless

@Yvan-xy
Copy link
Member

Yvan-xy commented Jun 28, 2023

Could you please attach more details or log about your error output?

@Yvan-xy Yvan-xy added the build faild failed to build open64 label Jun 28, 2023
@rice7th
Copy link
Author

rice7th commented Jul 1, 2023

@Yvan-xy I am sorry but I am currently in vacation, and I have only my Void Linux laptop with me. The build however still fails at make: *** [Makefile:406: build] Error 2:

Making all in testsuite
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/testsuite'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/testsuite'
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
true "AR_FLAGS=rc" "CC_FOR_BUILD=gcc" "CC_FOR_TARGET=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/xgcc -B/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/ -B/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/bin/ -B/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/lib/ -isystem /home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/include -isystem /home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/sys-include" "CFLAGS=-O2 -O0 -g -DIs_True_On " "CXXFLAGS=-g -O2  -D_GNU_SOURCE" "CFLAGS_FOR_BUILD=-O0 -g -DIs_True_On" "CFLAGS_FOR_TARGET=-O2 -O0 -g -DIs_True_On " "INSTALL=/bin/install -c" "INSTALL_DATA=/bin/install -c -m 644" "INSTALL_PROGRAM=/bin/install -c" "INSTALL_SCRIPT=/bin/install -c" "LDFLAGS=" "LIBCFLAGS=-O2 -O0 -g -DIs_True_On " "LIBCFLAGS_FOR_TARGET=-O2 -O0 -g -DIs_True_On " "MAKE=make" "MAKEINFO=makeinfo --split-size=5000000 --split-size=5000000   " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "RUNTESTFLAGS=" "exec_prefix=/home/rice7th/git/local/open64-gcc-4.2.0" "infodir=/home/rice7th/git/local/open64-gcc-4.2.0/info" "libdir=/home/rice7th/git/local/open64-gcc-4.2.0/lib" "includedir=/home/rice7th/git/local/open64-gcc-4.2.0/include" "prefix=/home/rice7th/git/local/open64-gcc-4.2.0" "tooldir=/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu" "gxx_include_dir=/home/rice7th/git/local/open64-gcc-4.2.0/include/c++/4.2.0" "AR=ar" "AS=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/as" "LD=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld" "RANLIB=ranlib" "NM=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/nm" "NM_FOR_BUILD=" "NM_FOR_TARGET=nm" "DESTDIR=" "WERROR=" DO=all multi-do # make
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[5]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[4]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[3]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0'
make[2]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0'
make[1]: Leaving directory '/home/rice7th/git/build'
make: *** [Makefile:406: build] Error 2

Quick things about my file structure: git is the directory where I have all third party repos that I clone. It is also where I set $HOME according to @shinmingliu.

As such, the git folder looks like this:

.
├── build
├── local
└── open64

without however counting other repos in there too

@rice7th
Copy link
Author

rice7th commented Jul 1, 2023

Current system config:
OS: Void Linux (rolling release)
GCC: 12.2.0
CLANG:

clang version 15.0.7
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /bin

MAKE: Gnu Make 4.3
GNU LD: 2.39

if you need any other type of info just let me know!

@rice7th
Copy link
Author

rice7th commented Jul 1, 2023

Also, I am running make -j10 to speed up the build

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

please run make -j1 to get more specific error logs. Thx

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

@Yvan-xy OK. Here's the log:

C++    /home/rice7th/git/build/osprey/targdir/clang2whirl//home/rice7th/git/build/../open64/osprey/be/com/wn_verifier.cxx
C++    /home/rice7th/git/build/osprey/targdir/clang2whirl/../../../../open64/osprey/clang2whirl/c2w_builder.cxx
In file included from ../../../../open64/osprey/clang2whirl/c2w_builder.cxx:31:
../../../../open64/osprey/clang2whirl/c2w_builder.h:36:10: fatal error: llvm/Support/CommandLine.h: No such file or directory
   36 | #include "llvm/Support/CommandLine.h"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [/home/rice7th/git/build/../open64/osprey/linux/make/gcommonrules:149: c2w_builder.o] Error 1
make[3]: Leaving directory '/home/rice7th/git/build/osprey/targdir/clang2whirl'
make[2]: *** [../../../../open64/osprey/clang2whirl/Makefile.gbase:340: default] Error 2
make[2]: Leaving directory '/home/rice7th/git/build/osprey/targdir/clang2whirl'
make[1]: *** [Makefile:273: clangfe] Error 2
make[1]: Leaving directory '/home/rice7th/git/build'
make: *** [Makefile:406: build] Error 2

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

It seems that you didn't set the $CLANG_HOME in ENV. Pls run export CLANG_HOME="/path/to/llvm" and then rerun the configure and make command.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

I Did set clang home to what @shinmingliu said: $HOME/opt/x86_64. I also tried /usr/lib/clang/15.0.7 and /usr/lib/clang, but no luck:

make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/libsupc++'
Making all in libmath
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/libmath'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/libmath'
Making all in src
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/src'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/src'
Making all in po
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/po'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/po'
Making all in testsuite
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/testsuite'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/testsuite'
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
true "AR_FLAGS=rc" "CC_FOR_BUILD=gcc" "CC_FOR_TARGET=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/xgcc -B/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/ -B/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/bin/ -B/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/lib/ -isystem /home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/include -isystem /home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/sys-include" "CFLAGS=-O2 -O0 -g -DIs_True_On " "CXXFLAGS=-g -O2  -D_GNU_SOURCE" "CFLAGS_FOR_BUILD=-O0 -g -DIs_True_On" "CFLAGS_FOR_TARGET=-O2 -O0 -g -DIs_True_On " "INSTALL=/bin/install -c" "INSTALL_DATA=/bin/install -c -m 644" "INSTALL_PROGRAM=/bin/install -c" "INSTALL_SCRIPT=/bin/install -c" "LDFLAGS=" "LIBCFLAGS=-O2 -O0 -g -DIs_True_On " "LIBCFLAGS_FOR_TARGET=-O2 -O0 -g -DIs_True_On " "MAKE=make" "MAKEINFO=makeinfo --split-size=5000000 --split-size=5000000   " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "RUNTESTFLAGS=" "exec_prefix=/home/rice7th/git/local/open64-gcc-4.2.0" "infodir=/home/rice7th/git/local/open64-gcc-4.2.0/info" "libdir=/home/rice7th/git/local/open64-gcc-4.2.0/lib" "includedir=/home/rice7th/git/local/open64-gcc-4.2.0/include" "prefix=/home/rice7th/git/local/open64-gcc-4.2.0" "tooldir=/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu" "gxx_include_dir=/home/rice7th/git/local/open64-gcc-4.2.0/include/c++/4.2.0" "AR=ar" "AS=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/as" "LD=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld" "RANLIB=ranlib" "NM=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/nm" "NM_FOR_BUILD=" "NM_FOR_TARGET=nm" "DESTDIR=" "WERROR=" DO=all multi-do # make
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[5]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[4]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[3]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0'
make[2]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0'
make[1]: Leaving directory '/home/rice7th/git/build'
make: *** [Makefile:406: build] Error 2

Same problem as before

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

@Yvan-xy export CLANG_HOME=$HOME/opt/x86_64 is the one who got me the farthets

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

It should be LLVM path rather than /use/lib/clang. Sorry about the confusing variable name. I will refine it later. Please try again.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

I don't know where llvm lives actually... There is no /usr/lib/llvm somehow, even tho i have llvm 15 installed

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

It should be /usr/lib/llvm-xxx
Screen Shot 2023-07-02 at 18 02 48

Did you install it by running apt install llvm-15?

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

I am on Void Linux, not Ubuntu nor ubuntu based. Void uses the xbps package manager.

My install command was sudo xbps-install -S llvm and the latest version is 15 so yeah the installed version is indeed llvm 15.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Note that void is rolling release like arch

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

I am not familiar with this Linux release. I think maybe you can try to use find to search if LLVM is located somewhere.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

@Yvan-xy FOUND IT! Void installs LLVM in /usr/include/llvm, not /usr/lib/llvm

Unfortunately, even after setting LLVM_HOME and CLANG_HOME to the new directory, it still fails at the same Makefile:406 error

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

Can you found this file llvm/Support/CommandLine.h in /usr/include/llvm. Remember to clear your build directory and rerun configure and make

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Yes, /usr/include/llvm/Support/CommandLine.h Exists. I rerun the config every time. Now I'll try cleaning it too.

Do I need LLVM_HOME and CLANG_HOME to be the same?

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

yes, they should be the same. Thx

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

I Just realized GitHub issues are realtime lol

Anyways, it seems to be compiling right now. Even if this is a laptop with a Ryzen 5825U, it might take a while. I'll notify you when I am done!

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

non lol it failed again:

make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/src'
Making all in po
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/po'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/po'
Making all in testsuite
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/testsuite'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3/testsuite'
make[6]: Entering directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
true "AR_FLAGS=rc" "CC_FOR_BUILD=gcc" "CC_FOR_TARGET=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/xgcc -B/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/ -B/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/bin/ -B/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/lib/ -isystem /home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/include -isystem /home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu/sys-include" "CFLAGS=-O2 -O0 -g -DIs_True_On " "CXXFLAGS=-g -O2  -D_GNU_SOURCE" "CFLAGS_FOR_BUILD=-O0 -g -DIs_True_On" "CFLAGS_FOR_TARGET=-O2 -O0 -g -DIs_True_On " "INSTALL=/bin/install -c" "INSTALL_DATA=/bin/install -c -m 644" "INSTALL_PROGRAM=/bin/install -c" "INSTALL_SCRIPT=/bin/install -c" "LDFLAGS=" "LIBCFLAGS=-O2 -O0 -g -DIs_True_On " "LIBCFLAGS_FOR_TARGET=-O2 -O0 -g -DIs_True_On " "MAKE=make" "MAKEINFO=makeinfo --split-size=5000000 --split-size=5000000   " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "RUNTESTFLAGS=" "exec_prefix=/home/rice7th/git/local/open64-gcc-4.2.0" "infodir=/home/rice7th/git/local/open64-gcc-4.2.0/info" "libdir=/home/rice7th/git/local/open64-gcc-4.2.0/lib" "includedir=/home/rice7th/git/local/open64-gcc-4.2.0/include" "prefix=/home/rice7th/git/local/open64-gcc-4.2.0" "tooldir=/home/rice7th/git/local/open64-gcc-4.2.0/x86_64-linux-gnu" "gxx_include_dir=/home/rice7th/git/local/open64-gcc-4.2.0/include/c++/4.2.0" "AR=ar" "AS=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/as" "LD=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld" "RANLIB=ranlib" "NM=/home/rice7th/git/build/osprey-gcc-4.2.0/host-unknown/gcc/nm" "NM_FOR_BUILD=" "NM_FOR_TARGET=nm" "DESTDIR=" "WERROR=" DO=all multi-do # make
make[6]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[5]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[4]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0/x86_64-linux-gnu/libstdc++-v3'
make[3]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0'
make[2]: Leaving directory '/home/rice7th/git/build/osprey-gcc-4.2.0'
make[1]: Leaving directory '/home/rice7th/git/build'
make: *** [Makefile:406: build] Error 2

Same error, (again 😭 ) But at least now it took much longer to get there

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

please post the log of make -j1

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

This will take a long while

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

No, you don't have to delete the cache files. Just rerun make -j1 would not be so long

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Ok, so:

/bin/ld: (.text._ZNK4llvm24DwarfInstrProfCorrelatorIjE11getLocationERKNS_8DWARFDieE[_ZNK4llvm24DwarfInstrProfCorrelatorIjE11getLocationERKNS_8DWARFDieE]+0x229): undefined reference to `llvm::DWARFExpression::Operation::extract(llvm::DataExtractor, unsigned char, unsigned long, llvm::Optional<llvm::dwarf::DwarfFormat>)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMProfileData.a(InstrProfCorrelator.cpp.o): in function `llvm::DwarfInstrProfCorrelator<unsigned long>::isDIEOfProbe(llvm::DWARFDie const&)':
(.text._ZN4llvm24DwarfInstrProfCorrelatorImE12isDIEOfProbeERKNS_8DWARFDieE[_ZN4llvm24DwarfInstrProfCorrelatorImE12isDIEOfProbeERKNS_8DWARFDieE]+0x19): undefined reference to `llvm::DWARFDie::getParent() const'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorImE12isDIEOfProbeERKNS_8DWARFDieE[_ZN4llvm24DwarfInstrProfCorrelatorImE12isDIEOfProbeERKNS_8DWARFDieE]+0x5c): undefined reference to `llvm::DWARFDie::isSubprogramDIE() const'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorImE12isDIEOfProbeERKNS_8DWARFDieE[_ZN4llvm24DwarfInstrProfCorrelatorImE12isDIEOfProbeERKNS_8DWARFDieE]+0x80): undefined reference to `llvm::DWARFDie::getName(llvm::DINameKind) const'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMProfileData.a(InstrProfCorrelator.cpp.o): in function `llvm::DwarfInstrProfCorrelator<unsigned long>::getLocation(llvm::DWARFDie const&) const':
(.text._ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE[_ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE]+0x35): undefined reference to `llvm::DWARFDie::getLocations(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE[_ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE]+0x1b0): undefined reference to `llvm::DWARFExpression::Operation::extract(llvm::DataExtractor, unsigned char, unsigned long, llvm::Optional<llvm::dwarf::DwarfFormat>)'
/bin/ld: (.text._ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE[_ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE]+0x1e2): undefined reference to `llvm::DWARFUnit::getAddrOffsetSectionItem(unsigned int) const'
/bin/ld: (.text._ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE[_ZNK4llvm24DwarfInstrProfCorrelatorImE11getLocationERKNS_8DWARFDieE]+0x229): undefined reference to `llvm::DWARFExpression::Operation::extract(llvm::DataExtractor, unsigned char, unsigned long, llvm::Optional<llvm::dwarf::DwarfFormat>)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMProfileData.a(InstrProfCorrelator.cpp.o): in function `llvm::DwarfInstrProfCorrelator<unsigned int>::correlateProfileDataImpl()::{lambda(llvm::DWARFDie)#1}::operator()(llvm::DWARFDie) const':
(.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x99): undefined reference to `llvm::DWARFDie::getParent() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0xb9): undefined reference to `llvm::DWARFDie::find(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0xd9): undefined reference to `llvm::DWARFDie::getLastChild() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0xf1): undefined reference to `llvm::DWARFDie::getFirstChild() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x171): undefined reference to `llvm::DWARFDie::getSibling() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x25c): undefined reference to `llvm::DWARFDie::find(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x26c): undefined reference to `llvm::DWARFDie::find(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x298): undefined reference to `llvm::DWARFFormValue::getAsCString() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x433): undefined reference to `llvm::DWARFFormValue::getAsUnsignedConstant() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x464): undefined reference to `llvm::DWARFFormValue::getAsAddress() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x4bd): undefined reference to `llvm::DWARFFormValue::getAsCString() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x573): undefined reference to `llvm::DWARFFormValue::getAsUnsignedConstant() const'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMProfileData.a(InstrProfCorrelator.cpp.o): in function `llvm::DwarfInstrProfCorrelator<unsigned int>::correlateProfileDataImpl()':
(.text._ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv]+0x30): undefined reference to `llvm::DWARFContext::parseNormalUnits()'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv]+0x59): undefined reference to `llvm::DWARFUnit::extractDIEsIfNeeded(bool)'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv]+0x9d): undefined reference to `llvm::DWARFContext::parseDWOUnits(bool)'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorIjE24correlateProfileDataImplEv]+0xca): undefined reference to `llvm::DWARFUnit::extractDIEsIfNeeded(bool)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMProfileData.a(InstrProfCorrelator.cpp.o): in function `llvm::DwarfInstrProfCorrelator<unsigned long>::correlateProfileDataImpl()::{lambda(llvm::DWARFDie)#1}::operator()(llvm::DWARFDie) const':
(.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x99): undefined reference to `llvm::DWARFDie::getParent() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0xb9): undefined reference to `llvm::DWARFDie::find(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0xd9): undefined reference to `llvm::DWARFDie::getLastChild() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0xf1): undefined reference to `llvm::DWARFDie::getFirstChild() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x171): undefined reference to `llvm::DWARFDie::getSibling() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x25c): undefined reference to `llvm::DWARFDie::find(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x26c): undefined reference to `llvm::DWARFDie::find(llvm::dwarf::Attribute) const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x298): undefined reference to `llvm::DWARFFormValue::getAsCString() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x433): undefined reference to `llvm::DWARFFormValue::getAsUnsignedConstant() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x464): undefined reference to `llvm::DWARFFormValue::getAsAddress() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x4bd): undefined reference to `llvm::DWARFFormValue::getAsCString() const'
/bin/ld: (.text._ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_[_ZZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEvENKUlNS_8DWARFDieEE_clES2_]+0x573): undefined reference to `llvm::DWARFFormValue::getAsUnsignedConstant() const'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMProfileData.a(InstrProfCorrelator.cpp.o): in function `llvm::DwarfInstrProfCorrelator<unsigned long>::correlateProfileDataImpl()':
(.text._ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv]+0x30): undefined reference to `llvm::DWARFContext::parseNormalUnits()'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv]+0x59): undefined reference to `llvm::DWARFUnit::extractDIEsIfNeeded(bool)'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv]+0x9d): undefined reference to `llvm::DWARFContext::parseDWOUnits(bool)'
/bin/ld: (.text._ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv[_ZN4llvm24DwarfInstrProfCorrelatorImE24correlateProfileDataImplEv]+0xca): undefined reference to `llvm::DWARFUnit::extractDIEsIfNeeded(bool)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMCore.a(LLVMRemarkStreamer.cpp.o): in function `llvm::LLVMRemarkStreamer::emit(llvm::DiagnosticInfoOptimizationBase const&)':
(.text._ZN4llvm18LLVMRemarkStreamer4emitERKNS_30DiagnosticInfoOptimizationBaseE+0x46): undefined reference to `llvm::remarks::RemarkStreamer::matchesFilter(llvm::StringRef)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMCore.a(LLVMRemarkStreamer.cpp.o): in function `llvm::setupLLVMOptimizationRemarks(llvm::LLVMContext&, llvm::raw_ostream&, llvm::StringRef, llvm::StringRef, bool, llvm::Optional<unsigned long>)':
(.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextERNS_11raw_ostreamENS_9StringRefES4_bNS_8OptionalImEE+0x75): undefined reference to `llvm::remarks::parseFormat(llvm::StringRef)'
/bin/ld: (.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextERNS_11raw_ostreamENS_9StringRefES4_bNS_8OptionalImEE+0x16f): undefined reference to `llvm::remarks::createRemarkSerializer(llvm::remarks::Format, llvm::remarks::SerializerMode, llvm::raw_ostream&)'
/bin/ld: (.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextERNS_11raw_ostreamENS_9StringRefES4_bNS_8OptionalImEE+0x2b4): undefined reference to `llvm::remarks::RemarkStreamer::RemarkStreamer(std::unique_ptr<llvm::remarks::RemarkSerializer, std::default_delete<llvm::remarks::RemarkSerializer> >, llvm::Optional<llvm::StringRef>)'
/bin/ld: (.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextERNS_11raw_ostreamENS_9StringRefES4_bNS_8OptionalImEE+0x3a1): undefined reference to `llvm::remarks::RemarkStreamer::setFilter(llvm::StringRef)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMCore.a(LLVMRemarkStreamer.cpp.o): in function `llvm::setupLLVMOptimizationRemarks(llvm::LLVMContext&, llvm::StringRef, llvm::StringRef, llvm::StringRef, bool, llvm::Optional<unsigned long>)':
(.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextENS_9StringRefES2_S2_bNS_8OptionalImEE+0xed): undefined reference to `llvm::remarks::parseFormat(llvm::StringRef)'
/bin/ld: (.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextENS_9StringRefES2_S2_bNS_8OptionalImEE+0x306): undefined reference to `llvm::remarks::createRemarkSerializer(llvm::remarks::Format, llvm::remarks::SerializerMode, llvm::raw_ostream&)'
/bin/ld: (.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextENS_9StringRefES2_S2_bNS_8OptionalImEE+0x379): undefined reference to `llvm::remarks::RemarkStreamer::RemarkStreamer(std::unique_ptr<llvm::remarks::RemarkSerializer, std::default_delete<llvm::remarks::RemarkSerializer> >, llvm::Optional<llvm::StringRef>)'
/bin/ld: (.text._ZN4llvm28setupLLVMOptimizationRemarksERNS_11LLVMContextENS_9StringRefES2_S2_bNS_8OptionalImEE+0x580): undefined reference to `llvm::remarks::RemarkStreamer::setFilter(llvm::StringRef)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Compression.cpp.o): in function `llvm::compression::zlib::compress(llvm::ArrayRef<unsigned char>, llvm::SmallVectorImpl<unsigned char>&, int)':
(.text._ZN4llvm11compression4zlib8compressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEi+0x2c): undefined reference to `compressBound'
/bin/ld: (.text._ZN4llvm11compression4zlib8compressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEi+0x59): undefined reference to `compress2'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Compression.cpp.o): in function `llvm::compression::zlib::uncompress(llvm::ArrayRef<unsigned char>, unsigned char*, unsigned long&)':
(.text._ZN4llvm11compression4zlib10uncompressENS_8ArrayRefIhEEPhRm+0x2f): undefined reference to `uncompress'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Compression.cpp.o): in function `llvm::compression::zlib::uncompress(llvm::ArrayRef<unsigned char>, llvm::SmallVectorImpl<unsigned char>&, unsigned long)':
(.text._ZN4llvm11compression4zlib10uncompressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEm+0x57): undefined reference to `uncompress'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Compression.cpp.o): in function `llvm::compression::zstd::compress(llvm::ArrayRef<unsigned char>, llvm::SmallVectorImpl<unsigned char>&, int)':
(.text._ZN4llvm11compression4zstd8compressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEi+0x18): undefined reference to `ZSTD_compressBound'
/bin/ld: (.text._ZN4llvm11compression4zstd8compressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEi+0x41): undefined reference to `ZSTD_compress'
/bin/ld: (.text._ZN4llvm11compression4zstd8compressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEi+0x4c): undefined reference to `ZSTD_isError'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Compression.cpp.o): in function `llvm::compression::zstd::uncompress(llvm::ArrayRef<unsigned char>, unsigned char*, unsigned long&)':
(.text._ZN4llvm11compression4zstd10uncompressENS_8ArrayRefIhEEPhRm+0x2d): undefined reference to `ZSTD_decompress'
/bin/ld: (.text._ZN4llvm11compression4zstd10uncompressENS_8ArrayRefIhEEPhRm+0x3c): undefined reference to `ZSTD_isError'
/bin/ld: (.text._ZN4llvm11compression4zstd10uncompressENS_8ArrayRefIhEEPhRm+0x7f): undefined reference to `ZSTD_getErrorName'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Compression.cpp.o): in function `llvm::compression::zstd::uncompress(llvm::ArrayRef<unsigned char>, llvm::SmallVectorImpl<unsigned char>&, unsigned long)':
(.text._ZN4llvm11compression4zstd10uncompressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEm+0x54): undefined reference to `ZSTD_decompress'
/bin/ld: (.text._ZN4llvm11compression4zstd10uncompressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEm+0x5f): undefined reference to `ZSTD_isError'
/bin/ld: (.text._ZN4llvm11compression4zstd10uncompressENS_8ArrayRefIhEERNS_15SmallVectorImplIhEEm+0xb1): undefined reference to `ZSTD_getErrorName'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(CRC.cpp.o): in function `llvm::crc32(unsigned int, llvm::ArrayRef<unsigned char>)':
(.text._ZN4llvm5crc32EjNS_8ArrayRefIhEE+0x27): undefined reference to `crc32'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(CRC.cpp.o): in function `llvm::crc32(llvm::ArrayRef<unsigned char>)':
(.text._ZN4llvm5crc32ENS_8ArrayRefIhEE+0x27): undefined reference to `crc32'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(CRC.cpp.o): in function `llvm::JamCRC::update(llvm::ArrayRef<unsigned char>)':
(.text._ZN4llvm6JamCRC6updateENS_8ArrayRefIhEE+0x37): undefined reference to `crc32'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(ItaniumManglingCanonicalizer.cpp.o): in function `llvm::itanium_demangle::AbstractManglingParser<llvm::itanium_demangle::ManglingParser<(anonymous namespace)::CanonicalizerAllocator>, (anonymous namespace)::CanonicalizerAllocator>::parseName(llvm::itanium_demangle::AbstractManglingParser<llvm::itanium_demangle::ManglingParser<(anonymous namespace)::CanonicalizerAllocator>, (anonymous namespace)::CanonicalizerAllocator>::NameState*)':
(.text._ZN4llvm16itanium_demangle22AbstractManglingParserINS0_14ManglingParserIN12_GLOBAL__N_122CanonicalizerAllocatorEEES4_E9parseNameEPNS6_9NameStateE+0x166): undefined reference to `llvm::itanium_demangle::parse_discriminator(char const*, char const*)'
/bin/ld: (.text._ZN4llvm16itanium_demangle22AbstractManglingParserINS0_14ManglingParserIN12_GLOBAL__N_122CanonicalizerAllocatorEEES4_E9parseNameEPNS6_9NameStateE+0x4c9): undefined reference to `llvm::itanium_demangle::parse_discriminator(char const*, char const*)'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Process.cpp.o): in function `llvm::sys::Process::FileDescriptorHasColors(int)':
(.text._ZN4llvm3sys7Process23FileDescriptorHasColorsEi+0x5e): undefined reference to `set_curterm'
/bin/ld: (.text._ZN4llvm3sys7Process23FileDescriptorHasColorsEi+0x77): undefined reference to `setupterm'
/bin/ld: (.text._ZN4llvm3sys7Process23FileDescriptorHasColorsEi+0x98): undefined reference to `tigetnum'
/bin/ld: (.text._ZN4llvm3sys7Process23FileDescriptorHasColorsEi+0xa7): undefined reference to `set_curterm'
/bin/ld: (.text._ZN4llvm3sys7Process23FileDescriptorHasColorsEi+0xaf): undefined reference to `del_curterm'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Process.cpp.o): in function `llvm::sys::Process::StandardOutHasColors()':
(.text._ZN4llvm3sys7Process20StandardOutHasColorsEv+0x66): undefined reference to `set_curterm'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardOutHasColorsEv+0x82): undefined reference to `setupterm'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardOutHasColorsEv+0xa0): undefined reference to `tigetnum'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardOutHasColorsEv+0xaf): undefined reference to `set_curterm'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardOutHasColorsEv+0xb7): undefined reference to `del_curterm'
/bin/ld: /usr/lib64/gcc/x86_64-unknown-linux-gnu/12.2.0/../../../../lib64/libLLVMSupport.a(Process.cpp.o): in function `llvm::sys::Process::StandardErrHasColors()':
(.text._ZN4llvm3sys7Process20StandardErrHasColorsEv+0x66): undefined reference to `set_curterm'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardErrHasColorsEv+0x82): undefined reference to `setupterm'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardErrHasColorsEv+0xa0): undefined reference to `tigetnum'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardErrHasColorsEv+0xaf): undefined reference to `set_curterm'
/bin/ld: (.text._ZN4llvm3sys7Process20StandardErrHasColorsEv+0xb7): undefined reference to `del_curterm'
collect2: error: ld returned 1 exit status
make[3]: *** [../../../../open64/osprey/clang2whirl/Makefile.gbase:394: mapclang] Error 1
make[3]: Leaving directory '/home/rice7th/git/build/osprey/targdir/clang2whirl'
make[2]: *** [../../../../open64/osprey/clang2whirl/Makefile.gbase:340: default] Error 2
make[2]: Leaving directory '/home/rice7th/git/build/osprey/targdir/clang2whirl'
make[1]: *** [Makefile:273: clangfe] Error 2
make[1]: Leaving directory '/home/rice7th/git/build'
make: *** [Makefile:406: build] Error 2

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

I don't have LLD installed is that the issue?

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

it seems that libncurses-dev is required by llvm. I guess that you may need to install it. But the good news is that it starts to work now. Because this is a linkage error.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Oh.. well, let's see

Edit: They're both already installed

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

Do you have lib64tinfo6(terminfo) on your OS?
I found that these methods(setupterm, tigetnum) are related to terminfo and curses https://linux.die.net/man/3/set_curterm

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

No. I just installed ncurses-base (base terminfo files), wezterm-terminfo (my terminal's terminfo) and ncurses-libtinfo-devel and libs

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

Screen Shot 2023-07-02 at 19 51 23 Mines are here. Could you found it on your OS?

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Whoops that failed too

$ grep -R setupterm /usr/include/
/usr/include/ncurses.h:#define setterm(term)            setupterm(term, 1, (int *)0)
/usr/include/curses.h:#define setterm(term)             setupterm(term, 1, (int *)0)
/usr/include/term.h:extern NCURSES_EXPORT(int) setupterm (const char *,int,int *);

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

ok so somehow no ncursesw which I am not sure it is a great thing...

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

I have no idea why the linker can't find these functions. And I noticed that some functions of LLVM like(llvm::DWARFDie::find(llvm::dwarf::Attribute)' are also missing. Maybe the linker can't find the corresponding *.a or *.so correctly on your OS. I will check it later.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Yeah in the meantime I will open a reddit post on r/voidlinux about ncursesw and the missing llvm functions

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Here are all my commands:

export JAVA_HOME=/usr/lib/jvm/java-1.8-openjdk/
export HOME=`pwd`
export CLANG_HOME=/usr/lib/clang
export LLVM_HOME=/usr/include/llvm
export PATH=$CLANG_HOME/bin:$PATH
export PATH=$HOME/local/bin:$PATH
export PATH=$HOME/local/lib/gcc-lib/x86_64-open64-linux/5.0:$PATH
mkdir local build
cd build
../open64/configure --host=x86_64-linux-gnu --target=x86_64-linux-gnu --disable-fortran --with-build-product=OPEN64 --with-build-optimize=DEBUG --disable-multilib --prefix=$HOME/local

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Maybe the problem lies in CLANG_HOME, since there isn't really any bin in /usr/lib/clang

Or at least, there is a bin directory, just inside /usr/lib/clang/15.0.7

I'll try changing that

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

export CLANG_HOME=/usr/include/llvm

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

doesn't do anything. Already tried that

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

run llvm-config --libdir pls

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

/usr/lib

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

So the structure of libraries on void linux is totally different from Ubuntu. Maybe that's why the linker failed to find the corresponding libs

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

Well, what do I do now? I need to reconfigure the linker flags?

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

It's too difficult. The way easier way you can try is to compile and install llvm by yourself. However, The simplest way is to build Open64 in Ubuntu docker. 😂

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

oh my god

@Yvan-xy
Copy link
Member

Yvan-xy commented Jul 2, 2023

Maybe it is a good idea to add a Dockerfile to this Repo to avoid the complicated compilation process.

@rice7th
Copy link
Author

rice7th commented Jul 2, 2023

I would personally just let the user specify library paths

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build faild failed to build open64
Projects
None yet
Development

No branches or pull requests

3 participants