GNU bug report logs - #18662
Local -L flags for "make check" appear too late under HP-UX

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: automake; Reported by: Vincent Lefevre <vincent@HIDDEN>; dated Wed, 8 Oct 2014 11:34:02 UTC; Maintainer for automake is bug-automake@HIDDEN.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 8 Oct 2014 11:33:39 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 08 07:33:39 2014
Received: from localhost ([127.0.0.1]:37465 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1XbpUw-0004Yl-LB
	for submit <at> debbugs.gnu.org; Wed, 08 Oct 2014 07:33:39 -0400
Received: from eggs.gnu.org ([208.118.235.92]:55404)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <vincent@HIDDEN>) id 1XbpUu-0004Yd-HS
 for submit <at> debbugs.gnu.org; Wed, 08 Oct 2014 07:33:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <vincent@HIDDEN>) id 1XbpUo-0007C0-Fx
 for submit <at> debbugs.gnu.org; Wed, 08 Oct 2014 07:33:36 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled
 version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:55705)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <vincent@HIDDEN>) id 1XbpUo-0007Bv-E2
 for submit <at> debbugs.gnu.org; Wed, 08 Oct 2014 07:33:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57082)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <vincent@HIDDEN>) id 1XbpUi-0002ik-Uk
 for bug-automake@HIDDEN; Wed, 08 Oct 2014 07:33:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <vincent@HIDDEN>) id 1XbpUd-00079P-Nb
 for bug-automake@HIDDEN; Wed, 08 Oct 2014 07:33:24 -0400
Received: from ioooi.vinc17.net ([92.243.22.117]:33972)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <vincent@HIDDEN>) id 1XbpUd-00078f-Ie
 for bug-automake@HIDDEN; Wed, 08 Oct 2014 07:33:19 -0400
Received: from smtp-xvii.vinc17.net (128.119.75.86.rev.sfr.net [86.75.119.128])
 by ioooi.vinc17.net (Postfix) with ESMTPSA id E65E3460;
 Wed,  8 Oct 2014 13:33:11 +0200 (CEST)
Received: by xvii.vinc17.org (Postfix, from userid 1000)
 id 2B0F721A07A; Wed,  8 Oct 2014 13:33:11 +0200 (CEST)
Date: Wed, 8 Oct 2014 13:33:11 +0200
From: Vincent Lefevre <vincent@HIDDEN>
To: bug-automake@HIDDEN
Subject: Local -L flags for "make check" appear too late under HP-UX
Message-ID: <20141008113310.GA25883@HIDDEN>
Mail-Followup-To: Vincent Lefevre <vincent@HIDDEN>,
	bug-automake@HIDDEN
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
X-Mailer-Info: http://www.vinc17.net/mutt/
User-Agent: Mutt/1.5.23-6365-vl-r59709 (2014-09-07)
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -5.0 (-----)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -5.0 (-----)

I reported the following bug

  http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D9728

against libtool a few years ago, but it was said that the bug was in
autoconf or automake (then, I suspect automake). I don't know whether
something has been done on the automake side; I don't have access to
HP-UX machines any longer.

The problem is the following.

To be able to build the MPFR library, the user may need to add some
search path when invoking configure, in order to find the GMP library
(on which MPFR depends). This is done via LDFLAGS, either explicitly
or by the configure script if the user has provided a --with-gmp=3DDIR
option. The setting of LDFLAGS for such a purpose is standard and
documented in the Automake manual (AM_LDFLAGS could be used too, with
the same effect).

Then, for "make check", the path to the MPFR library that has just
been built or the library filename itself must be added to the link
command by the autotools (automake?). Under GNU/Linux, the filename
../src/.libs/libmpfr.so is used, and there are no problems. But under
HP-UX, it is the path that is added (here, the -L../src/.libs flag),
and this is done in LIBS, which appears at the end of the command,
and in particular *after* $(LDFLAGS):

LINK =3D $(LIBTOOL) --tag=3DCC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
        --mode=3Dlink $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
        $(LDFLAGS) -o $@

tversion$(EXEEXT): $(tversion_OBJECTS) $(tversion_DEPENDENCIES)
        @rm -f tversion$(EXEEXT)
        $(LINK) $(tversion_OBJECTS) $(tversion_LDADD) $(LIBS)

which gives for instance:

libtool: link: gcc -O2 -s -o tversion tversion.o  -L/opt/gnu/lib ./.libs/=
libfrtests.a -lm -L../src/.libs -lmpfr -lgmp -Wl,+b -Wl,/xxx/gnu/mpfr-3.1=
.0/objdir/src/.libs:/opt/gnu/lib

(see the -L/opt/gnu/lib before -L../src/.libs).

This means that search paths added via AM_LDFLAGS and/or LDFLAGS have
the precedence over the local search path, and if an old version of
the library is installed in some LDFLAGS search path (which happens),
it will be used for "make check" instead of the library that has just
been built.

--=20
Vincent Lef=E8vre <vincent@HIDDEN> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)




Acknowledgement sent to Vincent Lefevre <vincent@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-automake@HIDDEN. Full text available.
Report forwarded to bug-automake@HIDDEN:
bug#18662; Package automake. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Fri, 31 Oct 2014 17:00:04 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.