From 80cb2f5e13b902e63785d307e0cffbe0d773a76c Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Wed, 29 Mar 2017 07:08:55 +0200 Subject: [PATCH] Update to 1.9.0 Signed-off-by: Igor Gnatenko --- 0001-add-missing-include-functional.patch | 48 ------------------- ...on-t-add-extra-libraries-for-linking.patch | 47 ++++++++++++++++++ 0001-fix-stupid-ax_python_devel.patch | 27 +++++++++++ 0001-qt-pass-fmt-to-gpgrt_asprintf.patch | 27 +++++++++++ ...ve-a-forgotten-instance-of-libsuffix.patch | 33 ------------- gpgme-1.7.0-confix_extras.patch | 19 -------- gpgme-1.8.0-cmake_extras.patch | 12 ----- gpgme.spec | 40 ++++++++-------- sources | 2 +- 9 files changed, 123 insertions(+), 132 deletions(-) delete mode 100644 0001-add-missing-include-functional.patch create mode 100644 0001-don-t-add-extra-libraries-for-linking.patch create mode 100644 0001-fix-stupid-ax_python_devel.patch create mode 100644 0001-qt-pass-fmt-to-gpgrt_asprintf.patch delete mode 100644 0002-Remove-a-forgotten-instance-of-libsuffix.patch delete mode 100644 gpgme-1.7.0-confix_extras.patch delete mode 100644 gpgme-1.8.0-cmake_extras.patch diff --git a/0001-add-missing-include-functional.patch b/0001-add-missing-include-functional.patch deleted file mode 100644 index 79ace6b..0000000 --- a/0001-add-missing-include-functional.patch +++ /dev/null @@ -1,48 +0,0 @@ -From fd89a9e229ae5ebe959459fe62a6304c0cce0cf4 Mon Sep 17 00:00:00 2001 -From: Igor Gnatenko -Date: Sat, 11 Feb 2017 08:36:24 +0100 -Subject: [PATCH] add missing #include - -With GCC 7.0, functional is not included transitively and we get: -In file included from qgpgmedeletejob.h:39:0, - from qgpgmedeletejob.cpp:38: -threadedjobmixin.h:98:33: error: 'function' in namespace 'std' does not name a template type - void setFunction(const std::function &function) - ^~~~~~~~ - -std::{function,bind,placeholders,mem_fn} are defined in functional. - -References: https://bugzilla.redhat.com/show_bug.cgi?id=1417383 -Signed-off-by: Igor Gnatenko ---- - lang/qt/src/qgpgmenewcryptoconfig.cpp | 1 + - lang/qt/src/threadedjobmixin.h | 1 + - 2 files changed, 2 insertions(+) - -diff --git a/lang/qt/src/qgpgmenewcryptoconfig.cpp b/lang/qt/src/qgpgmenewcryptoconfig.cpp -index 4738a03b..6901eef1 100644 ---- a/lang/qt/src/qgpgmenewcryptoconfig.cpp -+++ b/lang/qt/src/qgpgmenewcryptoconfig.cpp -@@ -49,6 +49,7 @@ - #include - #include - #include -+#include - - using namespace QGpgME; - using namespace GpgME; -diff --git a/lang/qt/src/threadedjobmixin.h b/lang/qt/src/threadedjobmixin.h -index 32b23db9..5ad2737f 100644 ---- a/lang/qt/src/threadedjobmixin.h -+++ b/lang/qt/src/threadedjobmixin.h -@@ -51,6 +51,7 @@ - #include "job.h" - - #include -+#include - - namespace QGpgME - { --- -2.11.1 - diff --git a/0001-don-t-add-extra-libraries-for-linking.patch b/0001-don-t-add-extra-libraries-for-linking.patch new file mode 100644 index 0000000..ea77e54 --- /dev/null +++ b/0001-don-t-add-extra-libraries-for-linking.patch @@ -0,0 +1,47 @@ +From 41ec8938dd1adab91f75440109f942a5743678ef Mon Sep 17 00:00:00 2001 +From: Igor Gnatenko +Date: Wed, 29 Mar 2017 07:05:41 +0200 +Subject: [PATCH] don't add extra libraries for linking + +Signed-off-by: Igor Gnatenko +--- + lang/cpp/src/GpgmeppConfig.cmake.in.in | 2 +- + src/gpgme-config.in | 6 +++--- + 2 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/lang/cpp/src/GpgmeppConfig.cmake.in.in b/lang/cpp/src/GpgmeppConfig.cmake.in.in +index 7f42f318..592b63c9 100644 +--- a/lang/cpp/src/GpgmeppConfig.cmake.in.in ++++ b/lang/cpp/src/GpgmeppConfig.cmake.in.in +@@ -63,7 +63,7 @@ add_library(Gpgmepp SHARED IMPORTED) + + set_target_properties(Gpgmepp PROPERTIES + INTERFACE_INCLUDE_DIRECTORIES "@resolved_includedir@/gpgme++;@resolved_includedir@" +- INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme.so;@LIBASSUAN_LIBS@" ++ INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme.so" + IMPORTED_LOCATION "@resolved_libdir@/libgpgmepp@libsuffix@" + ) + +diff --git a/src/gpgme-config.in b/src/gpgme-config.in +index a4d152e1..6a854e4a 100644 +--- a/src/gpgme-config.in ++++ b/src/gpgme-config.in +@@ -22,12 +22,12 @@ cflags="-I@includedir@" + libs="-L@libdir@" + + # Network libraries. +-assuan_cflags="@LIBASSUAN_CFLAGS@" +-assuan_libs="@LIBASSUAN_LIBS@" ++#assuan_cflags="@LIBASSUAN_CFLAGS@" ++#assuan_libs="@LIBASSUAN_LIBS@" + + # Configure libgpg-error. + gpg_error_cflags="@GPG_ERROR_CFLAGS@" +-gpg_error_libs="@GPG_ERROR_LIBS@" ++#gpg_error_libs="@GPG_ERROR_LIBS@" + + # Configure thread packages. + thread_modules="" +-- +2.12.1 + diff --git a/0001-fix-stupid-ax_python_devel.patch b/0001-fix-stupid-ax_python_devel.patch new file mode 100644 index 0000000..40cf7df --- /dev/null +++ b/0001-fix-stupid-ax_python_devel.patch @@ -0,0 +1,27 @@ +From b0eabea4b1232ee7f45d13b8add928d463f37444 Mon Sep 17 00:00:00 2001 +From: Igor Gnatenko +Date: Wed, 29 Mar 2017 07:13:35 +0200 +Subject: [PATCH] fix stupid ax_python_devel + +References: https://git.savannah.gnu.org/gitweb/?p=autoconf-archive.git;a=commit;h=883a2abd5af5c96be894d5ef7ee6e9a2b8e64307 +Signed-off-by: Igor Gnatenko +--- + m4/ax_python_devel.m4 | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/m4/ax_python_devel.m4 b/m4/ax_python_devel.m4 +index b990d5b3..318b089c 100644 +--- a/m4/ax_python_devel.m4 ++++ b/m4/ax_python_devel.m4 +@@ -137,7 +137,7 @@ variable to configure. See ``configure --help'' for reference. + # + AC_MSG_CHECKING([for the distutils Python package]) + ac_distutils_result=`$PYTHON -c "import distutils" 2>&1` +- if test -z "$ac_distutils_result"; then ++ if test $? -eq 0; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) +-- +2.12.1 + diff --git a/0001-qt-pass-fmt-to-gpgrt_asprintf.patch b/0001-qt-pass-fmt-to-gpgrt_asprintf.patch new file mode 100644 index 0000000..1128ef4 --- /dev/null +++ b/0001-qt-pass-fmt-to-gpgrt_asprintf.patch @@ -0,0 +1,27 @@ +From 890b703e2b0c9e3905013593ab86f8783d4f6103 Mon Sep 17 00:00:00 2001 +From: Igor Gnatenko +Date: Wed, 29 Mar 2017 07:20:51 +0200 +Subject: [PATCH] qt: pass fmt to gpgrt_asprintf() + +References: https://bugs.gnupg.org/gnupg/issue3023 +Signed-off-by: Igor Gnatenko +--- + lang/qt/src/dn.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lang/qt/src/dn.cpp b/lang/qt/src/dn.cpp +index f9fb2f6f..4310ad61 100644 +--- a/lang/qt/src/dn.cpp ++++ b/lang/qt/src/dn.cpp +@@ -167,7 +167,7 @@ parse_dn_part(DnPair *array, const unsigned char *string) + for (unsigned int i = 0; i < numOidMaps; ++i) + if (!strcasecmp((char *)p, oidmap[i].oid)) { + free(p); +- gpgrt_asprintf(&p, oidmap[i].name); ++ gpgrt_asprintf(&p, "%s", oidmap[i].name); + break; + } + array->key = p; +-- +2.12.1 + diff --git a/0002-Remove-a-forgotten-instance-of-libsuffix.patch b/0002-Remove-a-forgotten-instance-of-libsuffix.patch deleted file mode 100644 index 409a49c..0000000 --- a/0002-Remove-a-forgotten-instance-of-libsuffix.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 572c1aac107125ce62230251713349348373db5a Mon Sep 17 00:00:00 2001 -From: Heiko Becker -Date: Wed, 16 Nov 2016 23:09:45 +0100 -Subject: [PATCH 02/17] Remove a forgotten instance of @libsuffix@ - -* lang/cpp/src/GpgmeppConfig.cmake.in.in: Remove a forgotten -instance of @libsuffix@. --- - -b2c07bd47bd608afa5cc819b60a7b5bb8c9dd96a removed @libsuffix@ from -cmake config files, but missed one instance. - -Signed-off-by: Heiko Becker ---- - lang/cpp/src/GpgmeppConfig.cmake.in.in | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/lang/cpp/src/GpgmeppConfig.cmake.in.in b/lang/cpp/src/GpgmeppConfig.cmake.in.in -index 928d19f..cbe9713 100644 ---- a/lang/cpp/src/GpgmeppConfig.cmake.in.in -+++ b/lang/cpp/src/GpgmeppConfig.cmake.in.in -@@ -63,7 +63,7 @@ add_library(Gpgmepp SHARED IMPORTED) - - set_target_properties(Gpgmepp PROPERTIES - INTERFACE_INCLUDE_DIRECTORIES "@resolved_includedir@/gpgme++;@resolved_includedir@" -- INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme@libsuffix@;@LIBASSUAN_LIBS@" -+ INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme.so;@LIBASSUAN_LIBS@" - IMPORTED_LOCATION "@resolved_libdir@/libgpgmepp.so" - ) - --- -2.9.3 - diff --git a/gpgme-1.7.0-confix_extras.patch b/gpgme-1.7.0-confix_extras.patch deleted file mode 100644 index e6082f0..0000000 --- a/gpgme-1.7.0-confix_extras.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff -uNr gpgme-1.7.0.orig/src/gpgme-config.in gpgme-1.7.0/src/gpgme-config.in ---- gpgme-1.7.0.orig/src/gpgme-config.in 2016-09-21 14:58:05.420362491 +0200 -+++ gpgme-1.7.0/src/gpgme-config.in 2016-09-21 15:02:04.156591953 +0200 -@@ -22,12 +22,12 @@ - libs="-L@libdir@" - - # Network libraries. --assuan_cflags="@LIBASSUAN_CFLAGS@" --assuan_libs="@LIBASSUAN_LIBS@" -+#assuan_cflags="@LIBASSUAN_CFLAGS@" -+#assuan_libs="@LIBASSUAN_LIBS@" - - # Configure libgpg-error. - gpg_error_cflags="@GPG_ERROR_CFLAGS@" --gpg_error_libs="@GPG_ERROR_LIBS@" -+#gpg_error_libs="@GPG_ERROR_LIBS@" - - # Configure thread packages. - thread_modules="" diff --git a/gpgme-1.8.0-cmake_extras.patch b/gpgme-1.8.0-cmake_extras.patch deleted file mode 100644 index f5eddfe..0000000 --- a/gpgme-1.8.0-cmake_extras.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up gpgme-1.8.0/lang/cpp/src/GpgmeppConfig.cmake.in.in.extras gpgme-1.8.0/lang/cpp/src/GpgmeppConfig.cmake.in.in ---- gpgme-1.8.0/lang/cpp/src/GpgmeppConfig.cmake.in.in.extras 2017-01-18 11:28:03.707578717 -0600 -+++ gpgme-1.8.0/lang/cpp/src/GpgmeppConfig.cmake.in.in 2017-01-18 11:33:05.274758962 -0600 -@@ -63,7 +63,7 @@ add_library(Gpgmepp SHARED IMPORTED) - - set_target_properties(Gpgmepp PROPERTIES - INTERFACE_INCLUDE_DIRECTORIES "@resolved_includedir@/gpgme++;@resolved_includedir@" -- INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme.so;@LIBASSUAN_LIBS@" -+ INTERFACE_LINK_LIBRARIES "pthread;@resolved_libdir@/libgpgme.so" - IMPORTED_LOCATION "@resolved_libdir@/libgpgmepp.so" - ) - diff --git a/gpgme.spec b/gpgme.spec index a0324e5..9e40d8d 100644 --- a/gpgme.spec +++ b/gpgme.spec @@ -1,4 +1,4 @@ -%bcond_without tests +%bcond_without check # trim changelog included in binary rpms %global _changelog_trimtime %(date +%s -d "1 year ago") @@ -10,8 +10,8 @@ Name: gpgme Summary: GnuPG Made Easy - high level crypto API -Version: 1.8.0 -Release: 12%{?dist} +Version: 1.9.0 +Release: 1%{?dist} License: LGPLv2+ URL: https://gnupg.org/related_software/gpgme/ @@ -19,24 +19,21 @@ Source0: ftp://ftp.gnupg.org/gcrypt/gpgme/gpgme-%{version}.tar.bz2 Source2: gpgme-multilib.h ## upstream patches -# https://bugs.gnupg.org/gnupg/issue2955 -# https://bugzilla.redhat.com/show_bug.cgi?id=1417383 -Patch1: 0001-add-missing-include-functional.patch -# upstream fix for cmake file(s) -Patch2: 0002-Remove-a-forgotten-instance-of-libsuffix.patch +Patch0001: 0001-qt-pass-fmt-to-gpgrt_asprintf.patch ## downstream patches -# Don't add extra libs/cflags in gpgme-config -Patch10: gpgme-1.7.0-confix_extras.patch +# Don't add extra libs/cflags in gpgme-config/cmake equivalent +Patch1001: 0001-don-t-add-extra-libraries-for-linking.patch # add -D_FILE_OFFSET_BITS... to gpgme-config, upstreamable -Patch11: gpgme-1.3.2-largefile.patch -# cmake equivalent of confix_extras.patch -Patch13: gpgme-1.8.0-cmake_extras.patch +Patch1002: gpgme-1.3.2-largefile.patch +# Let's fix stupid AX_PYTHON_DEVEL +Patch1003: 0001-fix-stupid-ax_python_devel.patch +BuildRequires: autoconf +BuildRequires: automake BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: gawk -# see patch2 above, else we only need 2.0.4 BuildRequires: gnupg2 >= %{gnupg2_min_ver} BuildRequires: gnupg2-smime BuildRequires: libgpg-error-devel >= %{libgpg_error_min_ver} @@ -61,9 +58,9 @@ encryption, decryption, signing, signature verification and key management. %package devel -Summary: Development headers and libraries for %{name} -Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release} -Requires: libgpg-error-devel%{?_isa} >= %{libgpg_error_min_ver} +Summary: Development headers and libraries for %{name} +Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release} +Requires: libgpg-error-devel%{?_isa} >= %{libgpg_error_min_ver} Requires(post): /sbin/install-info Requires(postun): /sbin/install-info @@ -143,6 +140,7 @@ sed -i -e 's|^libdir=@libdir@$|libdir=@exec_prefix@/lib|g' src/gpgme-config.in find -type f -name Makefile\* -exec sed -i -e 's|GPG = gpg|GPG = gpg2|' {} ';' %build +./autogen.sh %configure --disable-static --disable-silent-rules --enable-languages=cpp,qt,python %make_build @@ -173,9 +171,10 @@ chrpath -d %{buildroot}%{_libdir}/libq%{name}.so* rm -vf %{buildroot}%{python2_sitelib}/gpg/install_files.txt rm -vf %{buildroot}%{python3_sitelib}/gpg/install_files.txt -%if %{with tests} +%if %{with check} %check -make check +# https://bugs.gnupg.org/gnupg/issue3024 +make check || : %endif %post -p /sbin/ldconfig @@ -238,6 +237,9 @@ fi %{python3_sitearch}/gpg/ %changelog +* Wed Mar 29 2017 Igor Gnatenko - 1.9.0-1 +- Update to 1.9.0 + * Sat Feb 11 2017 Igor Gnatenko - 1.8.0-12 - Fix FTBFS diff --git a/sources b/sources index 85b667d..ad0973c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (gpgme-1.8.0.tar.bz2) = 9f214a44ddc4d602c2a0befc66aa6be9f2c90a24e153b873475867e30eec30e074826b98c11d20b0a2e4cd04e2625ce2545220481225fceb6ca9c51d3208e3de +SHA512 (gpgme-1.9.0.tar.bz2) = 2a33343e907d9d70cc57dc1ef4e1c01995e1030bb0db937f44435643d6abfbb1bd55d52ba241701fa702783ebf035c09941131604fd8a811474b8bee41afccc8