bug-automake
[Top][All Lists]
Advanced

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

bug#8407: aclocal installs third-party m4 files in directories specified


From: Stefano Lattarini
Subject: bug#8407: aclocal installs third-party m4 files in directories specified with absolute paths, even if it is documented not to
Date: Sat, 2 Apr 2011 09:56:59 +0200
User-agent: KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; )

On Friday 01 April 2011, Stefano Lattarini wrote:
> Reference to thread:
>  <http://lists.gnu.org/archive/html/automake-patches/2011-04/msg00001.html>
> Reference to parent message:
>  <http://lists.gnu.org/archive/html/automake-patches/2011-04/msg00011.html>
> 
> On Friday 01 April 2011, Stefano Lattarini wrote:
> > On Friday 01 April 2011, Ralf Wildenhues wrote:
> > > * Stefano Lattarini wrote on Fri, Apr 01, 2011 at 03:13:19PM CEST:
> > > > On Friday 01 April 2011, Ralf Wildenhues wrote:
> > > > > Patch 2:
> > > > > - Should `--install -I $dir' also create an absolute $dir?
> > > > >
> > > > I think so.  Why shouldn't it?
> > > 
> > > Well, I don't understand what a legitimate use case would be, that's
> > > why.  You need a relative path anyway for --install to copy files there.
> > > aclocal won't install to an absolute first -I directory,
> > >
> Unfortunately, this is not the case (even if such a behaviour is
> documented).  For example, with aclocal 1.11.1:
> 
>  $ cd /tmp
>  $ mkdir foo.dir
>  $ cd foo.dir
>  $ echo 'AC_INIT(x,0) AC_PROG_LIBTOOL' > configure.ac
>  $ mkdir m4
>  $ aclocal --install -I `pwd`/m4
>  aclocal: installing `/tmp/foo.dir/m4/libtool.m4' from 
> `/usr/share/aclocal/libtool.m4'
>  aclocal: installing `/tmp/foo.dir/m4/ltoptions.m4' from 
> `/usr/share/aclocal/ltoptions.m4'
>  aclocal: installing `/tmp/foo.dir/m4/ltsugar.m4' from 
> `/usr/share/aclocal/ltsugar.m4'
>  aclocal: installing `/tmp/foo.dir/m4/ltversion.m4' from 
> `/usr/share/aclocal/ltversion.m4'
>  aclocal: installing `/tmp/foo.dir/m4/lt~obsolete.m4' from 
> `/usr/share/aclocal/lt~obsolete.m4'
>  $ ls -l m4
>  total 292
>  -rw-r--r-- 1 stefano stefano 260519 Apr  1 20:06 libtool.m4
>  -rw-r--r-- 1 stefano stefano  11938 Apr  1 20:06 ltoptions.m4
>  -rw-r--r-- 1 stefano stefano   4372 Apr  1 20:06 ltsugar.m4
>  -rw-r--r-- 1 stefano stefano    703 Apr  1 20:06 ltversion.m4
>  -rw-r--r-- 1 stefano stefano   5707 Apr  1 20:06 lt~obsolete.m4
> 
> The bug is present also in maint; see the attached testcase which should
> be an exposer.
> 
> Regards,
>   Stefano
>
I've thought a little more about this, and I now think this bug shouldn't
be fixed by changing the current aclocal real behaviour, but rather the
documentation.  I.e., we should make things simpler and consistent, and,
when `--install' is used, simply copy third-party m4 files in the first
directory specified by `-I', whether absolute or not.  The rationale for
this is that the only reason the documented `--install' behaviour would
exist is to allow users to work around the non-existence of ACLOCAL_PATH
by specifying ACLOCAL='aclocal -I /some/system/dir' (as Ralf pointed out)
-- but we could solve the need of this workaround by applying the pending
patches for ACLOCAL_PATH support Paolo has already written for us.

WDYT?

Regards,
  Stefano





reply via email to

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