On 1/8/2020 9:37 PM, Bruce Dubbs via blfs-support wrote:
On 1/8/20 8:54 PM, Alan Feuerbacher via blfs-support wrote:
After running into problems building doxygen, I tracked the basic problem down to the library file libLLVM-9.so being missing from /usr/lib .

I built stable systemd LLVM-8.0.1, and the corresponding library file /usr/lib/libLLVM-8.so was there.

Some internet searching indicates that libLLVM-9.so should be in /usr/lib . Any ideas what's going on?

First, there is no difference in llvm between the systemd and sysV versions of the book.

Mor specifically, it looks like you did not complete the llvm-9 installation.  What you should have, if you built both llvm8 and llvm9:

lrwxrwxrwx 1 root root       12 Dec 22 15:36 /usr/lib/libLLVM.so ->
libLLVM-9.so
-rwxr-xr-x 1 root root 57900736 Aug 16 12:42 /usr/lib/libLLVM-8.so
lrwxrwxrwx 1 root root       12 Aug 16 12:46 /usr/lib/libLLVM-8.0.1.so -> libLLVM-8.so
-rwxr-xr-x 1 root root 64059400 Dec 22 15:32 /usr/lib/libLLVM-9.so
lrwxrwxrwx 1 root root       12 Dec 22 15:36 /usr/lib/libLLVM-9.0.1.so -> libLLVM-9.so

  -- Bruce

Now this is downright weird! I rebuilt LLVM-9 several times, with
different
combinations of building non-shared libraries (the default from the
BLFS
book) and shared libraries. I also built LLVM-8 to see what I would
get. I never installed them during testing. Here are the results:

# Where libLLVM-9.so did not show up:
(lfs chroot) root:/sources/llvm-9.0.1.src/build/lib# ll libLLVM*
lrwxrwxrwx 1 root root      27 Jan  8 17:20 libLLVMAMDGPUAsmParser.so
-> libLLVMAMDGPUAsmParser.so.9
-rwxr-xr-x 1 root root 1808448 Jan  8 17:20 libLLVMAMDGPUAsmParser.so.9

# LLVM-8:
(lfs chroot) root:/sources/llvm-8.0.1.src/build/lib# ll libLLVM*
-rwxr-xr-x 1 root root 57944080 Jan  8 19:20 libLLVM-8.so
-rw-r--r-- 1 root root  1014160 Jan  8 19:05 libLLVMAMDGPUAsmParser.a
-rw-r--r-- 1 root root   333624 Jan  8 19:05 libLLVMAMDGPUAsmPrinter.a

# Today, where LLVM-9 created libLLVM-9.so:
(lfs chroot) root:/sources/llvm-9.0.1.src/build# ll /usr/lib/libLLVM*
lrwxrwxrwx 1 root root       12 Jan  9 08:06 /usr/lib/libLLVM-9.0.1.so
-> libLLVM-9.so
-rwxr-xr-x 1 root root 64084200 Jan  9 04:06 /usr/lib/libLLVM-9.so
lrwxrwxrwx 1 root root       12 Jan  9 08:06 /usr/lib/libLLVM.so ->
libLLVM-9.so
-rw-r--r-- 1 root root  2084696 Jan  9 03:48
/usr/lib/libLLVMAMDGPUAsmParser.a
lrwxrwxrwx 1 root root       27 Jan  8 18:16
/usr/lib/libLLVMAMDGPUAsmParser.so -> libLLVMAMDGPUAsmParser.so.9

I have no clue what happened, other than perhaps evil magic gremlins.

So now back to the original problem where testing doxygen-1.8.17 fails:

#########
. . .
#[100%] Built target doxygen
#Scanning dependencies of target tests
#[100%] Running doxygen tests...
#1..86
#Error: failed to run /sources/doxygen-1.8.17/build/bin/doxygen on
/sources/doxygen-1.8.17/build/testing/test_output_001/Doxyfile
#make[3]: *** [testing/CMakeFiles/tests.dir/build.make:58:
testing/CMakeFiles/tests] Error 1
#make[2]: *** [CMakeFiles/Makefile2:838:
testing/CMakeFiles/tests.dir/all] Error 2
#make[1]: *** [CMakeFiles/Makefile2:845:
testing/CMakeFiles/tests.dir/rule] Error 2
#make: *** [Makefile:418: tests] Error 2
#########

Then I ran the command that failed:

###########
(lfs chroot) root:/sources/doxygen-1.8.17/build# /sources/doxygen-
1.8.17/build/bin/doxygen /sources/doxygen-
1.8.17/build/testing/test_output_001/Doxyfile
: CommandLine Error: Option 'help-list' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options

(lfs chroot) root:/sources/doxygen-1.8.17/build# ldd /sources/doxygen-
1.8.17/build/bin/doxygen
        linux-vdso.so.1 (0x00007fffaf5f5000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x00007f1d491c4000)
        libclang.so.9 => /usr/lib/libclang.so.9 (0x00007f1d47a20000)
        libLLVM-9.so => /usr/lib/libLLVM-9.so (0x00007f1d4443d000)
        libz.so.1 => /lib/libz.so.1 (0x00007f1d44420000)
        librt.so.1 => /lib/librt.so.1 (0x00007f1d44416000)
        libdl.so.2 => /lib/libdl.so.2 (0x00007f1d44411000)
        libncursesw.so.6 => /lib/libncursesw.so.6 (0x00007f1d443a0000)
        libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f1d441c0000)
        libm.so.6 => /lib/libm.so.6 (0x00007f1d4407b000)
        libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007f1d44061000)
        libc.so.6 => /lib/libc.so.6 (0x00007f1d43e9d000)
        /lib64/ld-linux-x86-64.so.2 (0x00007f1d491f3000)
        libffi.so.7 =>/usr/lib/../lib/libffi.so.7 (0x00007f1d43e90000)
        libxml2.so.2 =>/usr/lib/../lib/libxml2.so.2
