1
0
python-rpm-macros/multiple_flavors.patch

35 lines
1.0 KiB
Diff

--- a/compile-macros.sh
+++ b/compile-macros.sh
@@ -1,10 +1,10 @@
#!/bin/bash
-FLAVORS="python2 python3 pypy3"
+FLAVORS="python2 python3 python36 python38 pypy3"
# order of BUILDSET is important, it is copied to order of %pythons,
# and that determines the last installed binary
-BUILDSET="python2 python3"
+BUILDSET="python2 python36 python38"
### flavor-specific: generate from flavor.in
--- a/flavor.in
+++ b/flavor.in
@@ -1,7 +1,5 @@
##### macro definitions for flavor "#FLAVOR#" #####
-%__#FLAVOR# /usr/bin/#FLAVOR#
-
%#FLAVOR#_shbang_opts %py_shbang_opts
%#FLAVOR#_prefix #FLAVOR#
@@ -10,6 +8,8 @@
%#FLAVOR#_version %{_python_sysconfig_var #FLAVOR# py_version_short}
%#FLAVOR#_version_nodots %{_python_sysconfig_var #FLAVOR# py_version_nodot}
+%__#FLAVOR# /usr/bin/python%{#FLAVOR#_version}
+
%#FLAVOR#_sysconfig_path() %{_rec_macro_helper}%{lua:call_sysconfig("path", "#FLAVOR#")}
%#FLAVOR#_sysconfig_var() %{_rec_macro_helper}%{lua:call_sysconfig("var", "#FLAVOR#")}