commit 24987a3274ba632b6d2bb078ff20280bfc55d907
Author: sagitter <sagitter(a)fedoraproject.org>
Date: Thu Jul 25 12:19:11 2019 +0200
Release to 2.5.3| Switch to Python3 definitively
.gitignore | 1 +
sources | 2 +-
xpra-codecs-freeworld.spec | 53 ++++++++++++++++++----------------------------
3 files changed, 23 insertions(+), 33 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 41a96e4..65757d5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -29,3 +29,4 @@ xpra-0.16.3.tar.xz
/xpra-2.5.tar.xz
/xpra-2.5.1.tar.xz
/xpra-2.5.2.tar.xz
+/xpra-2.5.3.tar.xz
diff --git a/sources b/sources
index 5e3c46f..ffd2b6d 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-51e3a3fb388d690e82f47aa0b97fa41c xpra-2.5.2.tar.xz
+2fac9c558c099a6ea13d0202732bd684 xpra-2.5.3.tar.xz
diff --git a/xpra-codecs-freeworld.spec b/xpra-codecs-freeworld.spec
index 29b4e1b..0ca3a3b 100644
--- a/xpra-codecs-freeworld.spec
+++ b/xpra-codecs-freeworld.spec
@@ -9,16 +9,6 @@
%endif
#
-# xpra does not correctly work with Python3 yet
-# Starting from Fedora 30, Python 2 will be no longer supported
-%if %{?fedora} < 29
-%global py_prefix 2
-%global pythonx_sitearch %python2_sitearch
-%else
-%global py_prefix 3
-%global pythonx_sitearch %python3_sitearch
-%endif
-
# These are nececessary as the _with_foo is *not* defined if the
# --with flag isn't specifed, and we need to have the --without
# specified option in that case.
@@ -35,22 +25,22 @@
%endif
Name: xpra-codecs-freeworld
-Version: 2.5.2
-Release: 2%{?dist}
+Version: 2.5.3
+Release: 1%{?dist}
Summary: Additional codecs for xpra using x264 and ffmpeg
License: GPLv2+
URL:
http://www.xpra.org/
Source0:
http://xpra.org/src/xpra-%{version}.tar.xz
-BuildRequires: python%py_prefix-devel
-BuildRequires: pygobject%py_prefix-devel
-BuildRequires: python%py_prefix-cairo-devel
+BuildRequires: python3-devel
+BuildRequires: pygobject3-devel
+BuildRequires: python3-cairo-devel
BuildRequires: pygtk2-devel
BuildRequires: gtk3-devel
BuildRequires: libXtst-devel, uglify-js
BuildRequires: libxkbfile-devel, libvpx-devel
BuildRequires: xvidcore-devel, x265-devel
-BuildRequires: python%py_prefix-Cython, ack
+BuildRequires: python3-Cython, ack
BuildRequires: gcc
BuildRequires: libwebp-devel
BuildRequires: libXdamage-devel
@@ -76,7 +66,7 @@ x264 and ffmpeg.
%autosetup -n xpra-%{version}
%build
-CFLAGS="%{optflags}" %{_bindir}/python%py_prefix setup.py build
--executable="%{_bindir}/python%py_prefix -s" \
+CFLAGS="%{optflags}" %{__python3} setup.py build
--executable="%{__python3} -s" \
%{?_with_enc_x264} \
%{?_with_dec_avcodec2} \
%{?_with_csc_swscale} \
@@ -87,18 +77,16 @@ CFLAGS="%{optflags}" %{_bindir}/python%py_prefix setup.py
build --executable="%
--without-html5 \
--without-tests \
--with-verbose \
-%if 0%{?fedora} > 27
--without-strict \
-%endif
--without-html5_gzip --without-html5_brotli
%install
-%{_bindir}/python%py_prefix setup.py install -O1 --skip-build --root destdir \
+%{__python3} setup.py install -O1 --skip-build --root destdir \
--without-html5_gzip --without-html5_brotli
## We are interested to additional codecs only
-mkdir -p %{buildroot}%{pythonx_sitearch}/xpra/codecs/
-pushd destdir%{pythonx_sitearch}/xpra/codecs/
+mkdir -p %{buildroot}%{python3_sitearch}/xpra/codecs/
+pushd destdir%{python3_sitearch}/xpra/codecs/
cp -pr \
%if %{with csc_swscale}
csc_swscale \
@@ -109,29 +97,30 @@ cp -pr \
%if %{with enc_x264}
enc_x264 \
%endif
- libav_common enc_ffmpeg enc_x265 %{buildroot}%{pythonx_sitearch}/xpra/codecs/
+ libav_common enc_ffmpeg enc_x265 %{buildroot}%{python3_sitearch}/xpra/codecs/
popd
-#fix shebangs from pythonX_sitearch
-find %{buildroot}%{pythonx_sitearch}/xpra -name '*.py' | xargs sed -i
'1s|^#!/usr/bin/env python|#!%{_bindir}/python%py_prefix|'
-for i in `ack -rl '^#!/.*python' %{buildroot}%{pythonx_sitearch}/xpra`; do
+#fix shebangs from python3_sitearch
+find %{buildroot}%{python3_sitearch}/xpra -name '*.py' | xargs sed -i
'1s|^#!/usr/bin/env python|#!%{__python3}|'
+for i in `ack -rl '^#!/.*python' %{buildroot}%{python3_sitearch}/xpra`; do
chmod 0755 $i
done
#fix permissions on shared objects
-find %{buildroot}%{pythonx_sitearch}/xpra -name '*.so' \
+find %{buildroot}%{python3_sitearch}/xpra -name '*.so' \
-exec chmod 0755 {} \;
%files
-%dir %{pythonx_sitearch}/xpra
-%dir %{pythonx_sitearch}/xpra/codecs
-%{pythonx_sitearch}/xpra/codecs/*
+%dir %{python3_sitearch}/xpra
+%dir %{python3_sitearch}/xpra/codecs
+%{python3_sitearch}/xpra/codecs/*
%doc README NEWS
%license COPYING
%changelog
-* Tue Jul 02 2019 Nicolas Chauvet <kwizart(a)gmail.com> - 2.5.2-2
-- Rebuilt for x265
+* Thu Jul 25 2019 Antonio Trande <sagitter(a)fedoraproject.org> - 2.5.3-1
+- Release to 2.5.3
+- Switch to Python3 definitively
* Sat Jun 08 2019 Antonio Trande <sagitter(a)fedoraproject.org> - 2.5.2-1
- Release to 2.5.2