gnu: fifengine: Fix build with newer Swig and Python.
* gnu/packages/patches/fifengine-swig-compat.patch: New file. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/games.scm (fifengine)[source](patches): New field. [arguments]: Remove hard coded Python version from #:configure-flags.master
parent
e22c2c78a1
commit
5afffbeffc
|
@ -868,6 +868,7 @@ dist_patch_DATA = \
|
||||||
%D%/packages/patches/fasthenry-spSolve.patch \
|
%D%/packages/patches/fasthenry-spSolve.patch \
|
||||||
%D%/packages/patches/fasthenry-spFactor.patch \
|
%D%/packages/patches/fasthenry-spFactor.patch \
|
||||||
%D%/packages/patches/fbreader-curl-7.62.patch \
|
%D%/packages/patches/fbreader-curl-7.62.patch \
|
||||||
|
%D%/packages/patches/fifengine-swig-compat.patch \
|
||||||
%D%/packages/patches/fifo-map-fix-flags-for-gcc.patch \
|
%D%/packages/patches/fifo-map-fix-flags-for-gcc.patch \
|
||||||
%D%/packages/patches/fifo-map-remove-catch.hpp.patch \
|
%D%/packages/patches/fifo-map-remove-catch.hpp.patch \
|
||||||
%D%/packages/patches/findutils-localstatedir.patch \
|
%D%/packages/patches/findutils-localstatedir.patch \
|
||||||
|
|
|
@ -2280,6 +2280,7 @@ Widgets, and allows users to create more.")
|
||||||
(uri (string-append "https://codeload.github.com/fifengine/"
|
(uri (string-append "https://codeload.github.com/fifengine/"
|
||||||
"fifengine/tar.gz/" version))
|
"fifengine/tar.gz/" version))
|
||||||
(file-name (string-append name "-" version ".tar.gz"))
|
(file-name (string-append name "-" version ".tar.gz"))
|
||||||
|
(patches (search-patches "fifengine-swig-compat.patch"))
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"1y4grw25cq5iqlg05rnbyxw1njl11ypidnlsm3qy4sm3xxdvb0p8"))))
|
"1y4grw25cq5iqlg05rnbyxw1njl11ypidnlsm3qy4sm3xxdvb0p8"))))
|
||||||
|
@ -2296,7 +2297,9 @@ Widgets, and allows users to create more.")
|
||||||
"/include/AL")
|
"/include/AL")
|
||||||
(string-append "-DPYTHON_SITE_PACKAGES="
|
(string-append "-DPYTHON_SITE_PACKAGES="
|
||||||
(assoc-ref %outputs "out")
|
(assoc-ref %outputs "out")
|
||||||
"/lib/python3.7/site-packages"))
|
"/lib/python"
|
||||||
|
,(version-major+minor (package-version python))
|
||||||
|
"/site-packages"))
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'patch-run_tests.py
|
(add-after 'unpack 'patch-run_tests.py
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
Fix build failure when using Swig 4.
|
||||||
|
|
||||||
|
Taken from upstream:
|
||||||
|
https://github.com/fifengine/fifengine/commit/d14f232f4cd9a00b05d6872957070e8c020f515d
|
||||||
|
|
||||||
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||||
|
--- a/CMakeLists.txt
|
||||||
|
+++ b/CMakeLists.txt
|
||||||
|
@@ -893,7 +893,7 @@ if(build-python)
|
||||||
|
find_package(PythonLibs ${PYTHON_VERSION_STRING} EXACT)
|
||||||
|
include_directories(${PYTHON_INCLUDE_PATH})
|
||||||
|
|
||||||
|
- set(CMAKE_SWIG_FLAGS -modern -fastdispatch -dirvtable -nosafecstrings -noproxydel -fastproxy -fastinit -fastunpack -fastquery -modernargs -nobuildnone -keyword -w511 -w473 -w404 -w314)
|
||||||
|
+ set(CMAKE_SWIG_FLAGS -modern -fastdispatch -dirvtable -noproxydel -fastproxy -fastinit -fastunpack -fastquery -modernargs -keyword -w511 -w473 -w404 -w314)
|
||||||
|
|
||||||
|
set_source_files_properties("${PROJECT_BINARY_DIR}/fife.i" PROPERTIES CPLUSPLUS ON)
|
||||||
|
set(FIFE_SOURCES ${FIFE_CORE_SRC})
|
Reference in New Issue