https://bugs.llvm.org/show_bug.cgi?id=41214

            Bug ID: 41214
           Summary: Undefined reference when I link libc++
           Product: libc++
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: All Bugs
          Assignee: unassignedclangb...@nondot.org
          Reporter: praveenvellieng...@gmail.com
                CC: llvm-bugs@lists.llvm.org, mclow.li...@gmail.com

Hi,

When I compile this example
[https://reviews.llvm.org/diffusion/L/browse/llvm/trunk/examples/HowToUseJIT/HowToUseJIT.cpp
]from the trunk, the linking fails.

Command used to compile : 

clang++ -stdlib=libc++ -fuse-ld=lld  howto.cpp `llvm-config --cxxflags
--ldflags --libs`

the linker throws up 

ld.lld: error: undefined symbol:
llvm::EngineBuilder::EngineBuilder(std::__1::unique_ptr<llvm::Module,
std::__1::default_delete<llvm::Module> >)


But when I link libstdc++ instead of libc++, error was gone. 

Is this a known bug? 

Is there any workaround for this? 

My clang++ -v shows:
clang version 9.0.0,
Target: x86_64-unknown-linux-gnu.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to