From 764fd26af504ff31833c0f765037daeab1e5cb6211d34833e250bee279a03b47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 5 Dec 2017 12:01:54 +0000 Subject: [PATCH] - Make sure we switch to python3 only on SLE15+ and not on SLE12 OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/graphite2?expand=0&rev=52 --- graphite2.changes | 5 +++++ graphite2.spec | 8 +++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/graphite2.changes b/graphite2.changes index 66ad274..9696d7b 100644 --- a/graphite2.changes +++ b/graphite2.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Dec 5 12:03:29 UTC 2017 - tchvatal@suse.com + +- Make sure we switch to python3 only on SLE15+ and not on SLE12 + ------------------------------------------------------------------- Mon Nov 20 12:16:37 UTC 2017 - mpluskal@suse.com diff --git a/graphite2.spec b/graphite2.spec index d0da03d..687f284 100644 --- a/graphite2.spec +++ b/graphite2.spec @@ -40,7 +40,11 @@ BuildRequires: freetype2-devel BuildRequires: gcc-c++ BuildRequires: glib2-devel BuildRequires: pkgconfig -BuildRequires: python3 +%if %{suse_version} >= 1330 +BuildRequires: python3-base +%else +BuildRequires: python-base +%endif %description Graphite2 is a project within SIL's Non-Roman Script Initiative and Language @@ -88,8 +92,10 @@ This package contains the %{name} development files. %build # Make sure to use python3 everywhere +%if %{suse_version} >= 1330 find tests -type f -exec sed -i "s|python|python3|g" {} + find . -name *.cmake -exec sed -i "s|python|python3|g" {} + +%endif %cmake \ -DGRAPHITE2_COMPARE_RENDERER=OFF \ -DGRAPHITE2_NTRACING=ON \