[LLVMdev] Is the option --enable-shared discontinued in 2.7?

Jeffrey Yasskin jyasskin at google.com
Wed Apr 28 09:22:19 PDT 2010


On Wed, Apr 28, 2010 at 1:42 AM, Yuri <yuri at tsoft.com> wrote:
> Jeffrey Yasskin wrote:
>>
>> I just tried it again on trunk (not 2.7) on OSX 10.5, and it works.
>> What platform are you on? Does it work with another version of gcc?
>>
>
> Looks like this is platform dependent. libLLVM-2.7.so created has size only
> 4145 bytes and all llvm symbols are missing.
> It's empty because there are no .o modules included into it, only libraries
> through -l options were specified in g++ command line.
> Libraries normally are specified with -l option to resolve unknown imports,
> not to be just included into .so library.
>
> All .o files should be listed in the command line instead.

We currently use two different techniques to get whole libraries
included into the .so. On Linux (gnu ld and gold), we pass
--whole-archive, while on OSX we pass -all_load. Which ld does FreeBSD
use? If you can rearrange tools/llvm-shlib/Makefile until it works for
you and send us a patch, we can probably get it working for llvm-2.8.



More information about the llvm-dev mailing list