GNU bug report logs -
#53780
Automake failing with conditional AC_CONFIG_FILES
Previous Next
To reply to this bug, email your comments to 53780 AT debbugs.gnu.org.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-automake <at> gnu.org
:
bug#53780
; Package
automake
.
(Fri, 04 Feb 2022 15:55:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Valio Valtokari <ubuntugeek1904 <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-automake <at> gnu.org
.
(Fri, 04 Feb 2022 15:55:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hello,
I have a project that supports multiple platforms (windows and linux as of
right now). To implement testing functionality I use a library that I
haven't configured for windows in my project yet. As such, my configure.ac
has these lines:
AC_CONFIG_FILES([Makefile:src/Makefile])
AM_COND_IF([OS_LINUX], [
PKG_CHECK_MODULES([CHECK], [check>=0.9])
AC_CONFIG_FILES([tests/Makefile])
], [])
This seemingly causes automake to crash with:
automake-1.16: error: Makefile:src/Makefile in @other_input_files
automake-1.16: @other_input_files = (Makefile:src/Makefile)
automake-1.16: Please contact <bug-automake <at> gnu.org>.
at /usr/share/automake-1.16/Automake/Channels.pm line 655.
Automake::Channels::msg("automake", "", "Makefile:src/Makefile in
\@other_input_files\x{a}\@other_input_file"...) called at
/usr/share/automake-1.16/Automake/ChannelDefs.pm line 226
Automake::ChannelDefs::prog_error("Makefile:src/Makefile in
\@other_input_files\x{a}\@other_input_file"...) called at
/usr/bin/automake-1.16 line 4311
Automake::handle_configure("tests/Makefile.am",
"tests/Makefile.in", "tests/Makefile", "tests/Makefile.in") called at
/usr/bin/automake-1.16 line 7950
Automake::generate_makefile("tests/Makefile.am",
"tests/Makefile.in") called at /usr/bin/automake-1.16 line 8257
Automake::handle_makefile("tests/Makefile.in") called at
/usr/bin/automake-1.16 line 8269
Automake::handle_makefiles_serial() called at
/usr/bin/automake-1.16 line 8401
autoreconf: error: automake failed with exit status: 255
I'm running on msys2. Any help would be appreciated.
[Message part 2 (text/html, inline)]
Information forwarded
to
bug-automake <at> gnu.org
:
bug#53780
; Package
automake
.
(Fri, 04 Feb 2022 22:12:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 53780 <at> debbugs.gnu.org (full text, mbox):
On 2022-02-04, Valio Valtokari <ubuntugeek1904 <at> gmail.com> wrote:
> Hello,
>
> I have a project that supports multiple platforms (windows and linux as of
> right now). To implement testing functionality I use a library that I
> haven't configured for windows in my project yet. As such, my configure.ac
> has these lines:
>
> AC_CONFIG_FILES([Makefile:src/Makefile])
Automake probably shouldn't crash but this line is a very unusual way to
tell configure to prepare the toplevel Makefile... it says the input to
generate it is src/Makefile (as opposed to the default Makefile.in).
Basically, this tells configure to copy src/Makefile to Makefile (and
apply substitutions).
Automake will not recognize this as something it should do anything with
(it only looks for matching .am files if it sees an input file that ends
with ".in").
I can only reproduce the crash if there is a file named "Makefile.am" in
the both the toplevel directory and in the "tests" directory. The
conditional is irrelevant: this will crash just the same:
AC_CONFIG_FILES([Makefile:src/Makefile tests/Makefile])
Given that, without knowing anything else about your project, I suspect
you probably meant to write:
AC_CONFIG_FILES([Makefile src/Makefile])
to have configure and/or automake prepare two different Makefiles.
Hope that helps,
Nick
Information forwarded
to
bug-automake <at> gnu.org
:
bug#53780
; Package
automake
.
(Sun, 20 Feb 2022 06:41:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 53780 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On 04 Feb 2022 17:12, Valio Valtokari wrote:
> I have a project that supports multiple platforms (windows and linux as of
> right now). To implement testing functionality I use a library that I
> haven't configured for windows in my project yet. As such, my configure.ac
> has these lines:
>
> AC_CONFIG_FILES([Makefile:src/Makefile])
> AM_COND_IF([OS_LINUX], [
> PKG_CHECK_MODULES([CHECK], [check>=0.9])
> AC_CONFIG_FILES([tests/Makefile])
> ], [])
>
> This seemingly causes automake to crash with:
>
> automake-1.16: error: Makefile:src/Makefile in @other_input_files
> automake-1.16: @other_input_files = (Makefile:src/Makefile)
> automake-1.16: Please contact <bug-automake <at> gnu.org>.
> at /usr/share/automake-1.16/Automake/Channels.pm line 655.
> Automake::Channels::msg("automake", "", "Makefile:src/Makefile in
> \@other_input_files\x{a}\@other_input_file"...) called at
> /usr/share/automake-1.16/Automake/ChannelDefs.pm line 226
> Automake::ChannelDefs::prog_error("Makefile:src/Makefile in
> \@other_input_files\x{a}\@other_input_file"...) called at
> /usr/bin/automake-1.16 line 4311
> Automake::handle_configure("tests/Makefile.am",
> "tests/Makefile.in", "tests/Makefile", "tests/Makefile.in") called at
> /usr/bin/automake-1.16 line 7950
> Automake::generate_makefile("tests/Makefile.am",
> "tests/Makefile.in") called at /usr/bin/automake-1.16 line 8257
> Automake::handle_makefile("tests/Makefile.in") called at
> /usr/bin/automake-1.16 line 8269
> Automake::handle_makefiles_serial() called at
> /usr/bin/automake-1.16 line 8401
> autoreconf: error: automake failed with exit status: 255
>
> I'm running on msys2. Any help would be appreciated.
can you link to the project/source ? the snippet you posted isn't complete,
and adding a few more lines doesn't cause automake crash for me.
-mike
[signature.asc (application/pgp-signature, inline)]
Added tag(s) moreinfo.
Request was from
Mike Frysinger <vapier <at> gentoo.org>
to
control <at> debbugs.gnu.org
.
(Sun, 20 Feb 2022 06:41:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-automake <at> gnu.org
:
bug#53780
; Package
automake
.
(Sun, 20 Feb 2022 08:01:01 GMT)
Full text and
rfc822 format available.
Message #16 received at 53780 <at> debbugs.gnu.org (full text, mbox):
On 2022-02-20, Mike Frysinger <vapier <at> gentoo.org> wrote:
> can you link to the project/source ? the snippet you posted isn't
> complete, and adding a few more lines doesn't cause automake crash for me.
Here is a minimal reproducer:
% cat >configure.ac <<'EOF'
AC_INIT([test], [0])
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_FILES([x:y z])
AC_OUTPUT
EOF
% touch x.am
% touch z.am
% autoreconf -is
configure.ac:2: installing './install-sh'
configure.ac:2: installing './missing'
automake-1.16: error: x:y in @other_input_files
[...]
Critically, both x.am and z.am files are required to exist to
reproduce the crash.
The "x" output should be ignored by Automake (since its input
filename, "y", does not end in ".in") but it apparently slightly
confused by the existence of the (should not be used) x.am in the
source tree.
I think this crash will, in practice, only ever happen due to
serious mistakes in configure.ac (i.e., I believe the reporter
has used AC_CONFIG_FILES with the wrong filenames).
Cheers,
Nick
Removed tag(s) moreinfo.
Request was from
Mike Frysinger <vapier <at> gentoo.org>
to
control <at> debbugs.gnu.org
.
(Sun, 20 Feb 2022 19:07:01 GMT)
Full text and
rfc822 format available.
Forcibly Merged 28002 53780.
Request was from
Mike Frysinger <vapier <at> gentoo.org>
to
control <at> debbugs.gnu.org
.
(Sun, 20 Feb 2022 19:07:02 GMT)
Full text and
rfc822 format available.
Added tag(s) confirmed.
Request was from
Mike Frysinger <vapier <at> gentoo.org>
to
control <at> debbugs.gnu.org
.
(Sun, 20 Feb 2022 19:39:01 GMT)
Full text and
rfc822 format available.
This bug report was last modified 3 years and 114 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.