[cfe-dev] Static Linking and loading "libclang.so"

David Tweed David.Tweed at arm.com
Mon Oct 14 07:07:56 PDT 2013


Hi,

Note that there may be a slightly different issue: to my understanding Android actually provides a lot of the system calls expected of a Unix-y environment, but often puts them in different libraries. (At the very least, it looks like the linker is looking directly for libdl.so.2, which may not be the version used on Android, or as mentioned the functionality LLVM wants may actually be resident in a different .so file). However, I'm not remotely expert of the intricacies of Android, so I'll leave further advice for someone who's actually built LLVM for Android :) (In the worst case that no-one has done this you may have to figure out the dependencies and change the LLVM build-files yourself.)

Cheers,
Dave

From: cfe-dev-bounces at cs.uiuc.edu [mailto:cfe-dev-bounces at cs.uiuc.edu] On Behalf Of Renato Golin
Sent: 14 October 2013 14:39
To: Anton Smirnov
Cc: Clang Dev
Subject: Re: [cfe-dev] Static Linking and loading "libclang.so"

On 14 October 2013 08:42, Anton Smirnov <dev at antonsmirnov.name<mailto:dev at antonsmirnov.name>> wrote:
Caused by: java.lang.UnsatisfiedLinkError: Cannot load library: link_image[1891]:   185 could not load needed library 'libdl.so.2' for 'libclang.so.3.3' (load_library[1093]: Library 'libdl.so.2' not found)

Hi Anton,

libdl is required (as others) and probably not installed in your target system. You should be able to install it via yum/apt-get etc.

Installing Clang via packages would probably bring that dependency automatically, but you compiled it from scratch on a separate machine, so dependencies won't be met automatically.

And, yes, Clang/LLVM libraries are huge, especially ones with debug symbols in it.

cheers,
--renato

-- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

ARM Limited, Registered office 110 Fulbourn Road, Cambridge CB1 9NJ, Registered in England & Wales, Company No: 2557590
ARM Holdings plc, Registered office 110 Fulbourn Road, Cambridge CB1 9NJ, Registered in England & Wales, Company No: 2548782
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20131014/1fe79d2e/attachment.html>


More information about the cfe-dev mailing list