[Mesa-dev] [PATCH 4/6] configure.ac: Use PKG_CHECK_VAR for libclc.

Brian Paul brianp at vmware.com
Tue Mar 7 21:08:30 UTC 2017


On 03/07/2017 01:49 PM, Matt Turner wrote:
> On Tue, Mar 7, 2017 at 12:41 PM, Brian Paul <brianp at vmware.com> wrote:
>> On 03/06/2017 12:06 PM, Matt Turner wrote:
>>>
>>> ---
>>>    configure.ac | 6 ++----
>>>    1 file changed, 2 insertions(+), 4 deletions(-)
>>>
>>> diff --git a/configure.ac b/configure.ac
>>> index 37f6b60..d44a229 100644
>>> --- a/configure.ac
>>> +++ b/configure.ac
>>> @@ -2018,10 +2018,8 @@ if test "x$enable_opencl" = xyes; then
>>>                        PKG_CONFIG_PATH environment variable.
>>>                        By default libclc.pc is installed to
>>> /usr/local/share/pkgconfig/])
>>>        else
>>> -        LIBCLC_INCLUDEDIR=`$PKG_CONFIG --variable=includedir libclc`
>>> -        LIBCLC_LIBEXECDIR=`$PKG_CONFIG --variable=libexecdir libclc`
>>> -        AC_SUBST([LIBCLC_INCLUDEDIR])
>>> -        AC_SUBST([LIBCLC_LIBEXECDIR])
>>> +        PKG_CHECK_VAR([LIBCLC_INCLUDEDIR], [libclc], [includedir])
>>> +        PKG_CHECK_VAR([LIBCLC_LIBEXECDIR], [libclc], [libexecdir])
>>>        fi
>>>
>>>        gallium_st="$gallium_st clover"
>>>
>>
>> Hi Matt,
>>
>> I'm getting a configure error after this change:
>>
>> $ ./autogen.sh CFLAGS="-g -O0" CXXFLAGS="-g -O0" --enable-debug
>> --enable-glx=gallium-xlib --disable-driglx-direct --disable-dri
>> --enable-osmesa --with-gallium-drivers=swrast,svga --disable-xvmc
>> --disable-gbm --disable-egl
>> autoreconf: Entering directory `.'
>> autoreconf: configure.ac: not using Gettext
>> autoreconf: running: aclocal --force -I m4
>> autoreconf: configure.ac: tracing
>> autoreconf: running: libtoolize --copy --force
>> libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, `bin'.
>> libtoolize: copying file `bin/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'
>> autoreconf: running: /usr/bin/autoconf --force
>> configure.ac:2021: error: possibly undefined macro: PKG_CHECK_VAR
>>        If this token and others are legitimate, please use m4_pattern_allow.
>>        See the Autoconf documentation.
>> autoreconf: /usr/bin/autoconf failed with exit status: 1
>>
>>
>> Any ideas?
>>
>> -Brian
>
> What version of pkg-config do you have? PKG_CHECK_VAR was added in
> version 0.28, which was released 2013-01-24. Perhaps naïvely, I
> assumed without checking that >4 years was sufficiently old.
>
> [1] indicates that Ubuntu 14.04LTS might only have 0.26? That seems
> unfortunate since it postdates pkg-config-0.28 by more than a year.
>
> If that is indeed the problem, I guess the first question is whether
> it's possible to easily update pkg-config to 0.28?
>
> Sorry for this.
>
> [1] https://urldefense.proofpoint.com/v2/url?u=http-3A__packages.ubuntu.com_search-3Fkeywords-3Dpkg-2Dconfig&d=DwIFaQ&c=uilaK90D4TOVoH58JNXRgQ&r=Ie7_encNUsqxbSRbqbNgofw0ITcfE8JKfaUjIQhncGA&m=4nlRGhdD5QmOowJspxy0hYNXFpN5Q8ArwUf3xdYPB1k&s=hjz5tyYRnKbN6RmtPWTF--zN-YRdE5yk1CQZIOJL6To&e=

My main system is running Mint 17 and it looks like pkg-config is 0.26.

I tried to upgrade it:

$ sudo apt-get install --only-upgrade pkg-config
[sudo] password for brianp:
Reading package lists... Done
Building dependency tree
Reading state information... Done
pkg-config is already the newest version.

I could try updating to 17.3 (still based on Ubuntu 14.04) but I don't 
know if that'll update pkg-config.

Upgrading to Mint 18 is something I'd rather not do right now (I have a 
knack for hitting snags).

How do you feel about reverting this patch and the wayland-scanner one?

-Brian



More information about the mesa-dev mailing list