Skip to content

Commit

Permalink
Work around autoconf 2.69 bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
fingolfin authored and james-d-mitchell committed Sep 11, 2023
1 parent 5c5f780 commit 6c21ed1
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions autogen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,20 @@
# Requires GNU autoconf, GNU automake and GNU libtool.
#
autoreconf -vif `dirname "$0"`

# autoconf 2.69 has a bug where autoreconf does not copy config.guess
# and config.sub even though configure.ac needs them, unless automake is
# being used. We work around this by forcing a call to automake if one
# or both of config.sub and config.guess are missing.
if ! test -x config.guess -a -x config.sub ; then
automake -acf 2> /dev/null || :
fi

# There is a second bug in autoconf 2.69 where the generated configure
# script complains about install-sh not being there (even though it does
# not actually need it). As a workaround, we just provide an empty file
# instead. Since newer autoconf versions such as 2.71 are not affected
# by the bug, we add a test to limit when this workaround is applied
if fgrep -q ac_aux_dir/install-sh configure ; then
touch install-sh
fi

0 comments on commit 6c21ed1

Please sign in to comment.