libtool
[Top][All Lists]
Advanced

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

Re: problem with libtool generated version script and underscores


From: Peter O'Gorman
Subject: Re: problem with libtool generated version script and underscores
Date: Wed, 06 Feb 2008 09:18:02 -0600
User-agent: Thunderbird 2.0.0.9 (X11/20071115)

Aleksey Demakov wrote:
> On Feb 6, 2008 2:51 AM, Aleksey Demakov <address@hidden> wrote:
>> I try to build a library (glib to be specific) with a cross-toolchain
>> that prepends underscore to C names. The problem is that the
>> symbols the library has to export do not get exported.
>>
> 
> By the way my problem looks just the same as discussed here:
> 
> http://lists.gnu.org/archive/html/bug-libtool/2007-05/msg00051.html
> 
> Though I do not get from this discussion if it was somehow resolved.

Libtool does not know about the system you are building for, does not
know that an underscore is required.

What is the host triplet for the system that you are building for?

You need to set archive_expsym_cmds for that system to be similar to
interix[[3-9]]* which has:

        _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols
>$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs
$compiler_flags ${wl}-h,$soname
${wl}--retain-symbols-file,$output_objdir/$soname.expsym
${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280`
-o $lib'

As you can see, it takes the symbol list, prepends and underscore, and
then uses that.

It is not required to change global_symbol_pipe etc.

Peter
-- 
Peter O'Gorman
http://pogma.com




reply via email to

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