Configuring automake to install to a path containing a '@' character breaks the 
compilation as shown in the attached typescripts. We found that we were able to 
work around the bug with the following patch:

diff --git a/bin/aclocal.in b/bin/aclocal.in
index 349f24a2..c8ab8b3e 100644
--- a/bin/aclocal.in
+++ b/bin/aclocal.in
@@ -69,7 +69,7 @@ $perl_threads = 0;
# ACLOCAL_PATH environment variable, and reset with the '--system-acdir'
# option.
my @user_includes = ();
-my @automake_includes = ("@datadir@/aclocal-$APIVERSION");
+my @automake_includes = ('@datadir@/aclocal-' . $APIVERSION);
my @system_includes = ('@datadir@/aclocal');

# Whether we should copy M4 file in $user_includes[0].

In considering alternative fixes we found that we could equally address the 
problem by replacing the double-quoted string with 
'@datadir@/aclocal-@APIVERSION@', similar to the use of @APIVERSION@ on line 
30, but elected to continue the use of $APIVERSION in the event that there was 
a specific reason for using the Perl variable in this instance.

Regards,

Michael Brantley
Script started on Fri 30 Dec 2016 06:21:37 AM EST
sh-4.2$ cd /tmp
sh-4.2$ tar xJf ~/Downloads/automake-1.15.tar.xz
sh-4.2$ cd automake-1.15/
sh-4.2$ ./configure --prefix=/tmp/automake
checking whether make supports nested variables... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether ln -s works... yes
checking for perl... /usr/local/bin/perl
checking for tex... tex
checking for yacc... yacc
checking for lex... lex
checking whether autoconf is installed... yes
checking whether autoconf works... yes
checking whether autoconf is recent enough... yes
checking whether ln works... yes
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
configure: will now look for a sturdy POSIX shell, for our testsuite
checking for sh... /usr/bin/sh
checking for sh5... no
checking for dash... /usr/bin/dash
checking for ash... no
checking for bash... /usr/local/bin/bash
checking for zsh... /usr/local/bin/zsh
checking for ksh... /usr/bin/ksh
checking for pdksh... no
checking whether /usr/bin/sh supports $(cmd)... yes
checking whether /usr/bin/sh supports $((expr))... yes
checking whether /usr/bin/sh supports ${#var}... yes
checking whether /usr/bin/sh supports ${var#glob} and ${var%glob}... yes
checking whether /usr/bin/sh preserves exit traps with "set -e"... yes
checking whether /usr/bin/sh can define exit traps in a shell function... yes
checking whether /usr/bin/sh corrupts stderr with "set -x"... no
checking whether /usr/bin/sh can return early from "dot-sourced" files... yes
checking whether /usr/bin/sh supports alias named like shell builtins... yes
checking whether /usr/bin/sh supports "test -e"... yes
configure: shell /usr/bin/sh is good enough, stop looking
configure: will use /usr/bin/sh as the testsuite shell
configure: will now look for generic compilers
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for aCC... no
checking for CC... no
checking for FCC... no
checking for KCC... no
checking for RCC... no
checking for xlC_r... no
checking for xlC... no
checking for c++... c++
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether c++ accepts -g... yes
checking for xlf95... no
checking for f95... f95
checking whether the Fortran compiler works... yes
checking for Fortran compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU Fortran compiler... yes
checking whether f95 accepts -g... yes
checking for xlf... no
checking for f77... no
checking for frt... no
checking for pgf77... no
checking for cf77... no
checking for fort77... no
checking for fl32... no
checking for af77... no
checking for g77... no
checking for gfortran... gfortran
checking whether the Fortran 77 compiler works... yes
checking for Fortran 77 compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether gfortran accepts -g... yes
configure: will now look for GNU compilers
configure: cc is already a GNU C compiler
configure: c++ is already a GNU C++ compiler
configure: f95 is already a GNU Fortran compiler
configure: gfortran is already a GNU Fortran 77 compiler
checking for gcj... no
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating t/wrap/aclocal-1.15
config.status: creating t/wrap/automake-1.15
sh-4.2$ make
  GEN      bin/automake
  GEN      bin/aclocal
  GEN      t/ax/shell-no-trail-bslash
  GEN      t/ax/cc-no-c-o
  GEN      runtest
  GEN      doc/aclocal.1
  GEN      doc/automake.1
  GEN      lib/Automake/Config.pm
  GEN      doc/aclocal-1.15.1
  GEN      doc/automake-1.15.1
  GEN      t/ax/test-defs.sh
sh-4.2$ make install
make[1]: Entering directory `/tmp/automake-1.15'
 /usr/bin/mkdir -p '/tmp/automake/bin'
 /usr/bin/install -c bin/automake bin/aclocal '/tmp/automake/bin'
make  install-exec-hook
make[2]: Entering directory `/tmp/automake-1.15'
 ln '/tmp/automake/bin/automake' '/tmp/automake/bin/automake-1.15'
 ln '/tmp/automake/bin/aclocal' '/tmp/automake/bin/aclocal-1.15'
make[2]: Leaving directory `/tmp/automake-1.15'
 /usr/bin/mkdir -p '/tmp/automake/share/automake-1.15/am'
 /usr/bin/install -c -m 644 lib/am/check.am lib/am/check2.am 
lib/am/clean-hdr.am lib/am/clean.am lib/am/compile.am lib/am/configure.am 
lib/am/data.am lib/am/dejagnu.am lib/am/depend.am lib/am/depend2.am 
lib/am/distdir.am lib/am/footer.am lib/am/header-vars.am lib/am/header.am 
lib/am/install.am lib/am/inst-vars.am lib/am/java.am lib/am/lang-compile.am 
lib/am/lex.am lib/am/library.am lib/am/libs.am lib/am/libtool.am lib/am/lisp.am 
lib/am/ltlib.am lib/am/ltlibrary.am lib/am/mans-vars.am lib/am/mans.am 
lib/am/program.am lib/am/progs.am lib/am/python.am lib/am/remake-hdr.am 
lib/am/scripts.am lib/am/subdirs.am lib/am/tags.am lib/am/texi-vers.am 
lib/am/texibuild.am lib/am/texinfos.am lib/am/vala.am lib/am/yacc.am 
'/tmp/automake/share/automake-1.15/am'
 /usr/bin/mkdir -p '/tmp/automake/share/aclocal-1.15'
 /usr/bin/install -c -m 644 m4/amversion.m4 m4/ar-lib.m4 m4/as.m4 m4/auxdir.m4 
m4/cond.m4 m4/cond-if.m4 m4/depend.m4 m4/depout.m4 m4/dmalloc.m4 
m4/extra-recurs.m4 m4/gcj.m4 m4/init.m4 m4/install-sh.m4 m4/lead-dot.m4 
m4/lex.m4 m4/lispdir.m4 m4/maintainer.m4 m4/make.m4 m4/missing.m4 m4/mkdirp.m4 
m4/obsolete.m4 m4/options.m4 m4/python.m4 m4/prog-cc-c-o.m4 m4/runlog.m4 
m4/sanity.m4 m4/silent.m4 m4/strip.m4 m4/substnot.m4 m4/tar.m4 m4/upc.m4 
m4/vala.m4 '/tmp/automake/share/aclocal-1.15'
 /usr/bin/mkdir -p '/tmp/automake/share/aclocal-1.15/internal'
 /usr/bin/install -c -m 644 m4/internal/ac-config-macro-dirs.m4 
'/tmp/automake/share/aclocal-1.15/internal'
 /usr/bin/mkdir -p '/tmp/automake/share/doc/automake'
 /usr/bin/install -c -m 644 ./doc/amhello-1.0.tar.gz 
'/tmp/automake/share/doc/automake'
 /usr/bin/mkdir -p '/tmp/automake/share/automake-1.15/Automake'
 /usr/bin/install -c -m 644 lib/Automake/ChannelDefs.pm 
lib/Automake/Channels.pm lib/Automake/Condition.pm lib/Automake/Configure_ac.pm 
lib/Automake/DisjConditions.pm lib/Automake/FileUtils.pm 
lib/Automake/General.pm lib/Automake/Getopt.pm lib/Automake/Item.pm 
lib/Automake/ItemDef.pm lib/Automake/Language.pm lib/Automake/Location.pm 
lib/Automake/Options.pm lib/Automake/Rule.pm lib/Automake/RuleDef.pm 
lib/Automake/Variable.pm lib/Automake/VarDef.pm lib/Automake/Version.pm 
lib/Automake/XFile.pm lib/Automake/Wrap.pm 
'/tmp/automake/share/automake-1.15/Automake'
 /usr/bin/mkdir -p '/tmp/automake/share/automake-1.15'
 /usr/bin/install -c -m 644 lib/COPYING lib/INSTALL lib/texinfo.tex 
'/tmp/automake/share/automake-1.15'
 /usr/bin/mkdir -p '/tmp/automake/share/automake-1.15'
 /usr/bin/install -c -m 644 lib/config.guess lib/config.sub lib/install-sh 
lib/mdate-sh lib/missing lib/mkinstalldirs lib/ylwrap lib/depcomp lib/compile 
lib/py-compile lib/ar-lib lib/test-driver lib/tap-driver.sh 
'/tmp/automake/share/automake-1.15'
 /usr/bin/mkdir -p '/tmp/automake/share/aclocal'
 /usr/bin/install -c -m 644 m4/acdir/README '/tmp/automake/share/aclocal'
 /usr/bin/mkdir -p '/tmp/automake/share/info'
 /usr/bin/install -c -m 644 ./doc/automake.info ./doc/automake.info-1 
./doc/automake.info-2 ./doc/automake-history.info '/tmp/automake/share/info'
 install-info --info-dir='/tmp/automake/share/info' 
'/tmp/automake/share/info/automake.info'
 install-info --info-dir='/tmp/automake/share/info' 
'/tmp/automake/share/info/automake-history.info'
install-info: warning: no info dir entry in 
`/tmp/automake/share/info/automake-history.info'
 /usr/bin/mkdir -p '/tmp/automake/share/man/man1'
 /usr/bin/install -c -m 644 doc/aclocal.1 doc/automake.1 doc/aclocal-1.15.1 
doc/automake-1.15.1 '/tmp/automake/share/man/man1'
 /usr/bin/mkdir -p '/tmp/automake/share/automake-1.15/Automake'
 /usr/bin/install -c -m 644 lib/Automake/Config.pm 
'/tmp/automake/share/automake-1.15/Automake'
make  install-data-hook
make[2]: Entering directory `/tmp/automake-1.15'
 chmod +x '/tmp/automake/share/automake-1.15/config.guess'
 chmod +x '/tmp/automake/share/automake-1.15/config.sub'
 chmod +x '/tmp/automake/share/automake-1.15/install-sh'
 chmod +x '/tmp/automake/share/automake-1.15/mdate-sh'
 chmod +x '/tmp/automake/share/automake-1.15/missing'
 chmod +x '/tmp/automake/share/automake-1.15/mkinstalldirs'
 chmod +x '/tmp/automake/share/automake-1.15/ylwrap'
 chmod +x '/tmp/automake/share/automake-1.15/depcomp'
 chmod +x '/tmp/automake/share/automake-1.15/compile'
 chmod +x '/tmp/automake/share/automake-1.15/py-compile'
 chmod +x '/tmp/automake/share/automake-1.15/ar-lib'
 chmod +x '/tmp/automake/share/automake-1.15/test-driver'
 chmod +x '/tmp/automake/share/automake-1.15/tap-driver.sh'
make[2]: Leaving directory `/tmp/automake-1.15'
make[1]: Leaving directory `/tmp/automake-1.15'
sh-4.2$ exit
exit

Script done on Fri 30 Dec 2016 06:22:28 AM EST
Script started on Fri 30 Dec 2016 06:22:42 AM EST
sh-4.2$ cd /tmp
sh-4.2$ tar xJf ~/Downloads/automake-1.15.tar.xz
sh-4.2$ cd automake-1.15/
sh-4.2$ ./configure --prefix=/tmp/autom@ke
checking whether make supports nested variables... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether ln -s works... yes
checking for perl... /usr/local/bin/perl
checking for tex... tex
checking for yacc... yacc
checking for lex... lex
checking whether autoconf is installed... yes
checking whether autoconf works... yes
checking whether autoconf is recent enough... yes
checking whether ln works... yes
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
configure: will now look for a sturdy POSIX shell, for our testsuite
checking for sh... /usr/bin/sh
checking for sh5... no
checking for dash... /usr/bin/dash
checking for ash... no
checking for bash... /usr/local/bin/bash
checking for zsh... /usr/local/bin/zsh
checking for ksh... /usr/bin/ksh
checking for pdksh... no
checking whether /usr/bin/sh supports $(cmd)... yes
checking whether /usr/bin/sh supports $((expr))... yes
checking whether /usr/bin/sh supports ${#var}... yes
checking whether /usr/bin/sh supports ${var#glob} and ${var%glob}... yes
checking whether /usr/bin/sh preserves exit traps with "set -e"... yes
checking whether /usr/bin/sh can define exit traps in a shell function... yes
checking whether /usr/bin/sh corrupts stderr with "set -x"... no
checking whether /usr/bin/sh can return early from "dot-sourced" files... yes
checking whether /usr/bin/sh supports alias named like shell builtins... yes
checking whether /usr/bin/sh supports "test -e"... yes
configure: shell /usr/bin/sh is good enough, stop looking
configure: will use /usr/bin/sh as the testsuite shell
configure: will now look for generic compilers
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for aCC... no
checking for CC... no
checking for FCC... no
checking for KCC... no
checking for RCC... no
checking for xlC_r... no
checking for xlC... no
checking for c++... c++
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether c++ accepts -g... yes
checking for xlf95... no
checking for f95... f95
checking whether the Fortran compiler works... yes
checking for Fortran compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU Fortran compiler... yes
checking whether f95 accepts -g... yes
checking for xlf... no
checking for f77... no
checking for frt... no
checking for pgf77... no
checking for cf77... no
checking for fort77... no
checking for fl32... no
checking for af77... no
checking for g77... no
checking for gfortran... gfortran
checking whether the Fortran 77 compiler works... yes
checking for Fortran 77 compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether gfortran accepts -g... yes
configure: will now look for GNU compilers
configure: cc is already a GNU C compiler
configure: c++ is already a GNU C++ compiler
configure: f95 is already a GNU Fortran compiler
configure: gfortran is already a GNU Fortran 77 compiler
checking for gcj... no
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating t/wrap/aclocal-1.15
config.status: creating t/wrap/automake-1.15
sh-4.2$ make
  GEN      bin/automake
  GEN      bin/aclocal
  GEN      t/ax/shell-no-trail-bslash
  GEN      t/ax/cc-no-c-o
  GEN      runtest
  GEN      doc/aclocal.1
  GEN      doc/automake.1
  GEN      lib/Automake/Config.pm
  GEN      doc/aclocal-1.15.1
help2man: can't get `--help' info from aclocal-1.15
Try `--no-discard-stderr' if option outputs to stderr
make: *** [doc/aclocal-1.15.1] Error 2
sh-4.2$ t/wrap/aclocal-1.15 --help
Possible unintended interpolation of @ke in string at 
/tmp/automake-1.15/bin/aclocal line 72.
Global symbol "@ke" requires explicit package name at 
/tmp/automake-1.15/bin/aclocal line 72.
BEGIN not safe after errors--compilation aborted at 
/tmp/automake-1.15/bin/aclocal line 119.
Compilation failed in require at t/wrap/aclocal-1.15 line 29.
sh-4.2$ exit
exit

Script done on Fri 30 Dec 2016 06:23:41 AM EST

Reply via email to