On Friday 23 November 2007, Alon Bar-Lev wrote:
> I have an issue with libtool and cross compile.

as much of a tool as Enrico is, he is right that libtool is not currently 
conducive to cross-compiling.  pkg-config seems to be doing a nicer job of 
exporting dependencies.

> When merging a library which uses libtool, it creates the .la file
> with libdir= variable, usually it will contain /usr/lib.

libtool is based off of $libdir (which is usually based off of $prefix).  it 
doesnt really have a concept of separating build and run paths.

> Eventually I ended up with patching every package I use with the
> following patch in order to make it work:

a nicer method would probably to add a post-install bashrc hook that mungs the 
installed libtool scripts (*.la) by changing libdir= by prefixing $SYSROOT.  
ive used this in other environments pretty successfully.

sed -i -e "/^libdir=/s:=:='$SYSROOT':" $SYSROOT/usr/lib*/*.la
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to