bug-automake
[Top][All Lists]
Advanced

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

bug#19964: automake fails if files named “install.sh” and “install-sh” a


From: Florent Le Coz
Subject: bug#19964: automake fails if files named “install.sh” and “install-sh” are found in the parent directory
Date: Fri, 27 Feb 2015 20:50:13 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0

Software versions:
automake (GNU automake) 1.14.1
aclocal (GNU automake) 1.14.1
autoconf (GNU Autoconf) 2.69
autoreconf (GNU Autoconf) 2.69


Assuming project.tar.gz contains the source code of a project using
the autotools as its build system:

$ tar xf project.tar.gz
$ cd project/
$ touch ../install-sh ../install.sh
$ autoreconf -vif
autoreconf: Entering directory `.'
[…]
BUG.am: error: 'install.sh' is an anachronism; use 'install-sh' instead
[…]
autoreconf: automake failed with exit status: 1

$ rm ../install-sh ../install.sh
$ autoreconf -vif
autoreconf: Entering directory `.'
[…]
autoreconf: Leaving directory `.'
$ echo $?
0

It seems to be related to this code (taken from the last git revision)

      # The default auxiliary directory is the first
      # of ., .., or ../.. that contains install-sh.
      # Assume . if install-sh doesn't exist yet.
      for my $dir (qw (. .. ../..))
        {
          if (-f "$dir/install-sh")
            {
              $config_aux_dir = $dir;
              last;
            }
        }

Which sets $config_aux_dir to "..", but then later we look for
install.sh in that directory

  err_am "'install.sh' is an anachronism; use 'install-sh' instead"
    if -f $config_aux_dir . '/install.sh';

You probably have reasons to look in .. or ../.. (and I would be
quite interested to hear them, actually), but I don’t think it
should fail in the specific case I described above.  I don’t
think it’s safe to assume that the parent directory of a project
is not filled with garbage (mine was full or random files,
including a install.sh and install-sh files, for some reasons).

Plus, it was really, really hard for me to understand which
“install.sh” file this error was talking about, since I could not
find any such file in my working directory or any sub-directory.

Regards

--
Florent






reply via email to

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