Subject: using absolute library references (paths) with libtool

From: René J.V. Bertin <[email-masked]>
Date: Mon, 09 May 2016 16:15:18 +0200

Hi,

I'm not sure if this is really a bug:

I'm trying to make sure that a certain software package is built with a custom library (ffmpeg) rather than using the shared libraries from a central location that also provides other dependencies. Since it seems impossible to tell the linker not to take a given library from a particular location I am patching the custom ffmpeg's .pc files so that the "Libs:" line reads "${libdir}/libavfoo.dylib" instead of "-L${libdir} -lavfoo" (this is on OS X, indeed).

This doesn't work, because for some reason the libtool script that is created in the toplevel source directory (by autoreconf) filters out those absolute paths to library files before calling the actual linker. In order for this to work I need to trick libtool: set up symlinks (ln -s libavfoo.dylib libavfoo.o) that look like regular object files, and let the linker driver (clang) figure out what it is actually working with.

Is this a known issue (or feature) in libtool, is there something awry with the copy that's created by autoreconf, or is this a bug that needs reporting?
I'm using version 2.4.6 .

Thanks,
René