Rebase to version 1.16.3 (#1899388)

This commit is contained in:
Ondrej Dubaj 2021-03-19 08:55:31 +01:00
parent 3b5d84703d
commit c3fe43baf6
7 changed files with 104 additions and 173 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
/automake-1.16.1.tar.xz
/automake-1.16.2.tar.xz
/automake-1.16.3.tar.xz

View File

@ -1,28 +0,0 @@
From: Pavel Raiskup <praiskup@redhat.com>
Date: Tue, 7 Jul 2015 11:46:24 +0200
Subject: [PATCH] tests: disable vala testcases
Currently broken vala installation in Fedora? Upstream thread:
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=12522
diff --git a/t/list-of-tests.mk b/t/list-of-tests.mk
index 9363ee3..b99f15c 100644
--- a/t/list-of-tests.mk
+++ b/t/list-of-tests.mk
@@ -1239,16 +1239,6 @@ t/upc2.sh \
t/upc3.sh \
t/vala-configure.sh \
t/vala-grepping.sh \
-t/vala-headers.sh \
-t/vala-libs.sh \
-t/vala-mix.sh \
-t/vala-mix2.sh \
-t/vala-non-recursive-setup.sh \
-t/vala-parallel.sh \
-t/vala-per-target-flags.sh \
-t/vala-recursive-setup.sh \
-t/vala-vapi.sh \
-t/vala-vpath.sh \
t/vars.sh \
t/vars3.sh \
t/var-recurs.sh \

View File

@ -1,48 +0,0 @@
diff --git a/lib/am/python.am b/lib/am/python.am
index 21e6f842c..e29ecfcd0 100644
--- a/lib/am/python.am
+++ b/lib/am/python.am
@@ -97,7 +97,7 @@ endif %?INSTALL%
if %?INSTALL%
?FIRST?am__pep3147_tweak = \
-?FIRST? sed -e 's|\.py$$||' -e 's|[^/]*$$|&.*.pyc\n&.*.pyo|'
+?FIRST? sed -e 's|\.py$$||' -e 's|[^/]*$$|__pycache__/&.*.py|'
.PHONY uninstall-am: uninstall-%DIR%PYTHON
uninstall-%DIR%PYTHON:
@@ -108,19 +108,26 @@ uninstall-%DIR%PYTHON:
test -n "$$py_files" || exit 0; \
dir='$(DESTDIR)$(%NDIR%dir)'; \
## Also remove the .pyc and .pyo byte compiled versions.
+## This is somewhat tricky, because for newer pythons we have to take
+## PEP-3147 into account.
pyc_files=`echo "$$py_files" | sed 's|$$|c|'`; \
pyo_files=`echo "$$py_files" | sed 's|$$|o|'`; \
+ py_files_pep3147=`echo "$$py_files" | $(am__pep3147_tweak)`; \
+ echo "$$py_files_pep3147";\
+ pyc_files_pep3147=`echo "$$py_files_pep3147" | sed 's|$$|c|'`; \
+ pyo_files_pep3147=`echo "$$py_files_pep3147" | sed 's|$$|o|'`; \
st=0; \
- for files in "$$py_files" "$$pyc_files" "$$pyo_files"; do \
+ for files in \
+ "$$py_files" \
+ "$$pyc_files" \
+ "$$pyo_files" \
+## Installation of '.py' files is not influenced by PEP-3147, so it
+## is correct *not* to have $pyfiles_pep3147 here.
+ "$$pyc_files_pep3147" \
+ "$$pyo_files_pep3147" \
+ ; do \
$(am__uninstall_files_from_dir) || st=$$?; \
done; \
-## This is somewhat tricky, because for newer pythons we have to take PEP-3147
-## into account. Avoid exceeding the command-line length limit.
- dir='$(DESTDIR)$(%NDIR%dir)/__pycache__'; \
- echo "$$py_files" | $(am__pep3147_tweak) | $(am__base_list) | \
- while read files; do \
- $(am__uninstall_files_from_dir) || st=$$?; \
- done || exit $$?; \
exit $$st
endif %?INSTALL%

View File

@ -1,84 +0,0 @@
From e21d46fddd0753e66a4acda88317670fee07f3e6 Mon Sep 17 00:00:00 2001
From: "Miro Hron\\v{c}ok" <miro@hroncok.cz>
Date: Tue, 27 Oct 2020 14:33:46 -0700
Subject: [PATCH] python: determine Python (3.10) version number correctly.
This change fixes https://bugs.gnu.org/44239
(and https://bugzilla.redhat.com/show_bug.cgi?id=1889732).
* m4/python.m4: use print('%u.%u' % sys.version_info[:2]) for
the version number instead of merely sys.version[:3], so the
numbers are treated as numbers.
* t/python-vars.sh (PYTHON_VERSION): Likewise.
* doc/automake.texi: Document it.
* NEWS: mention it. (Minor tweaks from Karl Berry.)
---
NEWS | 2 ++
doc/automake.texi | 2 +-
m4/python.m4 | 12 +++++++-----
t/python-vars.sh | 4 +++-
4 files changed, 13 insertions(+), 7 deletions(-)
diff --git a/doc/automake.texi b/doc/automake.texi
index ed7e2e242..17bc2dae6 100644
--- a/doc/automake.texi
+++ b/doc/automake.texi
@@ -7861,7 +7861,7 @@ AM_CONDITIONAL([HAVE_PYTHON], [test "$PYTHON" != :])
@item PYTHON_VERSION
The Python version number, in the form @var{major}.@var{minor}
(e.g., @samp{2.5}). This is currently the value of
-@samp{sys.version[:3]}.
+@samp{'%u.%u' % sys.version_info[:2]}.
@item PYTHON_PREFIX
The string @samp{$@{prefix@}}. This term may be used in future work
diff --git a/m4/python.m4 b/m4/python.m4
index 16c2f4f1a..b2302baa3 100644
--- a/m4/python.m4
+++ b/m4/python.m4
@@ -1,7 +1,7 @@
## ------------------------ -*- Autoconf -*-
## Python file handling
## From Andrew Dalke
-## Updated by James Henstridge
+## Updated by James Henstridge and other contributors.
## ------------------------
# Copyright (C) 1999-2020 Free Software Foundation, Inc.
#
@@ -86,12 +86,14 @@ AC_DEFUN([AM_PATH_PYTHON],
m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])])
else
- dnl Query Python for its version number. Getting [:3] seems to be
- dnl the best way to do this; it's what "site.py" does in the standard
- dnl library.
+ dnl Query Python for its version number. Although site.py simply uses
+ dnl sys.version[:3], printing that failed with Python 3.10, since the
+ dnl trailing zero was eliminated. So now we output just the major
+ dnl and minor version numbers, as numbers. Apparently the tertiary
+ dnl version is not of interest.
AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version],
- [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`])
+ [am_cv_python_version=`$PYTHON -c "import sys; print('%u.%u' % sys.version_info[[:2]])"`])
AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
dnl Use the values of $prefix and $exec_prefix for the corresponding
diff --git a/t/python-vars.sh b/t/python-vars.sh
index 5c748bcf1..b53018b37 100644
--- a/t/python-vars.sh
+++ b/t/python-vars.sh
@@ -28,7 +28,9 @@ CONFIG_SITE=/dev/null; export CONFIG_SITE
# vary among different python installations, so we need more relaxed
# and ad-hoc checks for them. Also, more proper "functional" checks
# on them should be done in the 'python-virtualenv.sh' test.
-PYTHON_VERSION=$($PYTHON -c 'import sys; print(sys.version[:3])') || exit 1
+#
+# This version identification is duplicated in python.m4 (and the manual).
+PYTHON_VERSION=$($PYTHON -c 'import sys; print("%u.%u" % sys.version_info[:2])') || exit 1
PYTHON_PLATFORM=$($PYTHON -c 'import sys; print(sys.platform)') || exit 1
PYTHON_EXEC_PREFIX='${exec_prefix}'
PYTHON_PREFIX='${prefix}'
--
2.29.0

View File

@ -0,0 +1,94 @@
From: Zack Weinberg <zackw@panix.com>
Subject: [PATCH] Autoconf 2.71 (released last week) makes a few changes
that broke Automakes expectations, mostly in the test suite. This
patch addresses two of the problems:
- autoconf now issues a warning if fed a configure script that doesnt invoke
both AC_INIT and AC_OUTPUT; this, plus a problem with system-provided
tools (still under investigation) broke the *build* on macOS; it also
causes a couple of spurious testsuite failures.
- AC_PACKAGE_NAME and AC_PACKAGE_VERSION are now defined unconditionally.
AM_INIT_AUTOMAKE needs to use m4_ifset instead of m4_ifdef to diagnose
the obsolete use of AC_INIT with fewer than two arguments. (This change
is compatible with autoconf 2.69; m4_ifset is much older, and it means
defined with a non-empty value.)
* configure.ac: Use both AC_INIT and AC_OUTPUT in test configure scripts.
* t/deprecated-acinit.sh, t/init.sh: Likewise.
* m4/init.m4 (AM_INIT_AUTOMAKE): Use m4_ifset, not m4_ifdef, to detect
AC_PACKAGE_NAME and/or AC_PACKAGE_VERSION not having a value.
---
configure.ac | 9 +++++++--
m4/init.m4 | 2 +-
t/deprecated-acinit.sh | 1 +
t/init.sh | 1 +
4 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
index 15d3f8e..e3a0df2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -123,7 +123,9 @@ fi
AC_CACHE_CHECK([whether autoconf works], [am_cv_autoconf_works],
[mkdir conftest
-echo 'AC''_INIT' > conftest/conftest.ac
+printf '%s\n' > conftest/conftest.ac \
+ 'AC''_INIT([smoke-test], [1])' \
+ 'AC''_OUTPUT'
if AM_RUN_LOG([cd conftest && $am_AUTOCONF -o /dev/null conftest.ac]);
then
am_cv_autoconf_works=yes
@@ -139,7 +141,10 @@ fi
AC_CACHE_CHECK([whether autoconf is recent enough], [am_cv_autoconf_version],
[mkdir conftest
dnl Creative quoting required to avoid spurious expansion of AC_PREREQ macro
-echo 'AC'"_PREREQ([[$required_autoconf_version]])" > conftest/conftest.ac
+printf '%s\n' > conftest/conftest.ac \
+ 'AC'"_PREREQ([[$required_autoconf_version]])" \
+ 'AC''_INIT([smoke-test], [1])' \
+ 'AC''_OUTPUT'
if AM_RUN_LOG([cd conftest && $am_AUTOCONF -o /dev/null conftest.ac]);
then
am_cv_autoconf_version=yes
diff --git a/m4/init.m4 b/m4/init.m4
index ba73676..339a167 100644
--- a/m4/init.m4
+++ b/m4/init.m4
@@ -64,7 +64,7 @@ m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
[_AM_SET_OPTIONS([$1])dnl
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
m4_if(
- m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
+ m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
[ok:ok],,
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
diff --git a/t/deprecated-acinit.sh b/t/deprecated-acinit.sh
index 21614ba..f393d65 100644
--- a/t/deprecated-acinit.sh
+++ b/t/deprecated-acinit.sh
@@ -35,6 +35,7 @@ for ac_init in AC_INIT 'AC_INIT([Makefile.am])'; do
$ac_init
$am_init_automake
AC_CONFIG_FILES([Makefile])
+ AC_OUTPUT
END
cat configure.ac # For debugging.
$ACLOCAL 2>stderr && { cat stderr >&2; exit 1; }
diff --git a/t/init.sh b/t/init.sh
index c6f6d64..df138a0 100644
--- a/t/init.sh
+++ b/t/init.sh
@@ -25,6 +25,7 @@ for ac_init_args in '' '([x])'; do
unindent >configure.ac <<END
AC_INIT$ac_init_args
AM_INIT_AUTOMAKE$am_init_args
+ AC_OUTPUT
END
cat configure.ac # For debugging.
# The error message should mention AC_INIT, not AC_PACKAGE_VERSION.
--
2.26.0

View File

@ -14,8 +14,8 @@
Summary: A GNU tool for automatically creating Makefiles
Name: automake
# Any bump here requires libtool rebuild, rhbz#1813010
Version: %{api_version}.2
Release: 5%{?dist}
Version: %{api_version}.3
Release: 1%{?dist}
# docs ~> GFDL, sources ~> GPLv2+, mkinstalldirs ~> PD and install-sh ~> MIT
License: GPLv2+ and GFDL and Public Domain and MIT
@ -24,15 +24,10 @@ Source: ftp://ftp.gnu.org/gnu/automake/automake-%{version}.tar.xz
Source2: http://git.savannah.gnu.org/cgit/config.git/plain/config.sub
Source3: http://git.savannah.gnu.org/cgit/config.git/plain/config.guess
# Keep those patches in 'git format-patch' format (with docs).
%if %{with check} && !%{without automake_enables_optional_test}
Patch0: automake-1.15-disable-vala-tests.patch
%endif
# Fix test failures with autoconf-2.71
# https://git.savannah.gnu.org/cgit/automake.git/commit/?id=ccb57553e3433df3e52e534e6f87915db23ff9a5
Patch0: automake-1.16.3-fix-testsuite-failures-with-autoconf-2.71.patch
# Support multiple digits in Python version, e.g. Python 3.10
# Taken from upstream commit (NEWS hunks removed due to conflicts)
# https://debbugs.gnu.org/cgi/bugreport.cgi?bug=44239
Patch1: automake-1.16.2-python-version-multiple-digits.patch
URL: http://www.gnu.org/software/automake/
Requires: autoconf >= 2.65
@ -108,8 +103,6 @@ done
%build
# disable replacing config.guess and config.sub from redhat-rpm-config
%global _configure_gnuconfig_hack 0
%configure
%make_build
cp m4/acdir/README README.aclocal
@ -142,6 +135,9 @@ make -k %{?_smp_mflags} check %{?TESTS_FLAGS: TESTS="%{TESTS_FLAGS}"} \
%changelog
* Wed Feb 24 2021 Ondrej Dubaj <odubaj@redhat.com> - 1.16.3-1
- Rebase to upstream version 1.16.3
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.16.2-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild

View File

@ -1 +1 @@
SHA512 (automake-1.16.2.tar.xz) = a4aa0e41ceaa7df5bc303a6004597fb158f4198594017cd2c586fd9f5a29233e081766bf22b7e4ef0d4c8c3d45a8591009427efa319b362922a958ac1ef6e27b
SHA512 (automake-1.16.3.tar.xz) = 7265aeb7f82a8a205761d76e6ade7b7e97831c283349fd80f86e511f4b0b3e17f429d1506fca84c76079f63781e5dbf5ca81455d6bf6cda27d2e5c3d23b0d1aa