Обсуждение: configure problem --with-libxml

Поиск
Список
Период
Сортировка

configure problem --with-libxml

От
"Pavel Stehule"
Дата:
Hello,

I try to compile postgres with SQL/XML, but I finished on

checking libxml/parser.h usability... no
checking libxml/parser.h presence... no
checking for libxml/parser.h... no
configure: error: header file <libxml/parser.h> is required for XML support

I have Fedora Core 6, and libxml2-devel I have installed. I checked parser.h 
and this file is in /usr/include/libxml2/libxml/ directory

I am sorry, but configure file is spenish vilage for me, and I can't correct 
it.

Regards
Pavel Stehule

_________________________________________________________________
Chcete sdilet sve obrazky a hudbu s prateli? http://messenger.msn.cz/



Re: configure problem --with-libxml

От
Stefan Kaltenbrunner
Дата:
Pavel Stehule wrote:
> Hello,
> 
> I try to compile postgres with SQL/XML, but I finished on
> 
> checking libxml/parser.h usability... no
> checking libxml/parser.h presence... no
> checking for libxml/parser.h... no
> configure: error: header file <libxml/parser.h> is required for XML support
> 
> I have Fedora Core 6, and libxml2-devel I have installed. I checked 
> parser.h and this file is in /usr/include/libxml2/libxml/ directory
> 
> I am sorry, but configure file is spenish vilage for me, and I can't 
> correct it.

try adding --with-includes=/usr/include/libxml2 to your configure line


Stefan


Re: configure problem --with-libxml

От
"Pavel Stehule"
Дата:
I solved it via symlink, but this is much cleaner

Maybe configure scripts needs little bit more inteligence. All people on RH 
systems have to do it :-(

Thank you

Pavel Stehule


>From: Stefan Kaltenbrunner <stefan@kaltenbrunner.cc>
>To: Pavel Stehule <pavel.stehule@hotmail.com>
>CC: pgsql-hackers@postgresql.org
>Subject: Re: [HACKERS] configure problem --with-libxml
>Date: Fri, 22 Dec 2006 09:49:00 +0100
>
>Pavel Stehule wrote:
>>Hello,
>>
>>I try to compile postgres with SQL/XML, but I finished on
>>
>>checking libxml/parser.h usability... no
>>checking libxml/parser.h presence... no
>>checking for libxml/parser.h... no
>>configure: error: header file <libxml/parser.h> is required for XML 
>>support
>>
>>I have Fedora Core 6, and libxml2-devel I have installed. I checked 
>>parser.h and this file is in /usr/include/libxml2/libxml/ directory
>>
>>I am sorry, but configure file is spenish vilage for me, and I can't 
>>correct it.
>
>try adding --with-includes=/usr/include/libxml2 to your configure line
>
>
>Stefan

_________________________________________________________________
Emotikony a pozadi programu MSN Messenger ozivi vasi konverzaci. 
http://messenger.msn.cz/



Re: configure problem --with-libxml

От
"Nikolay Samokhvalov"
Дата:
another way is:
export CPPFLAGS=$(xml2-config --cflags); ./configure --with-libxml

I think that such thing can be used in configure script itself,
overwise a lot of people will try, fail and do not use SQL/XML at all.

On 12/22/06, Pavel Stehule <pavel.stehule@hotmail.com> wrote:
> Hello,
>
> I try to compile postgres with SQL/XML, but I finished on
>
> checking libxml/parser.h usability... no
> checking libxml/parser.h presence... no
> checking for libxml/parser.h... no
> configure: error: header file <libxml/parser.h> is required for XML support
>
> I have Fedora Core 6, and libxml2-devel I have installed. I checked parser.h
> and this file is in /usr/include/libxml2/libxml/ directory
>
> I am sorry, but configure file is spenish vilage for me, and I can't correct
> it.
>
> Regards
> Pavel Stehule
>
> _________________________________________________________________
> Chcete sdilet sve obrazky a hudbu s prateli? http://messenger.msn.cz/
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Have you searched our list archives?
>
>                http://archives.postgresql.org
>


-- 
Best regards,
Nikolay


Re: configure problem --with-libxml

От
Peter Eisentraut
Дата:
Nikolay Samokhvalov wrote:
> another way is:
> export CPPFLAGS=$(xml2-config --cflags); ./configure --with-libxml
>
> I think that such thing can be used in configure script itself,
> overwise a lot of people will try, fail and do not use SQL/XML at
> all.

The reason why I did not do this was that this could resolve 
to -I/usr/include or -I/usr/local/include, but adding such a standard 
path explicitly is wrong on some systems.

Clearly, we need to improve this, but I don't know how yet.  Ideas 
welcome.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/


Re: configure problem --with-libxml

От
Martijn van Oosterhout
Дата:
On Fri, Dec 22, 2006 at 03:03:49PM +0100, Peter Eisentraut wrote:
> Nikolay Samokhvalov wrote:
> > another way is:
> > export CPPFLAGS=$(xml2-config --cflags); ./configure --with-libxml
> >
> > I think that such thing can be used in configure script itself,
> > overwise a lot of people will try, fail and do not use SQL/XML at
> > all.
>
> The reason why I did not do this was that this could resolve
> to -I/usr/include or -I/usr/local/include, but adding such a standard
> path explicitly is wrong on some systems.

But if people on such a system want to use libxml2, and they install it
in /usr/include then they're screwed anyway. There's no way to tell the
compiler to use only some files in a directory.

Put another way, if adding the include path for libxml2 breaks their
build environment, they can't use libxml2. Have configure play dumb
isn't helping anyone. It won't work on any more or less systems.

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Re: configure problem --with-libxml

От
Tom Lane
Дата:
Martijn van Oosterhout <kleptog@svana.org> writes:
> On Fri, Dec 22, 2006 at 03:03:49PM +0100, Peter Eisentraut wrote:
>> The reason why I did not do this was that this could resolve
>> to -I/usr/include or -I/usr/local/include, but adding such a standard
>> path explicitly is wrong on some systems.

> But if people on such a system want to use libxml2, and they install it
> in /usr/include then they're screwed anyway. There's no way to tell the
> compiler to use only some files in a directory.

That's not the point, the point is that an *explicit* -I can be wrong
(because it can change the search order of the default directories).

Perhaps it'd be worth trying to add xml2-config's output only if the
first probe for the headers fails?
        regards, tom lane