bug-gnulib
[Top][All Lists]
Advanced

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

bootstrap check_exists() causes misleading diagnostics on OpenBSD


From: Ingo Schwarze
Subject: bootstrap check_exists() causes misleading diagnostics on OpenBSD
Date: Sat, 18 Oct 2014 18:58:56 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

Hi,

this is maybe not a full-grown bug, more like a quirk, but is is
sure bound to cause confusion, so i'd like to hear what you think...

I'm the maintainer of the OpenBSD port of groff (GNU troff),
and Bertrand (see Cc:) is currently migrating the groff build
system to automake and gnulib.  He uses the bootstrap script,
among many other parts of the gnulib toolkit.

On OpenBSD, the usual way to install the autotools is as follows:

 $ uname -a
OpenBSD isnote.usta.de 5.6 GENERIC.MP#338 i386
 $ pkg_info | grep -e autoconf -e automake
autoconf-2.13p3     automatically configure source code on many Un*x platforms
autoconf-2.59p4     automatically configure source code on many Un*x platforms
autoconf-2.61p4     automatically configure source code on many Un*x platforms
autoconf-2.62p1     automatically configure source code on many Un*x platforms
autoconf-2.63p0     automatically configure source code on many Un*x platforms
autoconf-2.65p0     automatically configure source code on many Un*x platforms
autoconf-2.67p0     automatically configure source code on many Un*x platforms
autoconf-2.68p0     automatically configure source code on many Un*x platforms
autoconf-2.69p1     automatically configure source code on many Un*x platforms
automake-1.11.6p1   GNU Standards-compliant Makefile generator
automake-1.12.6p0   GNU Standards-compliant Makefile generator
automake-1.14.1     GNU Standards-compliant Makefile generator
automake-1.9.6p11   GNU Standards-compliant Makefile generator
 $ ls /usr/local/bin/auto{conf,make}*
/usr/local/bin/autoconf                 /usr/local/bin/autoconf-2.68
/usr/local/bin/autoconf-2.13            /usr/local/bin/autoconf-2.69
/usr/local/bin/autoconf-2.59            /usr/local/bin/automake
/usr/local/bin/autoconf-2.61            /usr/local/bin/automake-1.11
/usr/local/bin/autoconf-2.62            /usr/local/bin/automake-1.12
/usr/local/bin/autoconf-2.63            /usr/local/bin/automake-1.14
/usr/local/bin/autoconf-2.65            /usr/local/bin/automake-1.9
/usr/local/bin/autoconf-2.67
 $ which autoconf automake
/usr/local/bin/autoconf
/usr/local/bin/automake
 $ autoconf; echo $?
Provide an AUTOCONF_VERSION environment variable, please
127
 $ automake; echo $? 
Provide an AUTOMAKE_VERSION environment variable, please
127
 $ export AUTOCONF_VERSION=2.65
 $ export AUTOMAKE_VERSION=1.12 
 $ autoconf --version | head -n1; echo $?
autoconf (GNU Autoconf) 2.65
0
address@hidden $ automake --version | head -n1; echo $? 
automake (GNU automake) 1.12.6
0

Now, if you forget to set these variables before running ./bootstrap,
bootstrap check_exists() redirects the helpful error messages to
/dev/null and shows bogus diagnostics instead:

  Error: 'autoconf' not found

Do you see any way of not hiding the real diagnostics from the
poor user?

Thanks for your work on gnulib and for your consideration,
  Ingo


Werner LEMBERG wrote on Mon, Sep 22, 2014 at 11:20:31PM +0200:

>> So this code in ./bootstrap is suboptimal:
>> 
>>   check_exists() {
>>     ($1 --version </dev/null) >/dev/null 2>&1
>> 
>> That deliberately hides the error message from the user and displays
>> a bogus message instead, so you might wish to refrain from hiding
>> stderr.

> ... given that `bootstrap' is a ready-to-run script from `gnulib',
> this should probably discussed with the gnulib people.



reply via email to

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