$ git diff --patch-with-stat --summary d95c6531f090dedfc4173f2c2e3d6b4692f14929..f1925c4d7bf7dbfdd69a49c0ae93884ce59f9203
check-update.sh | 3 +-
octave-parallel.spec | 29 +++---
...ve_7.patch => parallel-4.0.1-fix_octave_8.patch | 102 +++++++++++----------
3 files changed, 68 insertions(+), 66 deletions(-)
rename parallel-4.0.1-fix_octave_7.patch => parallel-4.0.1-fix_octave_8.patch (71%)
diff --git a/check-update.sh b/check-update.sh
index 8afa49f..32ab7b4 100755
--- a/check-update.sh
+++ b/check-update.sh
@@ -1,3 +1,4 @@
#!/bin/sh
-curl https://octave.sourceforge.io/parallel/index.html 2>/dev/null | grep -A1 "<dt>Version</dt>" |sed -ne 's,</dd>.*,,;s,.*<dd>,,p'
+package=parallel
+curl -L https://gnu-octave.github.io/packages/${package}/ 2>/dev/null |sed -ne "s,.*${package}-,,;s,\.tar.\gz,,p" |head -n1
diff --git a/octave-parallel.spec b/octave-parallel.spec
index 5d8666c..afd3c3b 100644
--- a/octave-parallel.spec
+++ b/octave-parallel.spec
@@ -1,24 +1,26 @@
%global octpkg parallel
Summary: Parallel execution package for Octave
-Name: octave-%{octpkg}
+Name: octave-parallel
Version: 4.0.1
-Release: 1
-Url: https://octave.sourceforge.io/%{octpkg}/
+Release: 2
+License: GPLv3+
+Group: Sciences/Mathematics
+Url: https://packages.octave.org/parallel/
Source0: https://downloads.sourceforge.net/octave/%{octpkg}-%{version}.tar.gz
# https://savannah.gnu.org/bugs/index.php?61516
Patch0: honor-cflags-cppflags-cxxflags.patch
# https://savannah.gnu.org/bugs/?62349
-Patch1: parallel-4.0.1-fix_octave_7.patch
-License: GPLv3+
-Group: Sciences/Mathematics
+Patch1: parallel-4.0.1-fix_octave_8.patch
-BuildRequires: octave-devel >= 3.8.0
-BuildRequires: octave-struct >= 1.0.12
+BuildRequires: octave-devel >= 4.0.0
+BuildRequires: octave-struct >= 1.0.12
+BuildRequires: parallel
BuildRequires: pkgconfig(p11-kit-1)
Requires: octave(api) = %{octave_api}
-Requires: octave-struct >= 1.0.12
+Requires: octave-struct >= 1.0.12
+Requires: parallel
Requires(post): octave
Requires(postun): octave
@@ -26,15 +28,13 @@ Requires(postun): octave
%description
Parallel execution package for Octave. See also package octave-mpi.
-This package is part of community Octave-Forge collection.
-
%files
%license COPYING
%doc NEWS
-%dir %{octpkglibdir}
-%{octpkglibdir}/*
%dir %{octpkgdir}
%{octpkgdir}/*
+%dir %{octpkglibdir}
+%{octpkglibdir}/*
%{_metainfodir}/*.metainfo.xml
#---------------------------------------------------------------------------
@@ -42,9 +42,6 @@ This package is part of community Octave-Forge collection.
%prep
%autosetup -p1 -n %{octpkg}-%{version}
-# remove backup files
-#find . -name \*~ -delete
-
%build
%set_build_flags
%octave_pkg_build
diff --git a/parallel-4.0.1-fix_octave_7.patch b/parallel-4.0.1-fix_octave_8.patch
similarity index 71%
rename from parallel-4.0.1-fix_octave_7.patch
rename to parallel-4.0.1-fix_octave_8.patch
index 6dceb82..0a27eb8 100644
--- a/parallel-4.0.1-fix_octave_7.patch
+++ b/parallel-4.0.1-fix_octave_8.patch
@@ -1,6 +1,22 @@
-Files parallel-4.0.1/src/error-helpers.h and parallel-4.0.1.new/src/error-helpers.h differ
---- parallel-4.0.1/src/error-helpers.h 2021-03-17 05:03:09.000000000 +1100
-+++ parallel-4.0.1.new/src/error-helpers.h 2022-02-14 21:24:32.664456607 +1100
+--- a/src/configure
+--- b/src/configure
+@@ -23482,11 +23482,11 @@
+ _ACEOF
+ if ac_fn_cxx_try_compile "$LINENO"; then :
+
+-$as_echo "#define OCTAVE__INTERPRETER__SYMBOL_TABLE__ASSIGN octave::interpreter::the_interpreter () -> get_symbol_table ().assign" >>confdefs.h
++$as_echo "#define OCTAVE__INTERPRETER__SYMBOL_TABLE__ASSIGN octave::interpreter::the_interpreter () -> assign" >>confdefs.h
+
+
+- { $as_echo "$as_me:${as_lineno-$LINENO}: result: octave::interpreter::the_interpreter () -> get_symbol_table ().assign" >&5
+-$as_echo "octave::interpreter::the_interpreter () -> get_symbol_table ().assign" >&6; }
++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: octave::interpreter::the_interpreter () -> assign" >&5
++$as_echo "octave::interpreter::the_interpreter () -> assign" >&6; }
+ echo '
+ ' >> oct-alt-includes.h
+ else
+--- a/src/error-helpers.h
+--- b/src/error-helpers.h
@@ -1,10 +1,10 @@
/*
@@ -65,21 +81,19 @@ Files parallel-4.0.1/src/error-helpers.h and parallel-4.0.1.new/src/error-helper
} \
catch (OCTAVE__EXECUTION_EXCEPTION&) \
{ \
-Files parallel-4.0.1/src/p-control.cc and parallel-4.0.1.new/src/p-control.cc differ
---- parallel-4.0.1/src/p-control.cc 2021-03-17 05:03:09.000000000 +1100
-+++ parallel-4.0.1.new/src/p-control.cc 2022-02-14 21:53:16.406264410 +1100
-@@ -286,7 +286,7 @@
- }
- else
- {
-- nproc_max = num_processors (NPROC_CURRENT);
-+ nproc_max = octave_num_processors_wrapper (NPROC_CURRENT);
+--- a/src/__octave_server__.cc
+--- b/src/__octave_server__.cc
+@@ -317,7 +317,7 @@
+ #endif // HAVE_LIBGNUTLS
- gnulib_pollfds = gnulib_alloc_pollfds (nproc_max);
- }
-Files parallel-4.0.1/src/parallel-gnutls.h and parallel-4.0.1.new/src/parallel-gnutls.h differ
---- parallel-4.0.1/src/parallel-gnutls.h 2021-03-17 05:03:09.000000000 +1100
-+++ parallel-4.0.1.new/src/parallel-gnutls.h 2022-02-14 21:53:10.983290233 +1100
+ // determine own number of usable processor cores
+- uint32_t nproc = num_processors (NPROC_CURRENT);
++ uint32_t nproc = octave_num_processors_wrapper (NPROC_CURRENT);
+
+ // The servers command stream will not be inserted into a
+ // connection object.
+--- a/src/parallel-gnutls.h
+--- b/src/parallel-gnutls.h
@@ -44,7 +44,7 @@
#include <stdint.h>
@@ -98,9 +112,8 @@ Files parallel-4.0.1/src/parallel-gnutls.h and parallel-4.0.1.new/src/parallel-g
}
-Files parallel-4.0.1/src/pconnect.cc and parallel-4.0.1.new/src/pconnect.cc differ
---- parallel-4.0.1/src/pconnect.cc 2021-03-17 05:03:09.000000000 +1100
-+++ parallel-4.0.1.new/src/pconnect.cc 2022-02-14 21:54:24.389940685 +1100
+--- a/src/pconnect.cc
+--- b/src/pconnect.cc
@@ -407,7 +407,7 @@
network->insert_connection (conn, 0);
@@ -110,33 +123,24 @@ Files parallel-4.0.1/src/pconnect.cc and parallel-4.0.1.new/src/pconnect.cc diff
for (uint32_t i = 0; i < nhosts; i++)
{
-Files parallel-4.0.1/src/configure and parallel-4.0.1.new/src/configure differ
---- parallel-4.0.1/src/configure 2021-03-17 05:03:44.766737817 +1100
-+++ parallel-4.0.1.new/src/configure 2022-02-14 21:24:32.667456592 +1100
-@@ -23482,11 +23482,11 @@
- _ACEOF
- if ac_fn_cxx_try_compile "$LINENO"; then :
-
--$as_echo "#define OCTAVE__INTERPRETER__SYMBOL_TABLE__ASSIGN octave::interpreter::the_interpreter () -> get_symbol_table ().assign" >>confdefs.h
-+$as_echo "#define OCTAVE__INTERPRETER__SYMBOL_TABLE__ASSIGN octave::interpreter::the_interpreter () -> assign" >>confdefs.h
-
-
-- { $as_echo "$as_me:${as_lineno-$LINENO}: result: octave::interpreter::the_interpreter () -> get_symbol_table ().assign" >&5
--$as_echo "octave::interpreter::the_interpreter () -> get_symbol_table ().assign" >&6; }
-+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: octave::interpreter::the_interpreter () -> assign" >&5
-+$as_echo "octave::interpreter::the_interpreter () -> assign" >&6; }
- echo '
- ' >> oct-alt-includes.h
- else
-Files parallel-4.0.1/src/__octave_server__.cc and parallel-4.0.1.new/src/__octave_server__.cc differ
---- parallel-4.0.1/src/__octave_server__.cc 2021-03-17 05:03:09.000000000 +1100
-+++ parallel-4.0.1.new/src/__octave_server__.cc 2022-02-14 21:39:50.968098793 +1100
-@@ -317,7 +317,7 @@
- #endif // HAVE_LIBGNUTLS
-
- // determine own number of usable processor cores
-- uint32_t nproc = num_processors (NPROC_CURRENT);
-+ uint32_t nproc = octave_num_processors_wrapper (NPROC_CURRENT);
+--- a/src/p-connection.cc
++++ b/src/p-connection.cc
+@@ -18,6 +18,7 @@ along with this program; If not, see <http://www.gnu.org/licenses/>.
+ */
+
+ #include <octave/oct.h>
++#include <octave/cdef-object.h>
+ #include <octave/Array.cc>
+
+ #include "parallel-gnutls.h"
+--- a/src/p-control.cc
+--- b/src/p-control.cc
+@@ -286,7 +286,7 @@
+ }
+ else
+ {
+- nproc_max = num_processors (NPROC_CURRENT);
++ nproc_max = octave_num_processors_wrapper (NPROC_CURRENT);
- // The servers command stream will not be inserted into a
- // connection object.
+ gnulib_pollfds = gnulib_alloc_pollfds (nproc_max);
+ }