autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PKG_CHECK_MODULES not working in Solaris


From: Daniel Pocock
Subject: Re: PKG_CHECK_MODULES not working in Solaris
Date: Sun, 26 Jan 2014 12:04:50 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131103 Icedove/17.0.10


On 20/07/11 16:12, Eric Blake wrote:
> On 07/20/2011 02:39 AM, Kaushik BV wrote:
>> But somehow it fails in `Solaris` with the following error
>>
>>      checking if libxml2 is present... ./configure: line 11586: syntax
>> error
>> near unexpected token `LIBXML2,'
>>      ./configure: line 11586: `PKG_CHECK_MODULES(LIBXML2, libxml-2.0>=
>> 2.6.19,'
> 
> That means that your aclocal.m4 (either hand-written, or as generated by
> 'aclocal' from automake) file did not include enough instructions to
> have a definition of the macro PKG_CHECK_MODULES.  Is your project using
> automake?  If so, it means that you were probably relying on automake's
> search path of installed public .m4 files on one machine where the
> pkg-config package had been installed, but on your Solaris machine,
> automake is not set up to find that external macro by default.
> 
> Relying on external .m4 macros when rerunning aclocal (or autoreconf) is
> always dangerous - it means you are dependent on what else is already
> installed on your machine.  Better is to copy the pkg-config .m4 file
> that defined PKG_CHECK_MODULES into your project, so that the macro is
> available for all people who autoreconf your package, even in cases like
> your Solaris setup where pkg-config has not already been installed in
> such a way that its public .m4 files are visible to automake.
> 
>> Googled for a solution, most of them complain of `pkg-config` not being
>> installed. But in my test machine its actually installed, checked it by
>> executing the following command.
>>
>>      bash-3.00# pkg-config libxml-2.0 --modversion
>>      2.6.23
> 
> That says that the pkg-config binary is installed, but doesn't say
> whether the public .m4 files provided by the pkg-config package are
> located somewhere that automake will find them by default.
> 

Users of reSIProcate have also come across this problem since we started
using PKG_CHECK_MODULES

I think PKG_CHECK_MODULES is a good idea, but is there some way to give
a more helpful error to tell people to install the pkg-config package on
their system?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]