[llvm-dev] LLVM source compilation Error: CommandLine Error: Option 'mc-relax-all' registered more than once!

Stephen Neuendorffer via llvm-dev llvm-dev at lists.llvm.org
Sat Jul 11 17:15:26 PDT 2020


This is usually a linkage error when the same library is being included in
both a static library and a shared library.  You can probably with around
it by disabling build shared libs temporarily.  I'll see if I can track
down the problem, but I doubt get to it right away.

Steve

On Sat, Jul 11, 2020, 4:28 PM K Jelesnianski via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> Dear All,
>
> Recently, I wanted to reinstall a fresh copy of llvm for a new project
> I am working on.
> However I ran into the following issue when attempting to build a vanilla
> copy.
>
> CommandLine Error: Option 'mc-relax-all' registered more than once!
> LLVM ERROR: inconsistency in registered CommandLine options
> make[2]: ***
> [unittests/Support/DynamicLibrary/CMakeFiles/DynamicLibraryLib.dir/build.make:85:
> lib/libDynamicLibraryLib.a] Error 1
> make[2]: *** Deleting file 'lib/libDynamicLibraryLib.a'
> make[1]: *** [CMakeFiles/Makefile2:137325:
> unittests/Support/DynamicLibrary/CMakeFiles/DynamicLibraryLib.dir/all]
> Error 2
> make[1]: *** Waiting for unfinished jobs....
>
> I am working on the following platform:
> Linux XXXX 5.0.16-100.fc28.x86_64 #1 SMP Tue May 14 18:22:28 UTC 2019
> x86_64 x86_64 x86_64 GNU/Linux
>
> My steps were:
> $ git clone git at github.com:llvm/llvm-project.git
> $ cd llvm-project/
> $ git checkout llvmorg-9.0.0
> (I later tried with releases llvmorg-8.0.0 AND llvm-10.0.0 but still
> got the same error)
> $ mkdir build && cd build
> $ cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Debug
> -DLLVM_TARGETS_TO_BUILD="X86" -DLLVM_ENABLE_PROJECTS=clang -G "Unix
> Makefiles" ../llvm
> (No errors so far)
> $ make -j40
> (This is where error happens)
>
> I have worked with llvm for over 6 years now and still never ran into
> something so bizarre. Any help is appreciated. I have looked online
> for a few hours now and found similar postings but no clear replies or
>  solutions for this.
>
> Sincerely,
>
> Christopher Jelesnianski
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20200711/d892fa4b/attachment.html>


More information about the llvm-dev mailing list