On Thu, 14 Feb 2019 23:21:26 +0000 "Paul \"LeoNerd\" Evans" <[email protected]> wrote:
> My earlier suggested approach of trying to hunt down the .la files and
> generate/append extra -Wl,-rpath arguments appears to be working
> reliably though, so it may be that's the best approach. It does feel
> rather fragile however, as I'm second-guessing around what libtool
> would do.
Alternatively, am I looking at this from the wrong direction? Maybe the
problem is that the exporting library isn't providing -Wl,-rpath in
its .pc file, to assist anyone else who wasn't using libtool to link it
(such as is the case here).
With that in mind, I now generate those if required, in the little
shell fragment I use to create the .pc file:
#!/bin/sh
LIBS='-L${libdir} -ltickit'
CFLAGS='-I${includedir}'
case "$LIBDIR" in
/usr/lib) ;;
/usr/local/lib) ;;
*)
LIBS="$LIBS -Wl,-rpath -Wl,$LIBDIR"
;;
esac
cat <<EOF
libdir=$LIBDIR
includedir=$INCDIR
Name: tickit
Description: Terminal Interface Construction KIT
Version: 0.2
Libs: $LIBS
Cflags: $CFLAGS
EOF
--
Paul "LeoNerd" Evans
[email protected] | https://metacpan.org/author/PEVANS
http://www.leonerd.org.uk/ | https://www.tindie.com/stores/leonerd/
pgpnfDWuo8Bev.pgp
Description: OpenPGP digital signature
_______________________________________________ https://lists.gnu.org/mailman/listinfo/libtool
