'system cflags' with other prefix

Dan Nicholson dbn.lists at gmail.com
Tue Jan 12 08:36:36 PST 2016


On Jan 12, 2016 8:18 AM, "Tollef Fog Heen" <tfheen at err.no> wrote:
>
> ]] Craig Treleaven
>
> > Eg, with MacPorts:
> > $ pkg-config --cflags x264
> > -I/opt/local/include                     ## want to make this disappear
since it is the ‘system include'
>
> If /opt/local/include is already on the compiler search path, pkg-config
> should be compiled with that knowledge, at which point it'll strip it
> out, like /usr/include on Linux.

This isn't documented (should be), but you can override pkg-config's notion
of the system include path with the environment variable
PKG_CONFIG_SYSTEM_INCLUDE_PATH. If that's not set, it uses the compiled in
defaults. That's been in pkg-config for a long time, so it should work with
the version you have. This should be in the form of a path style variable
with : separators.

Dan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/pkg-config/attachments/20160112/a5a73ccc/attachment.html>


More information about the pkg-config mailing list