From patchwork Mon May 17 15:56:28 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Romain Naour X-Patchwork-Id: 1479613 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=f/gnUtcB; dkim-atps=neutral Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4FkNzp4PRvz9sWQ for ; Tue, 18 May 2021 01:56:54 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 8F77783B46; Mon, 17 May 2021 15:56:52 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AlTeqmPLDJdx; Mon, 17 May 2021 15:56:51 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id DAA6683A83; Mon, 17 May 2021 15:56:50 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 56F091BF964 for ; Mon, 17 May 2021 15:56:38 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 535BF60A70 for ; Mon, 17 May 2021 15:56:38 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id E2CLUKsHC2WB for ; Mon, 17 May 2021 15:56:37 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-wr1-x42e.google.com (mail-wr1-x42e.google.com [IPv6:2a00:1450:4864:20::42e]) by smtp3.osuosl.org (Postfix) with ESMTPS id 5B14360A62 for ; Mon, 17 May 2021 15:56:37 +0000 (UTC) Received: by mail-wr1-x42e.google.com with SMTP id z17so6950708wrq.7 for ; Mon, 17 May 2021 08:56:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KRIHLgTqerZY66qyaZ+TpWmliH+I15hdcv1TMOEIVB0=; b=f/gnUtcB/GltwxZ8xYFqW2JglfPp/JLMCS1eVZt6fUgfgRKbGj3QldIGal86oRkFOu 7bsUhQ+PEv/Nlz7VLmmITZcbU7arZaRaEawRczI//jA9M2D/oSzBNcYWU8zAAhRtfmUZ EUeA6sblzZReWEHntloj19P7TOzNbQzi/vjdKDIsypsC6dodufmlb43l9pnSpy+RKGhc mJksZb/T0YVBrZEvTNwWDCXz+yjMkePbue614bWOwnx3URFJlowvZIpKUO3Pw8qh8qSq 3YXOoSMRVTdUMwW76YW7XRDYPTU66RFhMIx6ycSJ0etVY3yNVPBEukQTBWxxK3mX3OHj jL6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=KRIHLgTqerZY66qyaZ+TpWmliH+I15hdcv1TMOEIVB0=; b=j6tBONeI3+oLenIgef/ChEDDKdiM6DfbYwrHehWsJVtkQocxhzXNydPyoTJfCx7IJH tCTLqJQBzEpkoMlgOS9ocXIzQRfHLl1zEW4uXy/h2wg/4zeKZa6uhII9wJRaaH7YMvbV 0Z+eSlaXs3M7ipsX2F9teTBOGeD0TYD80sHBflS+GQ3XZJwOUP9IbA5sMjJNNk4p5bfY glyT7Qt1peHPDcpAZZY7o/UgkT7UgGAH6CfyN5TMfQUKQpfM/EF7RoU6W5kWYu1pV3Ns RfuCp1ln7Vza4bU3y86zE8H61bGS4VIgMctbzPCdxBT2wk1QmQZWhtCgPm4tUt9lEBxt wYcA== X-Gm-Message-State: AOAM533fr8OiJ+xVaG9DihGyLNMLvVJCFpMwD5kOqba2mIECer+8emit wsmMfBDSQ5lR4Q7NCLwe/BBAGGd0dP0= X-Google-Smtp-Source: ABdhPJxE1d9hcJpXTDNOOrkMSjVPpv3QORKBKbLwG5iuLUQxCi+W/xwJFvC2oRBBGocmPAss3km4iQ== X-Received: by 2002:a05:6000:551:: with SMTP id b17mr456378wrf.32.1621266995659; Mon, 17 May 2021 08:56:35 -0700 (PDT) Received: from localhost.localdomain (2a01cb058f8a180022164e4eb697b4ce.ipv6.abo.wanadoo.fr. [2a01:cb05:8f8a:1800:2216:4e4e:b697:b4ce]) by smtp.gmail.com with ESMTPSA id i1sm6716565wrp.51.2021.05.17.08.56.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 May 2021 08:56:35 -0700 (PDT) From: Romain Naour To: buildroot@buildroot.org Date: Mon, 17 May 2021 17:56:28 +0200 Message-Id: <20210517155628.267749-3-romain.naour@gmail.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210517155628.267749-1-romain.naour@gmail.com> References: <20210517155628.267749-1-romain.naour@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCHv2 3/3] package/poke: enable uClibc-ng support X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Romain Naour Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" poke bundle gnulib that doesn't support the case where host_os='linux-uclibc'. When cross-compiling, the guessed answers are mostly wrong and gnulib will try to replace snprintf with rpl_snprintf. This lead to "undefined reference to `rpl_snprintf'" errors. Signed-off-by: Romain Naour --- test-pkg config: BR2_PACKAGE_POKE=y BR2_PACKAGE_JSON_C=y --- package/poke/Config.in | 4 +--- package/poke/poke.mk | 25 +++++++++++++++++++++++++ 2 files changed, 26 insertions(+), 3 deletions(-) diff --git a/package/poke/Config.in b/package/poke/Config.in index d3334dfdd4..762ed0221d 100644 --- a/package/poke/Config.in +++ b/package/poke/Config.in @@ -4,7 +4,6 @@ config BR2_PACKAGE_POKE depends on BR2_PACKAGE_BUSYBOX_SHOW_OTHERS # less depends on BR2_USE_WCHAR # needs wctomb depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL - depends on BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_MUSL # gnulib select BR2_PACKAGE_BDWGC select BR2_PACKAGE_LESS # runtime select BR2_PACKAGE_READLINE @@ -24,6 +23,5 @@ config BR2_PACKAGE_POKE https://www.gnu.org/software/poke/ -comment "poke needs a glibc or musl toolchain w/ NPTL, wchar" - depends on !(BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_MUSL) +comment "poke needs a toolchain w/ NPTL, wchar" depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || !BR2_USE_WCHAR diff --git a/package/poke/poke.mk b/package/poke/poke.mk index 7c3c81d93c..406acf15e0 100644 --- a/package/poke/poke.mk +++ b/package/poke/poke.mk @@ -16,6 +16,31 @@ POKE_AUTORECONF = YES POKE_DEPENDENCIES = host-flex host-bison host-pkgconf bdwgc readline +# poke bundle gnulib that doesn't support the case where +# host_os='linux-uclibc'. When cross-compiling, the guessed +# answers are mostly wrong and gnulib will try to replace +# snprintf with rpl_snprintf. This lead to "undefined reference +# to `rpl_snprintf'" errors. +ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y) +POKE_CONF_ENV = gl_cv_func_printf_positions=yes \ + gl_cv_func_snprintf_retval_c99=yes \ + gl_cv_func_printf_sizes_c99=yes \ + gl_cv_func_printf_infinite_long_double=yes \ + gl_cv_func_snprintf_retval_c99=yes \ + gl_cv_func_snprintf_truncation_c99=yes \ + gl_cv_func_snprintf_usable=yes \ + gl_cv_func_strerror_0_works=yes \ + gl_cv_header_working_stdint_h=yes \ + gl_cv_func_printf_infinite=yes \ + gl_cv_func_printf_flag_zero=yes \ + gl_cv_func_printf_enomem=yes \ + gl_cv_func_printf_directive_f=yes \ + gl_cv_func_printf_directive_a=yes \ + gl_cv_func_snprintf_directive_n=yes \ + gl_cv_func_vsnprintf_posix=yes \ + gl_cv_func_vsnprintf_zerosize_c99=yes +endif + POKE_CONF_OPTS = \ --disable-gui \ --disable-libnbd \