[{"id":3676342,"web_url":"http://patchwork.ozlabs.org/comment/3676342/","msgid":"<875x5wdpvx.fsf@tarshish>","list_archive_url":null,"date":"2026-04-12T17:56:02","subject":"Re: [Buildroot] [PATCH 1/1] package/wolfssl: fix build with libcurl\n >= 8.19.0 on 32bit archs","submitter":{"id":1458,"url":"http://patchwork.ozlabs.org/api/people/1458/","name":"Baruch Siach","email":"baruch@tkos.co.il"},"content":"Hi Bernd,\n\nOn Sat, Apr 11 2026, Bernd Kuhls wrote:\n> wolfssl requires definition of SIZEOF_LONG_LONG. Commit 3a5e071e4f9\n> (\"package/libcurl: security bump to version 8.19.0\") removed\n> SIZEOF_LONG_LONG definitions from libcurl autotools build system,\n> breaking build with wolfssl.\n>\n> Fixes:\n> https://autobuild.buildroot.net/results/baa/baa74a47464ed3e21d0adad64dd0c7c708c9ef85/\n>\n> Signed-off-by: Bernd Kuhls <bernd@kuhls.net>\n> ---\n> Please note that Baruch sent a fix to libcurl:\n> https://patchwork.ozlabs.org/project/buildroot/patch/ec612e55099118043d351762107b9c1a18387130.1775471071.git.baruch@tkos.co.il/\n\nYour suggestion is better than mine for Buildroot, IMO.\n\nTested-by: Baruch Siach <baruch@tkos.co.il>\n\nThanks,\nbaruch\n\n> although the problem should be fixed in wolfSSL instead, see\n> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=294287\n> https://github.com/wolfSSL/wolfssl/issues/9936\n> for details.\n>\n>  ...TS_H-in-options.h-rather-than-config.patch | 60 +++++++++++++++++++\n>  1 file changed, 60 insertions(+)\n>  create mode 100644 package/wolfssl/0001-Define-HAVE_LIMITS_H-in-options.h-rather-than-config.patch\n>\n> diff --git\n> a/package/wolfssl/0001-Define-HAVE_LIMITS_H-in-options.h-rather-than-config.patch\n> b/package/wolfssl/0001-Define-HAVE_LIMITS_H-in-options.h-rather-than-config.patch\n> new file mode 100644\n> index 0000000000..67f9672c2a\n> --- /dev/null\n> +++ b/package/wolfssl/0001-Define-HAVE_LIMITS_H-in-options.h-rather-than-config.patch\n> @@ -0,0 +1,60 @@\n> +From b54173fc402c30e81d66b84e2f9725cb6d944b40 Mon Sep 17 00:00:00 2001\n> +From: Kareem <kareem@wolfssl.com>\n> +Date: Fri, 27 Mar 2026 17:01:02 -0700\n> +Subject: [PATCH] Define HAVE_LIMITS_H in options.h rather than config.h since\n> + types.h depends on this definition and config.h isn't consistently available\n> + at runtime. Fixes #9936.\n> +\n> +Upstream: https://github.com/wolfSSL/wolfssl/pull/10097\n> +\n> +[Bernd: rebased for 5.7.2]\n> +Signed-off-by: Bernd Kuhls <bernd@kuhls.net>\n> +---\n> + cmake/config.in    | 3 ---\n> + cmake/options.h.in | 3 +++\n> + configure.ac       | 4 +++-\n> + 3 files changed, 6 insertions(+), 4 deletions(-)\n> +\n> +diff --git a/cmake/config.in b/cmake/config.in\n> +index f2524e41e43..6054b6dbe7b 100644\n> +--- a/cmake/config.in\n> ++++ b/cmake/config.in\n> +@@ -19,9 +19,6 @@\n> + /* Define to 1 if you have the `gmtime_r' function. */\n> + #cmakedefine HAVE_GMTIME_R @HAVE_GMTIME_R@\n> + \n> +-/* Define to 1 if you have the <limits.h> header file. */\n> +-#cmakedefine HAVE_LIMITS_H @HAVE_LIMITS_H@\n> +-\n> + /* Define to 1 if you have the <pcap/pcap.h> header file. */\n> + #cmakedefine HAVE_PCAP_PCAP_H @HAVE_PCAP_PCAP_H@\n> + \n> +diff --git a/cmake/options.h.in b/cmake/options.h.in\n> +index 985b54241d6..c46ada8045d 100644\n> +--- a/cmake/options.h.in\n> ++++ b/cmake/options.h.in\n> +@@ -31,6 +31,9 @@ extern \"C\" {\n> + #endif\n> + \n> + #ifndef WOLFSSL_OPTIONS_IGNORE_SYS\n> ++/* Since types.h depends on HAVE_LIMITS_H, we must define it in options.h. */\n> ++#undef HAVE_LIMITS_H\n> ++#cmakedefine HAVE_LIMITS_H @HAVE_LIMITS_H@\n> + #undef _GNU_SOURCE\n> + #cmakedefine _GNU_SOURCE\n> + #undef _POSIX_THREADS\n> +diff --git a/configure.ac b/configure.ac\n> +index bce600f2ecc..c5cf9f320c7 100644\n> +--- a/configure.ac\n> ++++ b/configure.ac\n> +@@ -116,7 +116,9 @@\n> +     AM_CCASFLAGS=\"$AM_CCASFLAGS -DWOLFSSL_EXPERIMENTAL_SETTINGS\"\n> + fi\n> + \n> +-AC_CHECK_HEADERS([arpa/inet.h fcntl.h limits.h netdb.h netinet/in.h stddef.h\n> time.h sys/ioctl.h sys/socket.h sys/time.h errno.h sys/un.h])\n> ++AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h netinet/in.h stddef.h time.h\n> sys/ioctl.h sys/socket.h sys/time.h errno.h sys/un.h])\n> ++# Special case: Since types.h depends on HAVE_LIMITS_H, we must define it in options.h.\n> ++AC_CHECK_HEADER([limits.h], [AM_CPPFLAGS=\"$AM_CPPFLAGS -DHAVE_LIMITS_H=1\"], [])\n> + AC_CHECK_LIB([network],[socket])\n> + AC_C_BIGENDIAN\n> + AC_C___ATOMIC","headers":{"Return-Path":"<buildroot-bounces@buildroot.org>","X-Original-To":["incoming-buildroot@patchwork.ozlabs.org","buildroot@buildroot.org"],"Delivered-To":["patchwork-incoming-buildroot@legolas.ozlabs.org","buildroot@buildroot.org"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=buildroot.org header.i=@buildroot.org\n header.a=rsa-sha256 header.s=default header.b=VNK5ac8n;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org\n (client-ip=2605:bc80:3010::136; helo=smtp3.osuosl.org;\n envelope-from=buildroot-bounces@buildroot.org; receiver=patchwork.ozlabs.org)"],"Received":["from smtp3.osuosl.org (smtp3.osuosl.org [IPv6:2605:bc80:3010::136])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4ftyry55wdz1yCx\n\tfor <incoming-buildroot@patchwork.ozlabs.org>;\n Mon, 13 Apr 2026 03:56:18 +1000 (AEST)","from localhost (localhost [127.0.0.1])\n\tby smtp3.osuosl.org (Postfix) with ESMTP id 929A960C10;\n\tSun, 12 Apr 2026 17:56:16 +0000 (UTC)","from smtp3.osuosl.org ([127.0.0.1])\n by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id gisMTZ7IdUJv; Sun, 12 Apr 2026 17:56:15 +0000 (UTC)","from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142])\n\tby smtp3.osuosl.org (Postfix) with ESMTP id 9A6EB616D4;\n\tSun, 12 Apr 2026 17:56:15 +0000 (UTC)","from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133])\n by lists1.osuosl.org (Postfix) with ESMTP id 7CD1E194\n for <buildroot@buildroot.org>; Sun, 12 Apr 2026 17:56:13 +0000 (UTC)","from localhost (localhost [127.0.0.1])\n by smtp2.osuosl.org (Postfix) with ESMTP id 7AAFE4068F\n for <buildroot@buildroot.org>; Sun, 12 Apr 2026 17:56:13 +0000 (UTC)","from smtp2.osuosl.org ([127.0.0.1])\n by localhost (smtp2.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id c0vS7bi1ylq2 for <buildroot@buildroot.org>;\n Sun, 12 Apr 2026 17:56:12 +0000 (UTC)","from mail.tkos.co.il (hours.tkos.co.il [84.110.109.230])\n by smtp2.osuosl.org (Postfix) with ESMTPS id 637524009A\n for <buildroot@buildroot.org>; Sun, 12 Apr 2026 17:56:10 +0000 (UTC)","from localhost (unknown [10.0.8.2])\n by mail.tkos.co.il (Postfix) with ESMTP id ED518440A40;\n Sun, 12 Apr 2026 20:55:25 +0300 (IDT)"],"X-Virus-Scanned":["amavis at osuosl.org","amavis at osuosl.org"],"X-Comment":"SPF check N/A for local connections - client-ip=140.211.166.142;\n helo=lists1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org;\n receiver=<UNKNOWN> ","DKIM-Filter":["OpenDKIM Filter v2.11.0 smtp3.osuosl.org 9A6EB616D4","OpenDKIM Filter v2.11.0 smtp2.osuosl.org 637524009A"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=buildroot.org;\n\ts=default; t=1776016575;\n\tbh=yxK2cWIjqpMVNUQOlHK9beDYJYU2KWHKrUnwutwqNGg=;\n\th=To:Cc:In-Reply-To:References:Date:Subject:List-Id:\n\t List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe:\n\t From:Reply-To:From;\n\tb=VNK5ac8nfR7LPCSmlLVlJUVtejIc4sDcoTbba4y1xXVFQbjEJPAnQrXIqPXg/ZTMK\n\t m+Prcn1vL2dBmPtlzuDXOZToEMaBhKQg4HhTvxqz1UBD5ZEM5Ft/Hs9XyIGavoPwll\n\t SIZVu4a5w/8qDY4YZUDLL9TQJFgsgvc1CavV05yQutm7KxdFdY6JKUiYaMQCu9+4ST\n\t WbhYH9tlATraq5eHgeF9aX1tj4hj9xo6rrReasDqr86sdYx4olu/2PmsBvwDKTRQPN\n\t ScmqTmw37KbwuEvTSuzenRFxKYYN7w2FmZlFm9pMuRhYsKflBc/qcDNJ1UIvJ0McuL\n\t 1aYdIxfbBMq2w==","Received-SPF":"Pass (mailfrom) identity=mailfrom; client-ip=84.110.109.230;\n helo=mail.tkos.co.il; envelope-from=baruch@tkos.co.il; receiver=<UNKNOWN>","DMARC-Filter":"OpenDMARC Filter v1.4.2 smtp2.osuosl.org 637524009A","To":"Bernd Kuhls <bernd@kuhls.net>","Cc":"buildroot@buildroot.org,  Sergio Prado <sergio.prado@e-labworks.com>","In-Reply-To":"<20260411102917.2045764-1-bernd@kuhls.net> (Bernd Kuhls's message\n of \"Sat, 11 Apr 2026 12:29:17 +0200\")","References":"<20260411102917.2045764-1-bernd@kuhls.net>","User-Agent":"mu4e 1.12.15; emacs 30.2","Date":"Sun, 12 Apr 2026 20:56:02 +0300","Message-ID":"<875x5wdpvx.fsf@tarshish>","MIME-Version":"1.0","X-Mailman-Original-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple;\n d=tkos.co.il; s=default; t=1776016525;\n bh=XceQUHZ9x4eO1bT57AL0r9jWzbcniEoqkpIO9rSKzuQ=;\n h=From:To:Cc:Subject:In-Reply-To:References:Date:From;\n b=osFGk7hSSf1c7c2JXt732EfGOxV2+lEgiBp22H0+a58kJKIxeirxbUBAusud4SOvI\n 1xVb+e0KSEgrGE21QQeAtVKEzQKE8Vn95UZKJBwCiXSxqlMjpKguWOkmNMA7WLe1Ph\n X+eOho6iR3Fu8ln26shTdWjhh13mh9K37zUU2aOho2Jqj1uVkN0YGLJBlQchtZ45fN\n VNcRo9WqENyjpmI4bngnyx+2CPZ3B/6pveywsIySTwC8Q3K5/UNGKRncJ7jsRS8A3u\n 0nvTOnuvcwgRggIHvz8XDR3mzGyFiMgBWM1DvgXtsHMJtpvT803z8q531iOAJG6oa7\n mgthHtI3CSbmw==","X-Mailman-Original-Authentication-Results":["smtp2.osuosl.org;\n dmarc=pass (p=quarantine dis=none)\n header.from=tkos.co.il","smtp2.osuosl.org;\n dkim=pass (2048-bit key,\n unprotected) header.d=tkos.co.il header.i=@tkos.co.il header.a=rsa-sha256\n header.s=default header.b=osFGk7hS"],"Subject":"Re: [Buildroot] [PATCH 1/1] package/wolfssl: fix build with libcurl\n >= 8.19.0 on 32bit archs","X-BeenThere":"buildroot@buildroot.org","X-Mailman-Version":"2.1.30","Precedence":"list","List-Id":"Discussion and development of buildroot <buildroot.buildroot.org>","List-Unsubscribe":"<https://lists.buildroot.org/mailman/options/buildroot>,\n <mailto:buildroot-request@buildroot.org?subject=unsubscribe>","List-Archive":"<http://lists.buildroot.org/pipermail/buildroot/>","List-Post":"<mailto:buildroot@buildroot.org>","List-Help":"<mailto:buildroot-request@buildroot.org?subject=help>","List-Subscribe":"<https://lists.buildroot.org/mailman/listinfo/buildroot>,\n <mailto:buildroot-request@buildroot.org?subject=subscribe>","From":"Baruch Siach via buildroot <buildroot@buildroot.org>","Reply-To":"Baruch Siach <baruch@tkos.co.il>","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"buildroot-bounces@buildroot.org","Sender":"\"buildroot\" <buildroot-bounces@buildroot.org>"}}]