From 6c73b855fdad70d77ed771b306ef3dbc93d6ba71 Mon Sep 17 00:00:00 2001 From: Jonathan Dieter Date: Tue, 3 Sep 2019 19:48:54 +0100 Subject: [PATCH] Update to final patch as it was merged into libdnf Signed-off-by: Jonathan Dieter --- libdnf-0.35-fix-zchunk.patch | 44 ++++++++++++++++++++++++++++++++++++ libdnf.spec | 5 +++- 2 files changed, 48 insertions(+), 1 deletion(-) diff --git a/libdnf-0.35-fix-zchunk.patch b/libdnf-0.35-fix-zchunk.patch index bfc904d..f98acc4 100644 --- a/libdnf-0.35-fix-zchunk.patch +++ b/libdnf-0.35-fix-zchunk.patch @@ -23,3 +23,47 @@ index 16b63308..c69026d1 100644 if(ENABLE_RHSM_SUPPORT) pkg_check_modules(RHSM REQUIRED librhsm>=0.0.3) include_directories(${RHSM_INCLUDE_DIRS}) +diff --git a/libdnf.spec b/libdnf.spec +index 60091ccf..2e1f958c 100644 +--- a/libdnf.spec ++++ b/libdnf.spec +@@ -32,6 +32,12 @@ + %bcond_with rhsm + %endif + ++%if 0%{?rhel} ++%bcond_with zchunk ++%else ++%bcond_without zchunk ++%endif ++ + %global _cmake_opts \\\ + -DENABLE_RHSM_SUPPORT=%{?with_rhsm:ON}%{!?with_rhsm:OFF} \\\ + %{nil} +@@ -59,6 +65,9 @@ BuildRequires: rpm-devel >= %{rpm_version} + %if %{with rhsm} + BuildRequires: pkgconfig(librhsm) >= 0.0.3 + %endif ++%if %{with zchunk} ++BuildRequires: pkgconfig(zck) >= 0.9.11 ++%endif + BuildRequires: pkgconfig(sqlite3) + BuildRequires: pkgconfig(json-c) + BuildRequires: pkgconfig(cppunit) +@@ -175,14 +184,14 @@ mkdir build-py3 + %build + %if %{with python2} + pushd build-py2 +- %cmake -DPYTHON_DESIRED:FILEPATH=%{__python2} -DWITH_MAN=OFF ../ %{!?with_valgrind:-DDISABLE_VALGRIND=1} %{_cmake_opts} ++ %cmake -DPYTHON_DESIRED:FILEPATH=%{__python2} -DWITH_MAN=OFF ../ %{!?with_zchunk:-DWITH_ZCHUNK=OFF} %{!?with_valgrind:-DDISABLE_VALGRIND=1} %{_cmake_opts} + %make_build + popd + %endif # with python2 + + %if %{with python3} + pushd build-py3 +- %cmake -DPYTHON_DESIRED:FILEPATH=%{__python3} -DWITH_GIR=0 -DWITH_MAN=0 -Dgtkdoc=0 ../ %{!?with_valgrind:-DDISABLE_VALGRIND=1} %{_cmake_opts} ++ %cmake -DPYTHON_DESIRED:FILEPATH=%{__python3} -DWITH_GIR=0 -DWITH_MAN=0 -Dgtkdoc=0 ../ %{!?with_zchunk:-DWITH_ZCHUNK=OFF} %{!?with_valgrind:-DDISABLE_VALGRIND=1} %{_cmake_opts} + %make_build + popd + %endif diff --git a/libdnf.spec b/libdnf.spec index b7dd517..0be4ebf 100644 --- a/libdnf.spec +++ b/libdnf.spec @@ -55,6 +55,9 @@ Patch0001: 0001-Revert-9309e92332241ff1113433057c969cebf127734e.patch Patch0002: 0002-Revert-consequences-of-Fail-Safe-mechanism.patch Patch0003: 0004-Mark-job-goalupgrade-with-sltr-as-targeted.patch Patch0004: 0005-Apply-targeted-upgrade-only-for-selector-with-packages.patch +# Temporary until patch is upstreamed +# https://bugzilla.redhat.com/show_bug.cgi?id=1739867 +Patch0005: libdnf-0.35-fix-zchunk.patch BuildRequires: cmake BuildRequires: gcc @@ -72,7 +75,7 @@ BuildRequires: rpm-devel >= %{rpm_version} BuildRequires: pkgconfig(librhsm) >= 0.0.3 %endif %if %{with zchunk} -BuildRequires: zchunk-devel >= 0.9.11 +BuildRequires: pkgconfig(zck) >= 0.9.11 %endif BuildRequires: pkgconfig(sqlite3) BuildRequires: pkgconfig(json-c)