From 63973dee0a2fb79f68b53b2bdb4781a64f1b1b24 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Tue, 9 Jan 2024 23:23:41 +0000 Subject: [PATCH 1/4] autoconf271, autoreconfHook271: hold back a version Some package will require significant rework to support autoconf-2.72. Example are `firebird` and `python3Packages.awslambdaric`. Let's leave them on previous version until it's sorted upstream. --- pkgs/development/tools/misc/autoconf/2.71.nix | 69 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 8 ++- 2 files changed, 74 insertions(+), 3 deletions(-) create mode 100644 pkgs/development/tools/misc/autoconf/2.71.nix diff --git a/pkgs/development/tools/misc/autoconf/2.71.nix b/pkgs/development/tools/misc/autoconf/2.71.nix new file mode 100644 index 000000000000..1fcb819bd4b7 --- /dev/null +++ b/pkgs/development/tools/misc/autoconf/2.71.nix @@ -0,0 +1,69 @@ +{ lib, stdenv, fetchurl, m4, perl, texinfo }: + +# Note: this package is used for bootstrapping fetchurl, and thus +# cannot use fetchpatch! All mutable patches (generated by GitHub or +# cgit) that are needed here should be included directly in Nixpkgs as +# files. + +stdenv.mkDerivation rec { + pname = "autoconf"; + version = "2.71"; + outputs = [ "out" "doc" ]; + + src = fetchurl { + url = "mirror://gnu/autoconf/autoconf-${version}.tar.xz"; + sha256 = "197sl23irn6s9pd54rxj5vcp5y8dv65jb9yfqgr2g56cxg7q6k7i"; + }; + patches = [ + # fix stale autom4te cache race condition: + # https://savannah.gnu.org/support/index.php?110521 + ./2.71-fix-race.patch + ]; + + strictDeps = true; + nativeBuildInputs = [ m4 perl texinfo ]; + buildInputs = [ m4 ]; + postBuild = " + make html + "; + + postInstall = " + make install-html + "; + + # Work around a known issue in Cygwin. See + # http://thread.gmane.org/gmane.comp.sysutils.autoconf.bugs/6822 for + # details. + # There are many test failures on `i386-pc-solaris2.11'. + doCheck = ((!stdenv.isCygwin) && (!stdenv.isSunOS)); + + # Don't fixup "#! /bin/sh" in Autoconf, otherwise it will use the + # "fixed" path in generated files! + dontPatchShebangs = true; + + enableParallelBuilding = true; + + # Make the Autotest test suite run in parallel. + preCheck ='' + export TESTSUITEFLAGS="-j$NIX_BUILD_CORES" + ''; + + meta = { + homepage = "https://www.gnu.org/software/autoconf/"; + description = "Part of the GNU Build System"; + + longDescription = '' + GNU Autoconf is an extensible package of M4 macros that produce + shell scripts to automatically configure software source code + packages. These scripts can adapt the packages to many kinds of + UNIX-like systems without manual user intervention. Autoconf + creates a configuration script for a package from a template + file that lists the operating system features that the package + can use, in the form of M4 macro calls. + ''; + + license = lib.licenses.gpl3Plus; + + platforms = lib.platforms.all; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1f86bfebd832..0c56530fe638 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -184,6 +184,9 @@ with pkgs; autoreconfHook269 = autoreconfHook.override { autoconf = autoconf269; }; + autoreconfHook271 = autoreconfHook.override { + autoconf = autoconf271; + }; autorestic = callPackage ../tools/backup/autorestic { }; @@ -18478,14 +18481,13 @@ with pkgs; autobuild = callPackage ../development/tools/misc/autobuild { }; - autoconf = autoconf271; - autoconf-archive = callPackage ../development/tools/misc/autoconf-archive { }; + autoconf = callPackage ../development/tools/misc/autoconf { }; autoconf213 = callPackage ../development/tools/misc/autoconf/2.13.nix { }; autoconf264 = callPackage ../development/tools/misc/autoconf/2.64.nix { }; autoconf269 = callPackage ../development/tools/misc/autoconf/2.69.nix { }; - autoconf271 = callPackage ../development/tools/misc/autoconf { }; + autoconf271 = callPackage ../development/tools/misc/autoconf/2.71.nix { }; acr = callPackage ../development/tools/misc/acr { }; From 24f0289b18ed4e0b32b3e55ddbcf87d93692f278 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Wed, 10 Jan 2024 09:49:28 +0000 Subject: [PATCH 2/4] python3Packages.awslambdaric: pin to `autoconf-2.71` Without the change `python3Packages.awslambdaric` fails the build against `autoconf-2.72` as: python3.11-awslambdaric> checking curl version... 7.83.1 python3.11-awslambdaric> ./configure: line 6673: syntax error near unexpected token `;;' python3.11-awslambdaric> ./configure: line 6673: ` ;;' `python3Packages.awslambdaric` embeds tarballs of external dependencies and is a bit tricky to patch. Let's pin it to a working version. --- pkgs/development/python-modules/awslambdaric/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/awslambdaric/default.nix b/pkgs/development/python-modules/awslambdaric/default.nix index 3e20875ac15d..788148d5e441 100644 --- a/pkgs/development/python-modules/awslambdaric/default.nix +++ b/pkgs/development/python-modules/awslambdaric/default.nix @@ -5,7 +5,7 @@ , fetchpatch , isPy27 , pytestCheckHook -, autoconf +, autoconf271 , automake , cmake , gcc @@ -44,7 +44,7 @@ buildPythonPackage rec { propagatedBuildInputs = [ simplejson ]; - nativeBuildInputs = [ autoconf automake cmake libtool perl setuptools ]; + nativeBuildInputs = [ autoconf271 automake cmake libtool perl setuptools ]; buildInputs = [ gcc ]; From 7684034cd99d49da0dbb90853c1c5df6f4a94aa8 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Wed, 10 Jan 2024 10:19:58 +0000 Subject: [PATCH 3/4] firebird: pin to `autoconf-2.71` Without the change `firebird` builds fail against `autconf-2.72` as: checking for cc_r... gcc ./configure: line 5894: syntax error near unexpected token `;;' ./configure: line 5894: `printf "%s\n" "$as_me: WARNING: --with-system-editline specified, not found. Using bundled editline" >&2;} ;;' Upstream switched to `cmake` for new releases. Let's pin older ones to `autoconf-2.71`. --- pkgs/servers/firebird/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/servers/firebird/default.nix b/pkgs/servers/firebird/default.nix index e49f683da877..7e7387819ab0 100644 --- a/pkgs/servers/firebird/default.nix +++ b/pkgs/servers/firebird/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, libedit, autoreconfHook, zlib, unzip, libtommath, libtomcrypt, icu, superServer ? false }: +{ lib, stdenv, fetchFromGitHub, libedit, autoreconfHook271, zlib, unzip, libtommath, libtomcrypt, icu, superServer ? false }: let base = { pname = "firebird"; @@ -13,7 +13,7 @@ let base = { maintainers = with maintainers; [ marcweber ]; }; - nativeBuildInputs = [ autoreconfHook ]; + nativeBuildInputs = [ autoreconfHook271 ]; buildInputs = [ libedit icu ]; From 62abc91b9fa2bd651bb7bb0a7f7fecb9285130c0 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Fri, 9 Sep 2022 11:40:22 +0100 Subject: [PATCH 4/4] autoconf: 2.71 -> 2.72 Changes: https://lists.gnu.org/archive/html/info-gnu/2023-12/msg00002.html --- pkgs/development/tools/misc/autoconf/default.nix | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/pkgs/development/tools/misc/autoconf/default.nix b/pkgs/development/tools/misc/autoconf/default.nix index 1fcb819bd4b7..8039e36a4f20 100644 --- a/pkgs/development/tools/misc/autoconf/default.nix +++ b/pkgs/development/tools/misc/autoconf/default.nix @@ -7,18 +7,13 @@ stdenv.mkDerivation rec { pname = "autoconf"; - version = "2.71"; + version = "2.72"; outputs = [ "out" "doc" ]; src = fetchurl { url = "mirror://gnu/autoconf/autoconf-${version}.tar.xz"; - sha256 = "197sl23irn6s9pd54rxj5vcp5y8dv65jb9yfqgr2g56cxg7q6k7i"; + hash = "sha256-uohcExlXjWyU1G6bDc60AUyq/iSQ5Deg28o/JwoiP1o="; }; - patches = [ - # fix stale autom4te cache race condition: - # https://savannah.gnu.org/support/index.php?110521 - ./2.71-fix-race.patch - ]; strictDeps = true; nativeBuildInputs = [ m4 perl texinfo ];