bug-gnu-libiconv
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gnu-libiconv] Error cross-compiling to Android as shared librar


From: Bruno Haible
Subject: Re: [bug-gnu-libiconv] Error cross-compiling to Android as shared library
Date: Fri, 03 Jul 2020 00:18:17 +0200
User-agent: KMail/5.1.3 (Linux/4.4.0-179-generic; KDE/5.18.0; x86_64; ; )

Frederik Seiffert wrote:
> Changing LD to Android’s "ld" instead of clang allowed me to build libiconv 
> as a shared library. clang worked fine as linker for everything else I’ve 
> been building (I think it just forwards to ld), so I’m not sure why this 
> fixes the issue here – maybe a bug in libtool?

Thanks for telling us the solution.

clang and ld have different command-line invocation conventions. For example,
you can call
   ld -o foo.so -rpath /cross/lib object.o
whereas the calling convention for clang (as well as gcc) is
   $CC -o foo.so -Wl,-rpath,/cross/lib object.o

libtool needs to pass specific linker options when creating a shared library.

I think this explains it.

Bruno




reply via email to

[Prev in Thread] Current Thread [Next in Thread]