package/libgpgme: fix build without threads
Fix the following build failure without threads raised since bump to
version 1.17.1 in commit 3f121357ae
and
https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gpgme.git;a=commit;h=f3177d3ee0a1d30e15f33ff226b5e4c96b7610db:
run-wkdlookup.cpp: In function 'int main(int, char**)':
run-wkdlookup.cpp:130:18: error: 'std::this_thread' has not been declared
130 | std::this_thread::sleep_for(std::chrono::milliseconds{250 * cnt});
| ^~~~~~~~~~~
Fixes:
- http://autobuild.buildroot.org/results/2915f6105bae595274fabaa12de7cc53926d22d0
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
This commit is contained in:
parent
5c2d07b0b3
commit
b218ba178d
59
package/libgpgme/0001-Fix-build-without-threads.patch
Normal file
59
package/libgpgme/0001-Fix-build-without-threads.patch
Normal file
@ -0,0 +1,59 @@
|
||||
From fc1b821c80c78f4ae635639c7fce5bad754edda7 Mon Sep 17 00:00:00 2001
|
||||
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
Date: Sat, 27 Aug 2022 23:24:44 +0200
|
||||
Subject: [PATCH] Fix build without threads
|
||||
|
||||
Allow the user to disable cpp tests to avoid the following build failure
|
||||
without threads raised since version 1.17.1 and
|
||||
https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gpgme.git;a=commit;h=f3177d3ee0a1d30e15f33ff226b5e4c96b7610db
|
||||
|
||||
run-wkdlookup.cpp: In function 'int main(int, char**)':
|
||||
run-wkdlookup.cpp:130:18: error: 'std::this_thread' has not been declared
|
||||
130 | std::this_thread::sleep_for(std::chrono::milliseconds{250 * cnt});
|
||||
| ^~~~~~~~~~~
|
||||
|
||||
Fixes:
|
||||
- http://autobuild.buildroot.org/results/2915f6105bae595274fabaa12de7cc53926d22d0
|
||||
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
[Upstream status: https://dev.gnupg.org/T6165]
|
||||
---
|
||||
configure.ac | 5 +++++
|
||||
lang/cpp/Makefile.am | 6 +++++-
|
||||
2 files changed, 10 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index e7fe04a7..d1c87486 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -553,6 +553,11 @@ AC_ARG_ENABLE(g13-test,
|
||||
run_g13_test=$enableval)
|
||||
AM_CONDITIONAL(RUN_G13_TESTS, test "$run_g13_test" = "yes")
|
||||
|
||||
+run_cpp_test="yes"
|
||||
+AC_ARG_ENABLE(cpp-test,
|
||||
+ AS_HELP_STRING([--disable-cpp-test],[disable CPP regression test]),
|
||||
+ run_cpp_test=$enableval)
|
||||
+AM_CONDITIONAL(RUN_CPP_TESTS, test "$run_cpp_test" = "yes")
|
||||
|
||||
# Checks for header files.
|
||||
AC_CHECK_HEADERS_ONCE([locale.h sys/select.h sys/uio.h argp.h stdint.h
|
||||
diff --git a/lang/cpp/Makefile.am b/lang/cpp/Makefile.am
|
||||
index 724da6ca..243c463d 100644
|
||||
--- a/lang/cpp/Makefile.am
|
||||
+++ b/lang/cpp/Makefile.am
|
||||
@@ -18,6 +18,10 @@
|
||||
# License along with this program; if not, see <https://gnu.org/licenses/>.
|
||||
# SPDX-License-Identifier: LGPL-2.1-or-later
|
||||
|
||||
-SUBDIRS = src tests
|
||||
+SUBDIRS = src
|
||||
+
|
||||
+if RUN_CPP_TESTS
|
||||
+SUBDIRS += tests
|
||||
+endif
|
||||
|
||||
EXTRA_DIST = README
|
||||
--
|
||||
2.35.1
|
||||
|
@ -14,6 +14,8 @@ LIBGPGME_CPE_ID_PRODUCT = gpgme
|
||||
LIBGPGME_INSTALL_STAGING = YES
|
||||
LIBGPGME_DEPENDENCIES = libassuan libgpg-error
|
||||
LIBGPGME_CONFIG_SCRIPTS = gpgme-config
|
||||
# We're patching configure.ac
|
||||
LIBGPGME_AUTORECONF = YES
|
||||
|
||||
LIBGPGME_LANGUAGE_BINDINGS = cl
|
||||
# C++ bindings require a C++11 capable gcc, and -Wsuggest-override support
|
||||
@ -28,6 +30,7 @@ LIBGPGME_CONF_OPTS = \
|
||||
--disable-gpgconf-test \
|
||||
--disable-g13-test \
|
||||
--disable-gpg-test \
|
||||
--disable-cpp-test \
|
||||
--enable-languages=$(subst $(space),$(comma),$(LIBGPGME_LANGUAGE_BINDINGS))
|
||||
|
||||
# Handle argp-standalone or it errors out during build
|
||||
|
Loading…
Reference in New Issue
Block a user