(0x00007f1d43d28000)
        libicui18n.so.65 =>/usr/lib/../lib/libicui18n.so.65
(0x00007f1d43a1e000)
        libicuuc.so.65 =>/usr/lib/../lib/libicuuc.so.65
(0x00007f1d4382f000)
        libicudata.so.65 =>/usr/lib/../lib/libicudata.so.65
(0x00007f1d41d7e000)
        liblzma.so.5 => /lib/liblzma.so.5 (0x00007f1d41d56000)
###########

Then I installed doxygen:

#########
. . .
[100%] Built target doxmlparser_test
Install the project...
-- Install configuration: "Release"
-- Installing: /usr/bin/doxygen
#########

Then I tested the installed /usr/bin/doxygen:

#########
(lfs chroot) root:/sources/doxygen-1.8.17/build# which doxygen
/usr/bin/doxygen
(lfs chroot) root:/sources/doxygen-1.8.17/build# doxygen --version
: CommandLine Error: Option 'help-list' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options
#########

There's the same error as in testing.

Check doxygen with ldd:

#########
(lfs chroot) root:/sources/doxygen-1.8.17/build# ldd /usr/bin/doxygen
        linux-vdso.so.1 (0x00007ffff99b5000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x00007f8772e02000)
        libclang.so.9 => /usr/lib/libclang.so.9 (0x00007f877165e000)
        libLLVM-9.so => /usr/lib/libLLVM-9.so (0x00007f876e07b000)
        libz.so.1 => /lib/libz.so.1 (0x00007f876e05e000)
        librt.so.1 => /lib/librt.so.1 (0x00007f876e054000)
        libdl.so.2 => /lib/libdl.so.2 (0x00007f876e04f000)
        libncursesw.so.6 => /lib/libncursesw.so.6 (0x00007f876dfde000)
        libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f876ddfe000)
        libm.so.6 => /lib/libm.so.6 (0x00007f876dcb9000)
        libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007f876dc9f000)
        libc.so.6 => /lib/libc.so.6 (0x00007f876dadb000)
        /lib64/ld-linux-x86-64.so.2 (0x00007f8772e31000)
        libffi.so.7 =>/usr/lib/../lib/libffi.so.7 (0x00007f876dace000)
        libxml2.so.2 =>/usr/lib/../lib/libxml2.so.2
(0x00007f876d966000)
        libicui18n.so.65 =>/usr/lib/../lib/libicui18n.so.65
(0x00007f876d65c000)
        libicuuc.so.65 =>/usr/lib/../lib/libicuuc.so.65
(0x00007f876d46d000)
        libicudata.so.65 =>/usr/lib/../lib/libicudata.so.65
(0x00007f876b9bc000)
        liblzma.so.5 => /lib/liblzma.so.5 (0x00007f876b994000)
#########

Similarly check a program in LLVM:

#########
(lfs chroot) root:/sources/doxygen-1.8.17/build# which bugpoint
/usr/bin/bugpoint
(lfs chroot) root:/sources/doxygen-1.8.17/build# ldd /usr/bin/bugpoint
        linux-vdso.so.1 (0x00007ffe8b6fa000)
        libLLVM-9.so =>/usr/bin/../lib/libLLVM-9.so
(0x00007f9b26d86000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x00007f9b26d59000)
        libstdc++.so.6 =>/usr/bin/../lib/libstdc++.so.6
(0x00007f9b26b79000)
        libm.so.6 => /lib/libm.so.6 (0x00007f9b26a34000)
        libgcc_s.so.1 =>/usr/bin/../lib/libgcc_s.so.1
(0x00007f9b26a1a000)
        libc.so.6 => /lib/libc.so.6 (0x00007f9b26856000)
        libffi.so.7 =>/usr/bin/../lib/../lib/libffi.so.7
(0x00007f9b26847000)
        libz.so.1 => /lib/libz.so.1 (0x00007f9b2682a000)
        librt.so.1 => /lib/librt.so.1 (0x00007f9b26820000)
        libdl.so.2 => /lib/libdl.so.2 (0x00007f9b2681b000)
        libncursesw.so.6 => /lib/libncursesw.so.6 (0x00007f9b267ac000)
        libxml2.so.2 =>/usr/bin/../lib/../lib/libxml2.so.2
(0x00007f9b26646000)
        /lib64/ld-linux-x86-64.so.2 (0x00007f9b2a36b000)
        libicui18n.so.65 =>/usr/bin/../lib/../lib/libicui18n.so.65
(0x00007f9b2633a000)
        libicuuc.so.65 =>/usr/bin/../lib/../lib/libicuuc.so.65
(0x00007f9b2614b000)
        libicudata.so.65 =>/usr/bin/../lib/../lib/libicudata.so.65
(0x00007f9b2469a000)
        liblzma.so.5 => /lib/liblzma.so.5 (0x00007f9b24672000)
#########

So the basic error is:
: CommandLine Error: Option 'help-list' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options

My configure:

#########
cmake -G "Unix Makefiles"         \
      -DCMAKE_BUILD_TYPE=Release  \
      -DCMAKE_INSTALL_PREFIX=/usr \
      -Duse_libclang=ON           \
      -Wno-dev ..
#########

where I've added -Duse_libclang=ON .

Any ideas?

Alan


-- 
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