Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Cc: buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH 1/1] package/libgpgme: fix build without threads
Date: Sun, 28 Aug 2022 11:41:59 +0200	[thread overview]
Message-ID: <20220828094159.GI37358@scaer> (raw)
In-Reply-To: <20220827213558.476660-1-fontaine.fabrice@gmail.com>

Fabrice, All,

On 2022-08-27 23:35 +0200, Fabrice Fontaine spake thusly:
> Fix the following build failure without threads raised since bump to
> version 1.17.1 in commit 3f121357ae225be9ac2fbf4505027c2cc690626b 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>

Applied to master, thanks.

Regards,
Yann E. MORIN.

> ---
>  .../0001-Fix-build-without-threads.patch      | 59 +++++++++++++++++++
>  package/libgpgme/libgpgme.mk                  |  3 +
>  2 files changed, 62 insertions(+)
>  create mode 100644 package/libgpgme/0001-Fix-build-without-threads.patch
> 
> diff --git a/package/libgpgme/0001-Fix-build-without-threads.patch b/package/libgpgme/0001-Fix-build-without-threads.patch
> new file mode 100644
> index 0000000000..caa4ed7d78
> --- /dev/null
> +++ b/package/libgpgme/0001-Fix-build-without-threads.patch
> @@ -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
> +
> diff --git a/package/libgpgme/libgpgme.mk b/package/libgpgme/libgpgme.mk
> index 1b57b18872..2120ee8e3c 100644
> --- a/package/libgpgme/libgpgme.mk
> +++ b/package/libgpgme/libgpgme.mk
> @@ -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
> -- 
> 2.35.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

      reply	other threads:[~2022-08-28  9:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-27 21:35 [Buildroot] [PATCH 1/1] package/libgpgme: fix build without threads Fabrice Fontaine
2022-08-28  9:41 ` Yann E. MORIN [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220828094159.GI37358@scaer \
    --to=yann.morin.1998@free.fr \
    --cc=buildroot@buildroot.org \
    --cc=fontaine.fabrice@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox