user [email protected]
usertags 1067335 python3.15
tags 1067335 patch
thanks

Hi!

While rebuilding the python related packages against the Python 3.15rc2
version I ran into this FTBFS [1].

To get the package back to building, I had to apply a number of changes:
- Add setuptools build-dependency
- Migrate to use autoconf-archive
- Add upstream patch cd5df1dd: ask python where numpy is [2]
- Add upstream patch b03e4d12: ignore python minor version in test
  result comparison [3]
- Add upstream patch 237d7001: update for swig 4.3 [4]
- Add upstream patch 75e419d6: bump test results [5]
- Dropped obsolete build-deps: g++8 and python

I've applied these fixes in the sandbox [6] to verify that it builds
successfully, these should be applied in Debian to get the package back
to a healthy state.

Also, I noticed that there's a 0.0.6 release from 2020 and that the work
has continued in Git "develop" branch without releases after that. I'm
not sure how useful this package is, given how outdated it is right now,
it might be worth updating to the latest git version.

Happy hacking,

[1]: https://debusine.debian.net/debian/r-python-python3.15/artifact/4587723/
[2]: https:// codeberg 
.org/gnucap/gnucap-python/commit/cd5df1dd6f8cd18faf9b994d4e4655015149be48
[3]: https:// codeberg 
.org/gnucap/gnucap-python/commit/b03e4d12d7e9387910abad6f27daaa68fcdf4287
[4]: https:// codeberg 
.org/gnucap/gnucap-python/commit/237d700162d70cea931fa2758c6157cd1431438f
[5]: https:// codeberg 
.org/gnucap/gnucap-python/commit/75e419d68c6c9531ed64f02c29ee44b236ff3a7f
[6]: https://debusine.debian.net/debian/r-python-python3.15/

--
"Can you imagine what I would do if I could do all I can?" -- Sun Tzu
Saludos /\/\ /\ >< `/
diff -Nru gnucap-python-0.0.2/debian/changelog 
gnucap-python-0.0.2/debian/changelog
--- gnucap-python-0.0.2/debian/changelog        2020-07-30 03:27:14.000000000 
+0200
+++ gnucap-python-0.0.2/debian/changelog        2026-09-09 12:01:58.000000000 
+0200
@@ -1,3 +1,14 @@
+gnucap-python (0.0.2-1.3) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Use autoconf-archive instead of a deprecated ac_python_devel.m4
+  * Add backport of upstream patch cd5df1d to support numpy 2
+  * Add backport of upstream changes to support swig 4.3
+  * Add backport of upstream changes fc21b40 and 3806fca, to
+    fix SONAME detection in configure and ax_soname.m4
+
+ -- Maximiliano Curia <[email protected]>  Wed, 09 Sep 2026 12:01:58 +0200
+
 gnucap-python (0.0.2-1.2) unstable; urgency=medium
 
   * Non-maintainer upload.
diff -Nru gnucap-python-0.0.2/debian/control gnucap-python-0.0.2/debian/control
--- gnucap-python-0.0.2/debian/control  2020-07-30 03:20:12.000000000 +0200
+++ gnucap-python-0.0.2/debian/control  2026-09-09 12:01:58.000000000 +0200
@@ -5,7 +5,8 @@
 Uploaders: Felix Salfelder <[email protected]>
 X-Python3-Version: >= 3.6
 Standards-Version: 4.2.1
-Build-Depends: debhelper (>= 11),
+Build-Depends: autoconf-archive,
+               debhelper (>= 11),
                dh-python,
                dpkg-dev (>=1.17.14),
                gnucap,
@@ -36,11 +37,11 @@
 Package: python3-gnucap
 Section: python
 Architecture: any
-Depends: ${dlopen:Depends},
+Depends: gnucap-default-plugins0,
+         ${dlopen:Depends},
          ${misc:Depends},
          ${python3:Depends},
          ${shlibs:Depends}
-Recommends: gnucap-default-plugins0
 Description: Python 3 bindings for the GNU Circuit Analysis Package
  This package contains Python bindings for the GNU Circuit Analysis Package.
  .
diff -Nru gnucap-python-0.0.2/debian/patches/numpy.patch 
gnucap-python-0.0.2/debian/patches/numpy.patch
--- gnucap-python-0.0.2/debian/patches/numpy.patch      1970-01-01 
01:00:00.000000000 +0100
+++ gnucap-python-0.0.2/debian/patches/numpy.patch      2026-09-09 
12:01:58.000000000 +0200
@@ -0,0 +1,52 @@
+Description: Fix numpy include path detection for NumPy 2.x
+ Use numpy.get_include() to obtain the include directory and check for 
numpy/arrayobject.h.
+ Add NUMPY_DIR to AM_CPPFLAGS in gnucap/Makefile.am.
+Author: Felix Salfelder <[email protected]>
+Forwarded: no
+
+Index: gnucap-python/configure.ac
+===================================================================
+--- gnucap-python.orig/configure.ac
++++ gnucap-python/configure.ac
+@@ -58,6 +58,7 @@ AC_SUBST(ac_python_libdir)
+ AC_SUBST([PYTHON_SITE_PKG])
+ AC_SUBST([GC_CPPFLAGS])
+ AC_SUBST([GC_INCLUDEDIR])
++AC_SUBST([NUMPY_DIR])
+ AC_SUBST([GC_LIBS])
+ AC_SUBST([GC_PKGLIBDIR])
+ AC_SUBST([LIBGNUCAP_SONAME])
+@@ -104,17 +105,16 @@ AS_IF([ test "X$enable_plugpath_override
+ 
+ ## Check for numpy development file
+ AC_PYTHON_MODULE(numpy)
+-NUMPY_DIR="${PYTHON_SITE_PKG}/numpy"
++NUMPY_DIR=$($PYTHON -c 'import numpy; print(numpy.get_include())')
+ AC_ARG_WITH([numpy], [AC_HELP_STRING([--with-numpy=DIR],
+-                     [directory where numpy is installed
+-                      [default=${PYLIBDIR}/numpy] ])],
++                     [numpy install path
++                      [default=${NUMPY_DIR}] ])],
+         NUMPY_DIR=$withval)
+-NUMPY_DIR="${NUMPY_DIR}/core/include/numpy"
+ save_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS -I$NUMPY_DIR"
+ HAS_NUMPY=no
+ 
+-AC_CHECK_HEADER([${NUMPY_DIR}/arrayobject.h],
++AC_CHECK_HEADER([numpy/arrayobject.h],
+                 [ AC_DEFINE(HAS_NUMPY,[],[wether to include numpy support])
+               HAS_NUMPY=yes],[],[#include "Python.h"])
+ CPPFLAGS=$save_CPPFLAGS
+Index: gnucap-python/gnucap/Makefile.am
+===================================================================
+--- gnucap-python.orig/gnucap/Makefile.am
++++ gnucap-python/gnucap/Makefile.am
+@@ -21,6 +21,7 @@ AM_CPPFLAGS = \
+       ${GC_CPPFLAGS} \
+       -I${PYTHON_SITE_PKG} \
+       -DPYTHON_SO=\"@ac_python_libdir@/@ac_python_soname@\"
++AM_CPPFLAGS += -I${NUMPY_DIR}
+ 
+ # common library
+ pkglib_LTLIBRARIES = libgnucap-python.la
diff -Nru gnucap-python-0.0.2/debian/patches/series 
gnucap-python-0.0.2/debian/patches/series
--- gnucap-python-0.0.2/debian/patches/series   1970-01-01 01:00:00.000000000 
+0100
+++ gnucap-python-0.0.2/debian/patches/series   2026-09-09 12:01:58.000000000 
+0200
@@ -0,0 +1,3 @@
+numpy.patch
+swig.patch
+soname.patch
diff -Nru gnucap-python-0.0.2/debian/patches/soname.patch 
gnucap-python-0.0.2/debian/patches/soname.patch
--- gnucap-python-0.0.2/debian/patches/soname.patch     1970-01-01 
01:00:00.000000000 +0100
+++ gnucap-python-0.0.2/debian/patches/soname.patch     2026-09-09 
12:01:58.000000000 +0200
@@ -0,0 +1,40 @@
+Description: Fix SONAME detection in configure and ax_soname.m4
+ - Use mangled C++ symbol _Z11lib_versionv for libgnucap check
+ - Call the symbol in AC_TRY_LINK so the linker includes libgnucap in DT_NEEDED
+ - Fix backslash escaping in shrext_regexp
+ - Use libgnucap.so.0 as fallback instead of unversioned libgnucap.so
+Author: Felix Salfelder <[email protected]>
+Origin: upstream, commit:fc21b40b78a562e9b2972b99fbaa5cacfab7dd26, 
commit:3806fcafe1bb191358bdf45e4df9ff42d10748cc
+Forwarded: no
+
+Index: gnucap-python/configure.ac
+===================================================================
+--- gnucap-python.orig/configure.ac
++++ gnucap-python/configure.ac
+@@ -71,9 +71,9 @@ AC_CONFIG_MACRO_DIR([m4])
+ # export symbols to plugins
+ LDFLAGS="$LDFLAGS -rdynamic $GC_LDFLAGS"
+ 
+-AX_CHECK_LIB_SONAME([LIBGNUCAP], [gnucap], [help_dispatcher], [],
++AX_CHECK_LIB_SONAME([LIBGNUCAP], [gnucap], [_Z11lib_versionv], [],
+                   [AC_MSG_WARN(["cannot find SONAME in -lgnucap, using 
fallback"])
+-                   LIBGNUCAP_SONAME=libgnucap.so ],
++                   LIBGNUCAP_SONAME=libgnucap.so.0 ],
+                   [AC_MSG_ERROR(["cannot link -lgnucap"])])
+ 
+ if test "$enable_debug" = "yes" ; then
+Index: gnucap-python/m4/ax_soname.m4
+===================================================================
+--- gnucap-python.orig/m4/ax_soname.m4
++++ gnucap-python/m4/ax_soname.m4
+@@ -23,8 +23,8 @@ AC_DEFUN([AX_CHECK_LIB_SONAME], [
+           AS_VAR_SET([ac_Lib_SONAME], ["unknown"])
+           AX_CHECK_LIB_SONAME_LIBS="$LIBS"
+           LIBS="$LIBS $7 -l$2"
+-          shrext_regexp=`echo "$shrext_cmds" | sed 's/\./\\\\./'`
+-          AC_TRY_LINK([ ], [ ],
++          shrext_regexp=`echo "$shrext_cmds" | sed 's/\./\\./'`
++          AC_TRY_LINK([ extern "C" { char $3(); } ], [ $3() ],
+               [AS_VAR_SET([ac_Lib_SONAME], [`ldd conftest$ac_exeext | grep 
'lib[$2]'$shrext_regexp | sed 's/^@<:@ 
\t@:>@*lib[$2]'$shrext_regexp'/lib[$2]'$shrext_regexp'/;s/@<:@ \t@:>@.*$//'`])])
+           LIBS="$AX_CHECK_LIB_SONAME_LIBS"
+           AS_IF([test x"$ac_Lib_SONAME" = x ],
diff -Nru gnucap-python-0.0.2/debian/patches/swig.patch 
gnucap-python-0.0.2/debian/patches/swig.patch
--- gnucap-python-0.0.2/debian/patches/swig.patch       1970-01-01 
01:00:00.000000000 +0100
+++ gnucap-python-0.0.2/debian/patches/swig.patch       2026-09-09 
12:01:58.000000000 +0200
@@ -0,0 +1,448 @@
+Description: Update for SWIG 4.3+ and Python 3
+ - Fix PyString / PyInt compatibility in gnucap/numpy.i for Python 3
+ - Use SWIG_AppendOutput instead of SWIG_Python_AppendOutput for SWIG 4.3+
+ - Fix SWIG equality operator syntax formatting in gnucap/Makefile.am
+ - Drop removed top-level SWIG module exports from gnucap/__init__.py.in
+ - Use stream operator << on OMSTREAM instead of removed OMSTREAM__print
+Author: Felix Salfelder <[email protected]>, Pepijn de Vos 
<[email protected]>
+Forwarded: no
+
+Index: gnucap-python/examples/pz_spice.py
+===================================================================
+--- gnucap-python.orig/examples/pz_spice.py
++++ gnucap-python/examples/pz_spice.py
+@@ -20,7 +20,6 @@ from gnucap import ELEMENT
+ from gnucap import node_t
+ from gnucap import XPROBE
+ from gnucap import install_device
+-from gnucap import OMSTREAM__print
+ 
+ sigma = 0
+ 
+Index: gnucap-python/examples/pz_stub.py
+===================================================================
+--- gnucap-python.orig/examples/pz_stub.py
++++ gnucap-python/examples/pz_stub.py
+@@ -17,7 +17,6 @@ from gnucap import ELEMENT
+ from gnucap import node_t
+ from gnucap import XPROBE
+ from gnucap import install_device
+-from gnucap import OMSTREAM__print
+ 
+ sigma = 0
+ 
+@@ -166,7 +165,7 @@ class mysim(SIM):
+ 
+                               self.mysolve()
+                               self.outdata(sigma, 1)
+-                      OMSTREAM__print(self._out, "\n")
++                      self._out.print("\n")
+ 
+       def mysolve(self):
+               n = self.sim_()._total_nodes
+Index: gnucap-python/gnucap/Makefile.am
+===================================================================
+--- gnucap-python.orig/gnucap/Makefile.am
++++ gnucap-python/gnucap/Makefile.am
+@@ -79,6 +79,7 @@ SWIG_FLAGS = -I${GC_INCLUDEDIR}
+ 
+ %.py _%.cxx _%.h: _%.i
+       swig -python -c++ -Wall $(SWIG_FLAGS) -o _$*.cxx $<
++      sed -i 's/ =  = /==/' _$*.{h,cxx}
+ 
+ .i.cxx:
+ 
+Index: gnucap-python/gnucap/__init__.py.in
+===================================================================
+--- gnucap-python.orig/gnucap/__init__.py.in
++++ gnucap-python/gnucap/__init__.py.in
+@@ -20,10 +20,10 @@ else:
+ 
+ from .gnucap_swig import command, parse
+ trace("cmd imported")
+-from .c_comand import CMD, CMD_cmdproc, CMD_command
++from .c_comand import CMD
+ from .c_exp import eval
+ from .component import COMPONENT_ as COMPONENT
+-from .e_base import CKT_BASE_find_wave, CKT_BASE
++from .e_base import CKT_BASE
+ from .e_cardlist import CARD_LIST
+ from .e_elemnt import ELEMENT
+ from .e_node import node_t
+@@ -39,12 +39,16 @@ from .u_xprobe import XPROBE
+ from .ap import CS
+ from .mode import iTOTAL
+ 
+-from ._io_ import OMSTREAM__print, IO_mstdout_get, outset, outreset
++from ._io_ import IO_mstdout_get, outset, outreset
++
++CKT_BASE_find_wave = CKT_BASE.find_wave
++CMD_cmdproc = CMD.cmdproc
++CMD_command = CMD.command
+ 
+ _iomstout = IO_mstdout_get()
+ 
+ def out(s):
+-      OMSTREAM__print(_iomstout, s)
++      _iomstout << s
+ 
+ if(os.name=="posix"):
+       sys.setdlopenflags(oldflags)
+Index: gnucap-python/gnucap/numpy.i
+===================================================================
+--- gnucap-python.orig/gnucap/numpy.i
++++ gnucap-python/gnucap/numpy.i
+@@ -42,6 +42,11 @@
+ #include "stdio.h"
+ #define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
+ #include <numpy/arrayobject.h>
++#if PY_MAJOR_VERSION >= 3
++#define PyString_Check(op)   PyUnicode_Check(op)
++#define PyInt_Check(op)      PyLong_Check(op)
++#define PyInt_AsLong(op)     PyLong_AsLong(op)
++#endif
+ %}
+ 
+ /**********************************************************************/
+@@ -1996,7 +2001,7 @@
+ %typemap(argout)
+   (DATA_TYPE ARGOUT_ARRAY1[ANY])
+ {
+-  $result = SWIG_Python_AppendOutput($result,(PyObject*)array$argnum);
++  $result = SWIG_AppendOutput($result,(PyObject*)array$argnum);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE* ARGOUT_ARRAY1, DIM_TYPE DIM1)
+@@ -2024,7 +2029,7 @@
+ %typemap(argout)
+   (DATA_TYPE* ARGOUT_ARRAY1, DIM_TYPE DIM1)
+ {
+-  $result = SWIG_Python_AppendOutput($result,(PyObject*)array$argnum);
++  $result = SWIG_AppendOutput($result,(PyObject*)array$argnum);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE DIM1, DATA_TYPE* ARGOUT_ARRAY1)
+@@ -2052,7 +2057,7 @@
+ %typemap(argout)
+   (DIM_TYPE DIM1, DATA_TYPE* ARGOUT_ARRAY1)
+ {
+-  $result = SWIG_Python_AppendOutput($result,(PyObject*)array$argnum);
++  $result = SWIG_AppendOutput($result,(PyObject*)array$argnum);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE ARGOUT_ARRAY2[ANY][ANY])
+@@ -2070,7 +2075,7 @@
+ %typemap(argout)
+   (DATA_TYPE ARGOUT_ARRAY2[ANY][ANY])
+ {
+-  $result = SWIG_Python_AppendOutput($result,(PyObject*)array$argnum);
++  $result = SWIG_AppendOutput($result,(PyObject*)array$argnum);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE ARGOUT_ARRAY3[ANY][ANY][ANY])
+@@ -2088,7 +2093,7 @@
+ %typemap(argout)
+   (DATA_TYPE ARGOUT_ARRAY3[ANY][ANY][ANY])
+ {
+-  $result = SWIG_Python_AppendOutput($result,(PyObject*)array$argnum);
++  $result = SWIG_AppendOutput($result,(PyObject*)array$argnum);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE ARGOUT_ARRAY4[ANY][ANY][ANY][ANY])
+@@ -2106,7 +2111,7 @@
+ %typemap(argout)
+   (DATA_TYPE ARGOUT_ARRAY4[ANY][ANY][ANY][ANY])
+ {
+-  $result = SWIG_Python_AppendOutput($result,(PyObject*)array$argnum);
++  $result = SWIG_AppendOutput($result,(PyObject*)array$argnum);
+ }
+ 
+ /*****************************/
+@@ -2131,7 +2136,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DATA_TYPE** ARGOUTVIEW_ARRAY1)
+@@ -2152,7 +2157,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEW_ARRAY2, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2)
+@@ -2174,7 +2179,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** 
ARGOUTVIEW_ARRAY2)
+@@ -2196,7 +2201,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEW_FARRAY2, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2)
+@@ -2218,7 +2223,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array || !require_fortran(array)) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** 
ARGOUTVIEW_FARRAY2)
+@@ -2240,7 +2245,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array || !require_fortran(array)) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEW_ARRAY3, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2264,7 +2269,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3,
+@@ -2288,7 +2293,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEW_FARRAY3, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2312,7 +2317,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array || !require_fortran(array)) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3,
+@@ -2336,7 +2341,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array || !require_fortran(array)) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEW_ARRAY4, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2361,7 +2366,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, 
DIM_TYPE* DIM4,
+@@ -2386,7 +2391,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEW_FARRAY4, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2411,7 +2416,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array || !require_fortran(array)) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, 
DIM_TYPE* DIM4,
+@@ -2436,7 +2441,7 @@
+   PyArrayObject* array = (PyArrayObject*) obj;
+ 
+   if (!array || !require_fortran(array)) SWIG_fail;
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /*************************************/
+@@ -2474,7 +2479,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DATA_TYPE** ARGOUTVIEWM_ARRAY1)
+@@ -2508,7 +2513,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_ARRAY2, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2)
+@@ -2543,7 +2548,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** 
ARGOUTVIEWM_ARRAY2)
+@@ -2578,7 +2583,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_FARRAY2, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2)
+@@ -2613,7 +2618,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DATA_TYPE** 
ARGOUTVIEWM_FARRAY2)
+@@ -2648,7 +2653,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_ARRAY3, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2685,7 +2690,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3,
+@@ -2722,7 +2727,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_FARRAY3, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2759,7 +2764,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3,
+@@ -2796,7 +2801,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_ARRAY4, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2834,7 +2839,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, 
DIM_TYPE* DIM4,
+@@ -2872,7 +2877,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_FARRAY4, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2910,7 +2915,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, 
DIM_TYPE* DIM4,
+@@ -2948,7 +2953,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_ARRAY4, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -2986,7 +2991,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, 
DIM_TYPE* DIM4,
+@@ -3024,7 +3029,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DATA_TYPE** ARGOUTVIEWM_FARRAY4, DIM_TYPE* DIM1, 
DIM_TYPE* DIM2,
+@@ -3062,7 +3067,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /* Typemap suite for (DIM_TYPE* DIM1, DIM_TYPE* DIM2, DIM_TYPE* DIM3, 
DIM_TYPE* DIM4,
+@@ -3100,7 +3105,7 @@
+   PyArray_SetBaseObject(array,cap);
+ %#endif
+ 
+-  $result = SWIG_Python_AppendOutput($result,obj);
++  $result = SWIG_AppendOutput($result,obj);
+ }
+ 
+ /**************************************/
diff -Nru gnucap-python-0.0.2/debian/rules gnucap-python-0.0.2/debian/rules
--- gnucap-python-0.0.2/debian/rules    2020-07-30 03:21:24.000000000 +0200
+++ gnucap-python-0.0.2/debian/rules    2026-09-09 12:01:58.000000000 +0200
@@ -51,11 +51,16 @@
 
        printf "0.0.0\n=====\n* initial release\n" > 
debian/tmp/usr/share/doc/gnucap-python/NEWS
 
+override_dh_autoreconf:
+       [ ! -f m4/ac_python_devel.m4 ] || mv m4/ac_python_devel.m4 
m4/ac_python_devel.m4.bak
+       dh_autoreconf
+
 override_dh_auto_configure: $(PYVERS:%=ac-python%)
 override_dh_auto_build: $(PYVERS:%=ab-python%)
 override_dh_auto_test: $(PYVERS:%=at-python%)
 
 override_dh_clean: $(PYVERS:%=ar-python%)
+       [ ! -f m4/ac_python_devel.m4.bak ] || mv m4/ac_python_devel.m4.bak 
m4/ac_python_devel.m4
        dh_clean
        rm -rf build*
        find . -name *.pyc -delete
@@ -77,4 +82,4 @@
 
 # create dummy binary, linked against gnucap
 debian/tmp.out:
-       echo 'int main(){}' | gcc -lgnucap -x c - -o $@
+       echo 'int main(){}' | gcc -x c - -Wl,--no-as-needed -lgnucap -o $@

Reply via email to