aboutsummaryrefslogtreecommitdiff
path: root/nx-libs.spec
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2020-11-03 19:55:07 +0100
committerUlrich Sibiller <uli42@gmx.de>2020-11-03 19:55:07 +0100
commit5bd72aec3c45664712c4c88875777e955bb53da3 (patch)
tree57afdac5ede18a27b91c232911be569d15f9c13d /nx-libs.spec
parent1701a4a441d719cd5660cf3550cf2e5a62027a1d (diff)
downloadnx-libs-5bd72aec3c45664712c4c88875777e955bb53da3.tar.gz
nx-libs-5bd72aec3c45664712c4c88875777e955bb53da3.tar.bz2
nx-libs-5bd72aec3c45664712c4c88875777e955bb53da3.zip
nx-libs.spec: Set python shebang to python3 on fedora and rhel8
*** ERROR: ambiguous python shebang in /usr/bin/nxdialog: #!/usr/bin/env python. Change it to python3 (or python2) explicitly. Fedora offers a pythfix.py but I could not test with that so I simply used sed... Fixes ArcticaProject/nx-libs#955
Diffstat (limited to 'nx-libs.spec')
-rw-r--r--nx-libs.spec5
1 files changed, 5 insertions, 0 deletions
diff --git a/nx-libs.spec b/nx-libs.spec
index ddbc16799..7886be14d 100644
--- a/nx-libs.spec
+++ b/nx-libs.spec
@@ -473,6 +473,11 @@ rm -r %{buildroot}%{_includedir}/nx-X11/Xtrans
#Remove our shared libraries' .la files before wrapping up the packages
rm %{buildroot}%{_libdir}/*.la
+# Fix python scripts
+%if 0%{?fedora} >= 23 || 0%{?rhel} >= 8 || 0%{?py_ver} == 3
+sed -i '1 s/python/python3/' %{buildroot}%{_bindir}/nxdialog
+%endif
+
%if 0%{?fdupes:1}
%fdupes %{buildroot}%{_prefix}
%endif