Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 705566 - sys-devel/llvm-9.0.1 on prefix - var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
Summary: sys-devel/llvm-9.0.1 on prefix - var/tmp/portage/sys-devel/llvm-9.0.1/work/ll...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-01-16 15:13 UTC by gerion
Modified: 2021-08-29 14:34 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,737.62 KB, text/plain)
2020-01-16 15:13 UTC, gerion
Details
environment (environment,157.90 KB, text/plain)
2020-01-16 15:14 UTC, gerion
Details

Note You need to log in before you can comment on or make changes to this bug.
Description gerion 2020-01-16 15:13:04 UTC
llvm-9.0.1 fails for me to build on prefix (Ubuntu host). For me it seems that llvm builds a tool llvm-tblgen that is incorrectly linked for prefix and tries to load libtinfo from the host system. My Gentoo version of libtinfo is 6. The Ubuntu version is 5:
```
% equery files ncurses | grep libtinfo      
/srv/scratch/entrup/gentoo/usr/lib64/libtinfo.so
/srv/scratch/entrup/gentoo/usr/lib64/libtinfo.so.6
/srv/scratch/entrup/gentoo/usr/lib64/libtinfo.so.6.1
/srv/scratch/entrup/gentoo/usr/lib64/libtinfot.so
/srv/scratch/entrup/gentoo/usr/lib64/libtinfot.so.6
/srv/scratch/entrup/gentoo/usr/lib64/libtinfot.so.6.1
/srv/scratch/entrup/gentoo/usr/lib64/libtinfotw.so
/srv/scratch/entrup/gentoo/usr/lib64/libtinfotw.so.6
/srv/scratch/entrup/gentoo/usr/lib64/libtinfotw.so.6.1
/srv/scratch/entrup/gentoo/usr/lib64/libtinfow.so
/srv/scratch/entrup/gentoo/usr/lib64/libtinfow.so.6
/srv/scratch/entrup/gentoo/usr/lib64/libtinfow.so.6.1
% dpkg -L libtinfo5              
/.
/lib
/lib/x86_64-linux-gnu
/lib/x86_64-linux-gnu/libtinfo.so.5.9
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/libtic.so.5.9
/usr/share
/usr/share/doc
/usr/share/doc/libtinfo5
/usr/share/doc/libtinfo5/FAQ
/usr/share/doc/libtinfo5/TODO.Debian
/usr/share/doc/libtinfo5/changelog.Debian.gz
/usr/share/doc/libtinfo5/copyright
/lib/x86_64-linux-gnu/libtinfo.so.5
/usr/lib/x86_64-linux-gnu/libtic.so.5
% ldd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen
	linux-vdso.so.1 (0x00007fff7f956000)
	libLLVMTableGen.so.9 => /proj/opt/llvm-9.0/lib/libLLVMTableGen.so.9 (0x00007f99da08c000)
	libpthread.so.0 => /srv/scratch/entrup/gentoo/lib64/libpthread.so.0 (0x00007f99da04d000)
	libLLVMSupport.so.9 => /proj/opt/llvm-9.0/lib/libLLVMSupport.so.9 (0x00007f99d9928000)
	libstdc++.so.6 => /srv/scratch/entrup/gentoo/usr/lib/gcc/x86_64-pc-linux-gnu/9.2.0/libstdc++.so.6 (0x00007f99d96b3000)
	libgcc_s.so.1 => /srv/scratch/entrup/gentoo/usr/lib/gcc/x86_64-pc-linux-gnu/9.2.0/libgcc_s.so.1 (0x00007f99d9699000)
	libc.so.6 => /srv/scratch/entrup/gentoo/lib64/libc.so.6 (0x00007f99d94c6000)
	/srv/scratch/entrup/gentoo/lib64/ld-linux-x86-64.so.2 (0x00007f99da685000)
	libz.so.1 => /srv/scratch/entrup/gentoo/usr/lib64/libz.so.1 (0x00007f99d94ac000)
	libdl.so.2 => /srv/scratch/entrup/gentoo/lib64/libdl.so.2 (0x00007f99d94a6000)
	libtinfo.so.5 => not found
	libLLVMDemangle.so.9 => /proj/opt/llvm-9.0/lib/libLLVMDemangle.so.9 (0x00007f99d9235000)
	libm.so.6 => /srv/scratch/entrup/gentoo/lib64/libm.so.6 (0x00007f99d90e8000)
```

