From 116b60f9a4f5dfde7e494f8d48201c2a916f0e43 Mon Sep 17 00:00:00 2001 From: Leah Neukirchen Date: Tue, 30 Jul 2024 21:01:24 +0200 Subject: [PATCH] autogen: patch for guile3. --- .../autogen/patches/autogen-guile-3.0.patch | 50 +++++++++++++++++++ srcpkgs/autogen/patches/configure.patch | 13 ----- srcpkgs/autogen/template | 10 ++-- 3 files changed, 57 insertions(+), 16 deletions(-) create mode 100644 srcpkgs/autogen/patches/autogen-guile-3.0.patch delete mode 100644 srcpkgs/autogen/patches/configure.patch diff --git a/srcpkgs/autogen/patches/autogen-guile-3.0.patch b/srcpkgs/autogen/patches/autogen-guile-3.0.patch new file mode 100644 index 00000000000..0bc44c38c89 --- /dev/null +++ b/srcpkgs/autogen/patches/autogen-guile-3.0.patch @@ -0,0 +1,50 @@ +https://sourceforge.net/p/autogen/bugs/_discuss/thread/9e39945a9c/1a10/attachment/autogen-guile-3.0.patch + +Index: autogen-5.18.16/agen5/guile-iface.h +=================================================================== +--- autogen-5.18.16.orig/agen5/guile-iface.h ++++ autogen-5.18.16/agen5/guile-iface.h +@@ -9,16 +9,13 @@ + # error AutoGen does not work with this version of Guile + choke me. + +-#elif GUILE_VERSION < 203000 ++#else + # define AG_SCM_IS_PROC(_p) scm_is_true( scm_procedure_p(_p)) + # define AG_SCM_LIST_P(_l) scm_is_true( scm_list_p(_l)) + # define AG_SCM_PAIR_P(_p) scm_is_true( scm_pair_p(_p)) + # define AG_SCM_TO_LONG(_v) scm_to_long(_v) + # define AG_SCM_TO_ULONG(_v) ((unsigned long)scm_to_ulong(_v)) + +-#else +-# error unknown GUILE_VERSION +- choke me. + #endif + + #endif /* MUTATING_GUILE_IFACE_H_GUARD */ +Index: autogen-5.18.16/configure +=================================================================== +--- autogen-5.18.16.orig/configure ++++ autogen-5.18.16/configure +@@ -14798,7 +14798,7 @@ $as_echo "no" >&6; } + PKG_CONFIG="" + fi + fi +- _guile_versions_to_search="2.2 2.0 1.8" ++ _guile_versions_to_search="3.0 2.2 2.0 1.8" + if test -n "$GUILE_EFFECTIVE_VERSION"; then + _guile_tmp="" + for v in $_guile_versions_to_search; do +Index: autogen-5.18.16/config/guile.m4 +=================================================================== +--- autogen-5.18.16.orig/config/guile.m4 ++++ autogen-5.18.16/config/guile.m4 +@@ -61,7 +61,7 @@ + # + AC_DEFUN([GUILE_PKG], + [PKG_PROG_PKG_CONFIG +- _guile_versions_to_search="m4_default([$1], [2.2 2.0 1.8])" ++ _guile_versions_to_search="m4_default([$1], [3.0 2.2 2.0 1.8])" + if test -n "$GUILE_EFFECTIVE_VERSION"; then + _guile_tmp="" + for v in $_guile_versions_to_search; do diff --git a/srcpkgs/autogen/patches/configure.patch b/srcpkgs/autogen/patches/configure.patch deleted file mode 100644 index 5b66aaffd49..00000000000 --- a/srcpkgs/autogen/patches/configure.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git configure configure -index f149ede..e75e3f0 100755 ---- a/configure -+++ b/configure -@@ -17324,7 +17324,7 @@ $as_echo_n "checking whether strcspn matches prototype and works... " >&6; } - $as_echo_n "(cached) " >&6 - else - -- if test "$cross_compiling" = yes; then : -+ if test "$cross_compiling" = xxx; then : - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 - $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - as_fn_error $? "cannot run test program while cross compiling diff --git a/srcpkgs/autogen/template b/srcpkgs/autogen/template index 851d17e0c12..84daae958fe 100644 --- a/srcpkgs/autogen/template +++ b/srcpkgs/autogen/template @@ -1,10 +1,10 @@ # Template file for 'autogen' pkgname=autogen version=5.18.16 -revision=2 +revision=3 build_style=gnu-configure -configure_args="--disable-static --disable-dependency-tracking --without-libregex" -hostmakedepends="guile pkg-config perl tar which" +configure_args="--disable-static --disable-dependency-tracking --without-libregex ag_cv_run_strcspn=false" +hostmakedepends="automake guile libtool perl pkg-config tar which" makedepends="guile guile-devel libatomic_ops-devel libxml2-devel gc-devel" depends="guile perl" short_desc="Automated Program Generator" @@ -22,6 +22,10 @@ if [ "$CROSS_BUILD" ]; then hostmakedepends+=" autogen guile-devel" fi +pre_configure() { + autoreconf -fi +} + post_install() { if [ "$SOURCE_DATE_EPOCH" ]; then # repackaging libopts to apply correct mtimes