From a31b0c586417445f26862d2280983273c4a7db439a90ca9aa3c6c41052d3bdf5 Mon Sep 17 00:00:00 2001 From: Andreas Stieger Date: Wed, 14 Jun 2023 20:58:11 +0000 Subject: [PATCH 1/2] leap OBS-URL: https://build.opensuse.org/package/show/security:privacy/rnp?expand=0&rev=20 --- rnp.changes | 5 +++++ rnp.spec | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/rnp.changes b/rnp.changes index df2826f..de7b132 100644 --- a/rnp.changes +++ b/rnp.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Jun 14 20:57:32 UTC 2023 - Andreas Stieger + +- fix build on Leap (json-c) + ------------------------------------------------------------------- Mon Jun 12 20:32:19 UTC 2023 - Andreas Stieger diff --git a/rnp.spec b/rnp.spec index 1b0a4bb..aa5a0f0 100644 --- a/rnp.spec +++ b/rnp.spec @@ -34,9 +34,9 @@ BuildRequires: gcc-c++ BuildRequires: gpg2 >= 2.2 BuildRequires: gtest BuildRequires: pkgconfig -BuildRequires: cmake(json-c) >= 0.11 BuildRequires: pkgconfig(botan-2) >= 2.14.0 BuildRequires: pkgconfig(bzip2) +BuildRequires: pkgconfig(json-c) >= 0.11 BuildRequires: pkgconfig(zlib) BuildRequires: rubygem(asciidoctor) From 7f3672446236cd6f98f2837bb3e9ce75259a5c75cd796bd984f25469e9cd4c54 Mon Sep 17 00:00:00 2001 From: Andreas Stieger Date: Wed, 14 Jun 2023 21:07:56 +0000 Subject: [PATCH 2/2] Accepting request 1093174 from home:AndreasStieger build with system sexp library OBS-URL: https://build.opensuse.org/request/show/1093174 OBS-URL: https://build.opensuse.org/package/show/security:privacy/rnp?expand=0&rev=21 --- rnp-v0.17.0-gcc13.patch | 21 --------------------- rnp-v0.17.0-system-sexp.patch | 17 +++++++++++++++++ rnp.changes | 7 +++++++ rnp.spec | 14 +++++--------- 4 files changed, 29 insertions(+), 30 deletions(-) delete mode 100644 rnp-v0.17.0-gcc13.patch create mode 100644 rnp-v0.17.0-system-sexp.patch diff --git a/rnp-v0.17.0-gcc13.patch b/rnp-v0.17.0-gcc13.patch deleted file mode 100644 index e647c11..0000000 --- a/rnp-v0.17.0-gcc13.patch +++ /dev/null @@ -1,21 +0,0 @@ -From e665f81ef9568ac5dd4411d6814c75c06262b91c Mon Sep 17 00:00:00 2001 -From: Joonas Niilola -Date: Wed, 3 May 2023 10:31:07 +0300 -Subject: [PATCH] include/sexp/sexp-error.h: fix missing cstdint include - ---- - include/sexp/sexp-error.h | 1 + - 1 file changed, 1 insertion(+) - -Index: rnp-v0.17.0/src/libsexp/include/sexp/sexp-error.h -=================================================================== ---- rnp-v0.17.0.orig/src/libsexp/include/sexp/sexp-error.h -+++ rnp-v0.17.0/src/libsexp/include/sexp/sexp-error.h -@@ -29,6 +29,7 @@ - - #pragma once - -+#include - #include - #include - #include diff --git a/rnp-v0.17.0-system-sexp.patch b/rnp-v0.17.0-system-sexp.patch new file mode 100644 index 0000000..daf1776 --- /dev/null +++ b/rnp-v0.17.0-system-sexp.patch @@ -0,0 +1,17 @@ +Index: rnp-v0.17.0/CMakeLists.txt +=================================================================== +--- rnp-v0.17.0.orig/CMakeLists.txt ++++ rnp-v0.17.0/CMakeLists.txt +@@ -176,10 +176,8 @@ if (ENABLE_FUZZERS) + endif() + add_subdirectory(src/common) + +-set(WITH_SEXP_CLI OFF) +-set(WITH_SEXP_TESTS OFF) +-set(CMAKE_INSTALL_DEFAULT_COMPONENT_NAME development) +-add_subdirectory(src/libsexp EXCLUDE_FROM_ALL) ++find_package(PkgConfig REQUIRED) ++pkg_check_modules(SEXP REQUIRED sexp) + + add_subdirectory(src/lib) + add_subdirectory(src/rnp) diff --git a/rnp.changes b/rnp.changes index de7b132..3f3fd5b 100644 --- a/rnp.changes +++ b/rnp.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Jun 14 21:01:38 UTC 2023 - Andreas Stieger + +- build with system sexp library + (add rnp-v0.17.0-system-sexp.patch) +- drop rnp-v0.17.0-gcc13.patch no longer needed + ------------------------------------------------------------------- Wed Jun 14 20:57:32 UTC 2023 - Andreas Stieger diff --git a/rnp.spec b/rnp.spec index aa5a0f0..f39709e 100644 --- a/rnp.spec +++ b/rnp.spec @@ -28,7 +28,7 @@ Source: https://github.com/rnpgp/rnp/releases/download/v%{version}/%{nam Source2: https://github.com/rnpgp/rnp/releases/download/v%{version}/%{name}-v%{version}.tar.gz.asc Source3: https://www.rnpgp.org/openpgp_keys/31AF5A24D861EFCB7CB79A1924900CE0AEFB5417-50DA59D5B9134FA2DB1EB20CFB829AB5D0FE017F.asc#/%{name}.keyring Patch0: rnp-v0.17.0-disable-static.patch -Patch1: rnp-v0.17.0-gcc13.patch +Patch2: rnp-v0.17.0-system-sexp.patch BuildRequires: cmake >= 3.18 BuildRequires: gcc-c++ BuildRequires: gpg2 >= 2.2 @@ -37,6 +37,7 @@ BuildRequires: pkgconfig BuildRequires: pkgconfig(botan-2) >= 2.14.0 BuildRequires: pkgconfig(bzip2) BuildRequires: pkgconfig(json-c) >= 0.11 +BuildRequires: pkgconfig(sexp) >= 0.8.2 BuildRequires: pkgconfig(zlib) BuildRequires: rubygem(asciidoctor) @@ -44,9 +45,7 @@ BuildRequires: rubygem(asciidoctor) RNP is a set of OpenPGP (RFC4880) tools, an alternative to GnuPG. %package -n librnp%{soname} -%global libsexp_version 0.8.2 Summary: OpenPGP implementation as a C++ library fully compliant with RFC 4880 -Provides: bundled(libsexp) = %{libsexp_version} %description -n librnp%{soname} RNP is a set of OpenPGP (RFC4880) tools, an alternative to GnuPG. @@ -63,15 +62,12 @@ This package contains the files needed to build against librnp. %prep %autosetup -p1 -n %{name}-v%{version} -pushd src/libsexp -cp LICENSE.md ../../LICENSE-libsexp.md -grep -q %{libsexp_version} version.txt -popd +rm -rf src/libsexp %build %cmake \ - -DDOWNLOAD_GTEST=off \ - -DBUILD_TESTING=on \ + -DDOWNLOAD_GTEST:BOOL=OFF \ + -DBUILD_TESTING:BOOL=ON \ %{nil} %cmake_build