Accepting request 1148328 from KDE:Qt:5.15

- Switch to '%patch -P'
- Build with python 3.11 on Leap

OBS-URL: https://build.opensuse.org/request/show/1148328
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libqt5-qtwebengine?expand=0&rev=94
This commit is contained in:
Ana Guerrero 2024-02-21 16:52:55 +00:00 committed by Git OBS Bridge
commit 6ab6cb6925
2 changed files with 28 additions and 27 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Tue Feb 20 14:42:07 UTC 2024 - Christophe Marin <christophe@krop.fr>
- Switch to '%patch -P'
- Build with python 3.11 on Leap
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Nov 22 09:44:27 UTC 2023 - christophe@krop.fr Wed Nov 22 09:44:27 UTC 2023 - christophe@krop.fr

View File

@ -20,10 +20,12 @@
%bcond_without system_minizip %bcond_without system_minizip
%bcond_without pipewire %bcond_without pipewire
# The default python version is too old on Leap 15 # The default python version is too old on Leap 15
%if 0%{?suse_version} < 1550 %{?sle15_python_module_pythons}
%bcond_without python39 %if 0%{?suse_version} == 1500
%define pyver python311
%else %else
%bcond_without python3 # latest
%define pyver python3
%endif %endif
# spellchecking dictionary directory # spellchecking dictionary directory
@ -100,16 +102,9 @@ BuildRequires: perl-JSON
BuildRequires: pipewire-devel BuildRequires: pipewire-devel
%endif %endif
BuildRequires: pkgconfig BuildRequires: pkgconfig
%if %{with python3} BuildRequires: %{pyver}
BuildRequires: python3 BuildRequires: %{pyver}-devel
BuildRequires: python3-devel BuildRequires: %{pyver}-xml
BuildRequires: python3-xml
%endif
%if %{with python39}
BuildRequires: python39
BuildRequires: python39-devel
BuildRequires: python39-xml
%endif
BuildRequires: re2c BuildRequires: re2c
BuildRequires: sed BuildRequires: sed
BuildRequires: snappy-devel BuildRequires: snappy-devel
@ -292,16 +287,16 @@ Recommends: libqt5-qtpdf-devel
Examples for the libqt5-qtpdf module. Examples for the libqt5-qtpdf module.
%prep %prep
# Leap's rpm doesn't understand '%%autopatch -M N' nor '%%autopatch X Y Z -p1'
%setup -q -n %{tar_version} %setup -q -n %{tar_version}
# Leap 15 doesn't understand '%%autopatch -m' %patch -P0 -p1
%patch0 -p1 %patch -P1 -p1
%patch1 -p1 %patch -P2 -p1
%patch2 -p1 %patch -P3 -p1
%patch3 -p1 %patch -P4 -p1
%patch4 -p1 %patch -P5 -p1
%patch5 -p1 %patch -P6 -p1
%patch6 -p1 %patch -P7 -p1
%patch7 -p1
# Replace the whole catapult folder rather than picking individual changes # Replace the whole catapult folder rather than picking individual changes
pushd src/3rdparty/chromium/third_party pushd src/3rdparty/chromium/third_party
@ -312,8 +307,8 @@ popd
# FFmpeg 5 # FFmpeg 5
%if %{with system_ffmpeg} %if %{with system_ffmpeg}
%if %{pkg_vcmp libavcodec-devel >= 5} %if %{pkg_vcmp pkgconfig(libavcodec) >= 5}
%patch50 -p1 %patch -P50 -p1
%endif %endif
%endif %endif
@ -329,9 +324,9 @@ sed -i -e '/toolprefix = /d' -e 's/\${toolprefix}//g' \
%build %build
rm -r src/3rdparty/chromium/third_party/openh264/src rm -r src/3rdparty/chromium/third_party/openh264/src
%if %{with python39} %if "%{pyver}" == "python311"
sed -i 's#QMAKE_PYTHON = python3#QMAKE_PYTHON = python3.9#' mkspecs/features/functions.prf sed -i 's#QMAKE_PYTHON = python3#QMAKE_PYTHON = python3.11#' mkspecs/features/functions.prf
sed -i 's#python3#python3.9#' configure.pri sed -i 's#python3#python3.11#' configure.pri
%endif %endif
%ifnarch x86_64 %ifnarch x86_64