- new_python3.patch: enable python 3.11 as valid interpreter

OBS-URL: https://build.opensuse.org/package/show/devel:languages:nodejs/nodejs18?expand=0&rev=10
This commit is contained in:
Adam Majer 2022-09-19 15:01:15 +00:00 committed by Git OBS Bridge
parent 7955725487
commit d969f5eb93
3 changed files with 26 additions and 1 deletions

21
new_python3.patch Normal file
View File

@ -0,0 +1,21 @@
Index: node-v18.9.0/configure
===================================================================
--- node-v18.9.0.orig/configure
+++ node-v18.9.0/configure
@@ -4,6 +4,7 @@
# Note that the mix of single and double quotes is intentional,
# as is the fact that the ] goes on a new line.
_=[ 'exec' '/bin/sh' '-c' '''
+command -v python3.11 >/dev/null && exec python3.11 "$0" "$@"
command -v python3.10 >/dev/null && exec python3.10 "$0" "$@"
command -v python3.9 >/dev/null && exec python3.9 "$0" "$@"
command -v python3.8 >/dev/null && exec python3.8 "$0" "$@"
@@ -22,7 +23,7 @@ except ImportError:
from distutils.spawn import find_executable as which
print('Node.js configure: Found Python {}.{}.{}...'.format(*sys.version_info))
-acceptable_pythons = ((3, 10), (3, 9), (3, 8), (3, 7), (3, 6), (3, 4))
+acceptable_pythons = ((3, 11), (3, 10), (3, 9), (3, 8), (3, 7), (3, 6), (3, 4))
if sys.version_info[:2] in acceptable_pythons:
import configure
else:

View File

@ -24,6 +24,7 @@ Thu Sep 15 15:00:25 UTC 2022 - Adam Majer <adam.majer@suse.de>
- nodejs-libpath.patch, versioned.patch: refreshed
- fix_ci_tests.patch: partially upstreamed
- openssl3_fixups.patch: fix unit tests with openssl 1.1.1
- new_python3.patch: enable python 3.11 as valid interpreter
-------------------------------------------------------------------
Thu Aug 18 10:41:57 UTC 2022 - Adam Majer <adam.majer@suse.de>

View File

@ -171,7 +171,7 @@ Patch133: rsa-pss-revert.patch
Patch200: versioned.patch
Patch303: openssl3_fixups.patch
Patch304: new_python3.patch
BuildRequires: pkg-config
BuildRequires: fdupes
@ -667,6 +667,7 @@ tar Jxf %{SOURCE11}
%patch200 -p1
%patch303 -p1
%patch304 -p1
%if %{node_version_number} <= 12
# minimist security update - patch50
@ -981,9 +982,11 @@ make test-ci
%files devel
%defattr(-, root, root)
%{_includedir}/node%{node_version_number}
%if %{node_version_number} < 18
%dir %{_datadir}/systemtap
%dir %{_datadir}/systemtap/tapset
%{_datadir}/systemtap/tapset/node%{node_version_number}.stp
%endif
%files docs
%defattr(-,root,root)