summaryrefslogtreecommitdiffstats
path: root/redhat/main
diff options
context:
space:
mode:
Diffstat (limited to 'redhat/main')
-rw-r--r--redhat/main/tdebindings/tdebindings.spec14
-rw-r--r--redhat/main/tdeedu/tdeedu.spec12
2 files changed, 14 insertions, 12 deletions
diff --git a/redhat/main/tdebindings/tdebindings.spec b/redhat/main/tdebindings/tdebindings.spec
index 141c1d8aa..752b77632 100644
--- a/redhat/main/tdebindings/tdebindings.spec
+++ b/redhat/main/tdebindings/tdebindings.spec
@@ -168,17 +168,17 @@ BuildRequires: Mesa-libGL-devel
BuildRequires: Mesa-libGLU-devel
%endif
-
-## Python
-%if 0%{?rhel} >= 8 || 0%{?fedora} >= 31
-%define python python2
-%define __python %__python2
+# PYTHON support
+%if 0%{?rhel} >= 8 || 0%{?fedora} >= 31 || 0%{?suse_version} >= 1550
+%global python python2
+%global __python %__python2
+%global python_sitearch %{python2_sitearch}
%else
-%define python python
+%global python python
%endif
+%{!?python_sitearch:%global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
BuildRequires: %{python}
BuildRequires: %{python}-devel
-%define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")
## ruby
BuildRequires: ruby-devel >= 1.8
diff --git a/redhat/main/tdeedu/tdeedu.spec b/redhat/main/tdeedu/tdeedu.spec
index 5bd132298..c3d32ba1a 100644
--- a/redhat/main/tdeedu/tdeedu.spec
+++ b/redhat/main/tdeedu/tdeedu.spec
@@ -97,13 +97,15 @@ BuildRequires: %{_lib}usb-compat0.1-devel
BuildRequires: libusb-devel
%endif
-# PYTHON support
-%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 || 0%{?suse_version} >= 1500
-%define python python3
-%define __python %__python3
+# PYTHON3 support
+%if 0%{?rhel} >= 8 || 0%{?fedora} >= 31 || 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150100
+%global python python3
+%global __python %__python3
+%global python_sitearch %{python3_sitearch}
%else
-%define python python
+%global python python
%endif
+%{!?python_sitearch:%global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
BuildRequires: %{python}
BuildRequires: %{python}-devel