This is the error part of the build log:
```
...
[462/2074] cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/lib/ToolDrivers/llvm-lib -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/lib/ToolDrivers/llvm-lib/Options.td -o lib/ToolDrivers/llvm-lib/Options.inc -d lib/ToolDrivers/llvm-lib/Options.inc.d
FAILED: lib/ToolDrivers/llvm-lib/Options.inc 
cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/lib/ToolDrivers/llvm-lib -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/lib/ToolDrivers/llvm-lib/Options.td -o lib/ToolDrivers/llvm-lib/Options.inc -d lib/ToolDrivers/llvm-lib/Options.inc.d
/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
[463/2074] cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-cvtres -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-cvtres/Opts.td -o tools/llvm-cvtres/Opts.inc -d tools/llvm-cvtres/Opts.inc.d
FAILED: tools/llvm-cvtres/Opts.inc 
cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-cvtres -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-cvtres/Opts.td -o tools/llvm-cvtres/Opts.inc -d tools/llvm-cvtres/Opts.inc.d
/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
[464/2074] cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-lipo -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-lipo/LipoOpts.td -o tools/llvm-lipo/LipoOpts.inc -d tools/llvm-lipo/LipoOpts.inc.d
FAILED: tools/llvm-lipo/LipoOpts.inc 
cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-lipo -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-lipo/LipoOpts.td -o tools/llvm-lipo/LipoOpts.inc -d tools/llvm-lipo/LipoOpts.inc.d
/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
[465/2074] cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-mt -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-mt/Opts.td -o tools/llvm-mt/Opts.inc -d tools/llvm-mt/Opts.inc.d
FAILED: tools/llvm-mt/Opts.inc 
cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-mt -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-mt/Opts.td -o tools/llvm-mt/Opts.inc -d tools/llvm-mt/Opts.inc.d
/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
[466/2074] cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-objcopy -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-objcopy/ObjcopyOpts.td -o tools/llvm-objcopy/ObjcopyOpts.inc -d tools/llvm-objcopy/ObjcopyOpts.inc.d
FAILED: tools/llvm-objcopy/ObjcopyOpts.inc 
cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-objcopy -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-objcopy/ObjcopyOpts.td -o tools/llvm-objcopy/ObjcopyOpts.inc -d tools/llvm-objcopy/ObjcopyOpts.inc.d
/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
[467/2074] cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-rc -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-rc/Opts.td -o tools/llvm-rc/Opts.inc -d tools/llvm-rc/Opts.inc.d
FAILED: tools/llvm-rc/Opts.inc 
cd /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64 && /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen -gen-opt-parser-defs -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-rc -I /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/include /srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm/tools/llvm-rc/Opts.td -o tools/llvm-rc/Opts.inc -d tools/llvm-rc/Opts.inc.d
/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64/bin/llvm-tblgen: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
ninja: build stopped: subcommand failed.
 * ERROR: sys-devel/llvm-9.0.1::gentoo failed (compile phase):
 *   ninja -v -j96 -l0 failed
 * 
 * Call stack:
 *     ebuild.sh, line  125:  Called src_compile
 *   environment, line 3807:  Called multilib-minimal_src_compile
 *   environment, line 2256:  Called multilib_foreach_abi 'multilib-minimal_abi_src_compile'
 *   environment, line 2500:  Called multibuild_foreach_variant '_multilib_multibuild_wrapper' 'multilib-minimal_abi_src_compile'
 *   environment, line 2191:  Called _multibuild_run '_multilib_multibuild_wrapper' 'multilib-minimal_abi_src_compile'
 *   environment, line 2189:  Called _multilib_multibuild_wrapper 'multilib-minimal_abi_src_compile'
 *   environment, line  688:  Called multilib-minimal_abi_src_compile
 *   environment, line 2250:  Called multilib_src_compile
 *   environment, line 2720:  Called cmake-utils_src_compile
 *   environment, line 1028:  Called cmake-utils_src_make
 *   environment, line 1209:  Called _cmake_ninja_src_make
 *   environment, line  518:  Called eninja
 *   environment, line 1514:  Called die
 * The specific snippet of code:
 *       "$@" || die "${nonfatal_args[@]}" "${*} failed"
 * 
 * If you need support, post the output of `emerge --info '=sys-devel/llvm-9.0.1::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=sys-devel/llvm-9.0.1::gentoo'`.
 * The complete build log is located at '/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/temp/build.log'.
 * The ebuild environment file is located at '/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/temp/environment'.
 * Working directory: '/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm-abi_x86_64.amd64'
 * S: '/srv/scratch/entrup/gentoo/var/tmp/portage/sys-devel/llvm-9.0.1/work/llvm'

>>> Failed to emerge sys-devel/llvm-9.0.1, Log file:
...
```

Reproducible: Always
Comment 1 gerion 2020-01-16 15:13:28 UTC
Created attachment 603452 [details]
build.log
Comment 2 gerion 2020-01-16 15:14:17 UTC
Created attachment 603454 [details]
environment
Comment 3 gerion 2020-02-12 12:27:45 UTC
The LLVM libraries found by the loader also looks wrong. The links to /proj/opt/llvm-9.0. This is a self compiled LLVM and only in my $PATH (the bin directory of the LLVM installation).
Maybe the wrong "llvm-config" is used?
Comment 4 Fabian Groffen gentoo-dev 2021-08-29 14:34:20 UTC
this is an old version, we'd have to revisit this