mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-16 19:50:19 +01:00
academic/ViennaRNA: patch to compile against swig_4.2
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
parent
eb4b9071e6
commit
a31f117413
2 changed files with 25 additions and 0 deletions
|
@ -82,6 +82,9 @@ find -L . \
|
|||
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
|
||||
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
|
||||
|
||||
# https://github.com/ViennaRNA/ViennaRNA/issues/243
|
||||
patch -p1 < $CWD/swig_4.2.0.txt
|
||||
|
||||
# You can configure some ViennaRNA features that are (not) compiled by default.
|
||||
# See the README.md for details. You can enable/disable a these features by
|
||||
# passing variables to the script (VAR=yes/no ./ViennaRNA.SlackBuild).
|
||||
|
|
22
academic/ViennaRNA/swig_4.2.0.txt
Normal file
22
academic/ViennaRNA/swig_4.2.0.txt
Normal file
|
@ -0,0 +1,22 @@
|
|||
Description: rewriting code to build against swig 4.2.0
|
||||
Author: Pierre Gruet <pgt@debian.org>
|
||||
Forwarded: no
|
||||
Last-Update: 2024-07-26
|
||||
|
||||
--- a/interfaces/inverse.i
|
||||
+++ b/interfaces/inverse.i
|
||||
@@ -78,7 +78,14 @@
|
||||
#ifdef SWIGPYTHON
|
||||
%typemap(varin) char * symbolset {
|
||||
free(symbolset);
|
||||
+
|
||||
+#if SWIG_VERSION >= 0x040200
|
||||
+ PyObject *pbytes = NULL;
|
||||
+ symbolset = strdup(SWIG_PyUnicode_AsUTF8AndSize($input, NULL, &pbytes));
|
||||
+ Py_XDECREF(pbytes);
|
||||
+#else
|
||||
symbolset = strdup(SWIG_Python_str_AsChar($input));
|
||||
+#endif
|
||||
}
|
||||
|
||||
%typemap(varout) char * symbolset {
|
Loading…
Reference in a new issue