Add patch to support octave 8.1
This commit is contained in:
parent
fa8219acb6
commit
4043e54fe7
81
2512.patch
Normal file
81
2512.patch
Normal file
@ -0,0 +1,81 @@
|
||||
From 8d211ca6732cd0745b196b63ceeedc6cd4f5225c Mon Sep 17 00:00:00 2001
|
||||
From: Andrea L <andrea.latina@cern.ch>
|
||||
Date: Tue, 14 Mar 2023 22:08:30 +0100
|
||||
Subject: [PATCH 1/3] Update octruntime.swg to work with Octave v8.1.0
|
||||
|
||||
---
|
||||
Lib/octave/octruntime.swg | 4 +++-
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Lib/octave/octruntime.swg b/Lib/octave/octruntime.swg
|
||||
index e76151f146b..3a41ba02576 100644
|
||||
--- a/Lib/octave/octruntime.swg
|
||||
+++ b/Lib/octave/octruntime.swg
|
||||
@@ -318,8 +318,10 @@ DEFUN_DLD( SWIG_name, args, nargout, SWIG_name_usage ) {
|
||||
SWIG_InitializeModule(0);
|
||||
SWIG_PropagateClientData();
|
||||
|
||||
-#if SWIG_OCTAVE_PREREQ(6,0,0)
|
||||
+if SWIG_OCTAVE_PREREQ(8,0,0)
|
||||
octave::tree_evaluator& tree_eval = octave::interpreter::the_interpreter()->get_evaluator();
|
||||
+ octave_function *me = tree_eval.current_function();
|
||||
+#elif SWIG_OCTAVE_PREREQ(6,0,0) octave::tree_evaluator& tree_eval = octave::interpreter::the_interpreter()->get_evaluator();
|
||||
octave::call_stack& stack = tree_eval.get_call_stack();
|
||||
octave_function *me = stack.current_function();
|
||||
#elif SWIG_OCTAVE_PREREQ(4,4,0)
|
||||
|
||||
From e8fa1a5018b7ec2c52f98d2161331f3f17489c83 Mon Sep 17 00:00:00 2001
|
||||
From: Andrea L <andrea.latina@cern.ch>
|
||||
Date: Tue, 14 Mar 2023 22:13:21 +0100
|
||||
Subject: [PATCH 2/3] Update octrun.swg to work with Octave v8.1.0
|
||||
|
||||
---
|
||||
Lib/octave/octrun.swg | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Lib/octave/octrun.swg b/Lib/octave/octrun.swg
|
||||
index 2973318c44c..27389d57731 100644
|
||||
--- a/Lib/octave/octrun.swg
|
||||
+++ b/Lib/octave/octrun.swg
|
||||
@@ -1630,8 +1630,12 @@ SWIGRUNTIME void SWIG_Octave_LinkGlobalValue(std::string name) {
|
||||
octave::interpreter *interp = octave::interpreter::the_interpreter ();
|
||||
interp->assign(name, interp->global_varval(name));
|
||||
octave::tree_evaluator& tree_eval = interp->get_evaluator();
|
||||
+#if SWIG_OCTAVE_PREREQ(8,0,0)
|
||||
+ std::shared_ptr<octave::stack_frame> stackFrame = tree_eval.get_current_stack_frame();
|
||||
+#else
|
||||
octave::call_stack& callStack = tree_eval.get_call_stack();
|
||||
- std::shared_ptr<octave::stack_frame> stackFrame = callStack.get_current_stack_frame();
|
||||
+ std::shared_ptr<octave::stack_frame> stackFrame = tree_eval.get_current_stack_frame();
|
||||
+#endif
|
||||
octave::symbol_record sym=symscope.lookup_symbol(name);
|
||||
stackFrame->mark_global(sym);
|
||||
#else
|
||||
|
||||
From ae072d6585bc95ca16cdc0e19f4e227a2ba0a2eb Mon Sep 17 00:00:00 2001
|
||||
From: Andrea L <andrea.latina@cern.ch>
|
||||
Date: Tue, 14 Mar 2023 22:38:21 +0100
|
||||
Subject: [PATCH 3/3] Update octruntime.swg
|
||||
|
||||
---
|
||||
Lib/octave/octruntime.swg | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/Lib/octave/octruntime.swg b/Lib/octave/octruntime.swg
|
||||
index 3a41ba02576..94e2ca4fb9b 100644
|
||||
--- a/Lib/octave/octruntime.swg
|
||||
+++ b/Lib/octave/octruntime.swg
|
||||
@@ -318,10 +318,11 @@ DEFUN_DLD( SWIG_name, args, nargout, SWIG_name_usage ) {
|
||||
SWIG_InitializeModule(0);
|
||||
SWIG_PropagateClientData();
|
||||
|
||||
-if SWIG_OCTAVE_PREREQ(8,0,0)
|
||||
+#if SWIG_OCTAVE_PREREQ(8,0,0)
|
||||
octave::tree_evaluator& tree_eval = octave::interpreter::the_interpreter()->get_evaluator();
|
||||
octave_function *me = tree_eval.current_function();
|
||||
-#elif SWIG_OCTAVE_PREREQ(6,0,0) octave::tree_evaluator& tree_eval = octave::interpreter::the_interpreter()->get_evaluator();
|
||||
+#elif SWIG_OCTAVE_PREREQ(6,0,0)
|
||||
+ octave::tree_evaluator& tree_eval = octave::interpreter::the_interpreter()->get_evaluator();
|
||||
octave::call_stack& stack = tree_eval.get_call_stack();
|
||||
octave_function *me = stack.current_function();
|
||||
#elif SWIG_OCTAVE_PREREQ(4,4,0)
|
@ -56,7 +56,7 @@
|
||||
Summary: Connects C/C++/Objective C to some high-level programming languages
|
||||
Name: swig
|
||||
Version: 4.1.1
|
||||
Release: 4%{?dist}
|
||||
Release: 5%{?dist}
|
||||
License: GPL-3.0-or-later AND BSD-3-Clause
|
||||
URL: http://swig.sourceforge.net/
|
||||
Source0: http://downloads.sourceforge.net/project/swig/swig/swig-%{version}/swig-%{version}.tar.gz
|
||||
@ -68,6 +68,8 @@ Source3: ccache-swig.sh
|
||||
Source4: ccache-swig.csh
|
||||
%endif
|
||||
Patch0: swig-configure-c99.patch
|
||||
# Octave 8.1 support
|
||||
Patch1: https://patch-diff.githubusercontent.com/raw/swig/swig/pull/2512.patch
|
||||
|
||||
BuildRequires: coreutils
|
||||
BuildRequires: findutils
|
||||
@ -346,6 +348,9 @@ install -pm 644 Tools/swig.gdb %{buildroot}%{_datadir}/%{name}/gdb
|
||||
%{_datadir}/%{name}/gdb
|
||||
|
||||
%changelog
|
||||
* Thu Mar 16 2023 Orion Poplawski <orion@nwra.com> - 4.1.1-5
|
||||
- Add patch to support octave 8.1
|
||||
|
||||
* Thu Feb 02 2023 Jitka Plesnikova <jplesnik@redhat.com> - 4.1.1-4
|
||||
- Disable PHP test on i686
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user