[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: |
Mon, 27 Jan 2014 15:50:25 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131103 Icedove/17.0.10 |
On 27/01/14 14:27, Eric Blake wrote:
> On 01/26/2014 04:04 AM, Daniel Pocock wrote:
>
>> 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?
> Stick this in your configure.ac:
>
> m4_pattern_forbid([PKG_*])
>
> then anyone running autoconf on your package without the pkg-config m4
> modules installed will get an earlier error at autoconf time flagging
> the unexpanded macro, rather than a late error at configure execution of
> a shell syntax error or unfound command.
I tried adding that just under AM_INIT_AUTOMAKE
https://github.com/resiprocate/resiprocate/blob/master/configure.ac
autoreconf now fails even if pkg-config is present, here is the output:
$ autoreconf -fi
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, `build-aux'.
libtoolize: copying file `build-aux/ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
libtoolize: copying file `m4/libtool.m4'
libtoolize: copying file `m4/ltoptions.m4'
libtoolize: copying file `m4/ltsugar.m4'
libtoolize: copying file `m4/ltversion.m4'
libtoolize: copying file `m4/lt~obsolete.m4'
libtoolize: `AC_PROG_RANLIB' is rendered obsolete by `LT_INIT'
configure:1477: error: possibly undefined macro: PKGS
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure:16327: error: possibly undefined macro: ac_cv_env_PKG_CONFIG_set
configure:16333: error: possibly undefined macro: ac_cv_path_PKG_CONFIG
configure:16371: error: possibly undefined macro: ac_pt_PKG_CONFIG
configure:16376: error: possibly undefined macro:
ac_cv_path_ac_pt_PKG_CONFIG
configure:16508: error: possibly undefined macro: DEPS_PYTHON_PKG_ERRORS
autoreconf: /usr/bin/autoconf failed with exit status: 1