Re: find libxml2 using pkg-config

From: Noah Misch <noah(at)leadboat(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: find libxml2 using pkg-config
Date: 2013-03-04 18:36:37
Message-ID: 20130304183637.GA2978@tornado.leadboat.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, Mar 03, 2013 at 10:30:11PM -0500, Peter Eisentraut wrote:
> On Fri, 2013-03-01 at 14:25 -0500, Noah Misch wrote:
> > On Mon, Jan 14, 2013 at 06:51:05AM -0500, Peter Eisentraut wrote:
> > > In multi-arch OS installations, using a single foo-config script to
> > find
> > > libraries is problematic, because you don't know which architecture
> > it
> > > will point to, and you can't choose which one you want. Using
> > > pkg-config is better in that situation, because you can use its
> > > environment variables to point to your preferred version
> > > of /usr/lib*/pkgconfig or similar.
> >
> > "./configure XML2_CONFIG=/my/preferred/xml2-config" achieves this
> > today.
>
> No.
>
> The way multi-arch installations work is that you have the libraries
> under /usr/lib and /usr/lib64, or /usr/lib/$arch1 and /usr/lib/$arch2,
> but only one /usr/bin. So there cannot be two foo-config scripts to
> cover this. There is, however, /usr/lib/pkgconfig
> and /usr/lib64/pkgconfig (or analogous), so pkg-config can handle this.

Do you have in mind a target system exhibiting a problem? CentOS 6 ships a
single xml2-config, but its --cflags --libs output is the same regardless of
the installed combination of libxml2-dev packages. Ubuntu 13.04 does not ship
32-bit libxml2, so it avoids the question.

--
Noah Misch
EnterpriseDB http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2013-03-04 18:38:27 Re: sql_drop Event Trigger
Previous Message Josh Berkus 2013-03-04 18:06:32 Re: Commitfest progress