Subject: bug#54837: LLVM 3.* build failure

From: Guillaume Le Vaillant <[email-masked]>
Date: Sun, 10 Apr 2022 17:23:48 +0000

Guillaume Le Vaillant <[email-masked]> skribis:

> Guillaume Le Vaillant <[email-masked]> skribis:
>
>> However there are other issues during the build phase:
>>
>> ../../bin/llvm-tblgen: error while loading shared libraries: libLLVMTableGen.so: cannot open shared object file: No such file or directory
>> make[2]: *** [lib/IR/CMakeFiles/AttributeCompatFuncTableGen.dir/build.make:105: lib/IR/AttributesCompatFunc.inc.tmp] Error 127
>> make[2]: Leaving directory '/tmp/guix-build-llvm-3.9.1.drv-0/build'
>> make[1]: *** [CMakeFiles/Makefile2:5233: lib/IR/CMakeFiles/AttributeCompatFuncTableGen.dir/all] Error 2
>> make[1]: *** Waiting for unfinished jobs....
>> ../../bin/llvm-tblgen: error while loading shared libraries: libLLVMTableGen.so: cannot open shared object file: No such file or directory
>> make[2]: *** [lib/LibDriver/CMakeFiles/LibOptionsTableGen.dir/build.make:105: lib/LibDriver/Options.inc.tmp] Error 127
>> make[2]: Leaving directory '/tmp/guix-build-llvm-3.9.1.drv-0/build'
>> make[1]: *** [CMakeFiles/Makefile2:12101: lib/LibDriver/CMakeFiles/LibOptionsTableGen.dir/all] Error 2
>> ../../../bin/llvm-tblgen: error while loading shared libraries: libLLVMTableGen.so: cannot open shared object file: No such file or directory
>> make[2]: *** [include/llvm/IR/CMakeFiles/intrinsics_gen.dir/build.make:123: include/llvm/IR/Attributes.inc.tmp] Error 127
>> make[2]: *** Waiting for unfinished jobs....
>> ../../../bin/llvm-tblgen: error while loading shared libraries: libLLVMTableGen.so: cannot open shared object file: No such file or directory
>> make[2]: *** [include/llvm/IR/CMakeFiles/intrinsics_gen.dir/build.make:165: include/llvm/IR/Intrinsics.gen.tmp] Error 127
>> make[2]: Leaving directory '/tmp/guix-build-llvm-3.9.1.drv-0/build'
>> make[1]: *** [CMakeFiles/Makefile2:5153: include/llvm/IR/CMakeFiles/intrinsics_gen.dir/all] Error 2
>> make[2]: Leaving directory '/tmp/guix-build-llvm-3.9.1.drv-0/build'
>
> It looks like llvm-12 has a workaround for this issue. I'll copy it to
> llvm-3.9 and test that...

Partial fix pushed in 81567f751bd31d972cf05013a177311b73425d7d; the
builds for llvm-3.7 and llvm-3.8 are still failing.