All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/wget2: bump version to 2.3.0
@ 2026-10-22 19:50 Bernd Kuhls
  2026-10-22 21:19 ` Thomas Petazzoni via buildroot
  0 siblings, 1 reply; 2+ messages in thread
From: Bernd Kuhls @ 2026-10-22 19:50 UTC (permalink / raw)
  To: buildroot

https://lists.gnu.org/archive/html/wget-dev/2026-09/msg00031.html

Added upstream patch to fix a build error detected by the Gitlab
pipelines with defconfigs br-arm-full-static, br-arm-full-nothread &
bootlin-aarch64-glibc-old that would be introduced by this bump:

net.c: In function 'wget_tcp_write':
net.c:996:24: error: 'sockfd' undeclared (first use in this function);
 did you mean 'socket'?

Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
Gitlab pipelines passed:
https://gitlab.com/bkuhls/buildroot/-/commits/5af147ae82e7f180a1a586f5f9577e59931ef5ad

 ...-of-legacy-TCP-Fast-Open-code-branch.patch | 55 +++++++++++++++++++
 package/wget2/wget2.hash                      |  2 +-
 package/wget2/wget2.mk                        |  2 +-
 3 files changed, 57 insertions(+), 2 deletions(-)
 create mode 100644 package/wget2/0001-Fix-compilation-of-legacy-TCP-Fast-Open-code-branch.patch

diff --git a/package/wget2/0001-Fix-compilation-of-legacy-TCP-Fast-Open-code-branch.patch b/package/wget2/0001-Fix-compilation-of-legacy-TCP-Fast-Open-code-branch.patch
new file mode 100644
index 0000000000..6cc6419c87
--- /dev/null
+++ b/package/wget2/0001-Fix-compilation-of-legacy-TCP-Fast-Open-code-branch.patch
@@ -0,0 +1,55 @@
+From db600f40c51f0e612085f19351df3f9ad963bb5f Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tim=20R=C3=BChsen?= <tim.ruehsen@gmx.de>
+Date: Wed, 23 Sep 2026 12:02:24 +0200
+Subject: [PATCH] Fix compilation of legacy TCP Fast Open code branch
+
+* .gitlab-ci.yml: Add libwget compilation with -DTEST_LEGACY_TFO_API.
+* libwget/net.c: Use legacy code branch if TEST_LEGACY_TFO_API is set,
+  (wget_tcp_write): Fix two compilation errors.
+
+Fixes https://github.com/rockdaboot/wget2/issues/391
+
+Upstream: https://gitlab.com/gnuwget/wget2/-/commit/db600f40c51f0e612085f19351df3f9ad963bb5f
+
+[Bernd: removed .gitlab-ci.yml part from patch]
+Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
+---
+ .gitlab-ci.yml |  3 +++
+ libwget/net.c  | 10 +++++-----
+ 2 files changed, 8 insertions(+), 5 deletions(-)
+
+diff --git a/libwget/net.c b/libwget/net.c
+index 1cd7188c..fb7227bf 100644
+--- a/libwget/net.c
++++ b/libwget/net.c
+@@ -55,10 +55,10 @@
+ 
+ #if defined __APPLE__ && defined __MACH__ && defined CONNECT_DATA_IDEMPOTENT && defined CONNECT_RESUME_ON_READ_WRITE
+ # define TCP_FASTOPEN_OSX
+-#elif defined TCP_FASTOPEN_CONNECT // since Linux 4.11
+-# define TCP_FASTOPEN_LINUX_411
++#elif defined TCP_FASTOPEN_CONNECT && !defined TEST_LEGACY_TFO_API
++# define TCP_FASTOPEN_LINUX_411 // for Linux 4.11+: newer client API
+ #elif defined TCP_FASTOPEN && defined MSG_FASTOPEN
+-# define TCP_FASTOPEN_LINUX
++# define TCP_FASTOPEN_LINUX // for Linux 3.7+: legacy client API
+ #endif
+ 
+ #include <wget.h>
+@@ -993,11 +993,11 @@ ssize_t wget_tcp_write(wget_tcp *tcp, const char *buf, size_t count)
+ 				/* fallback from fastopen, e.g. when fastopen is disabled in system */
+ 				tcp->tcp_fastopen = 0;
+ 
+-				set_socket_timeout(sockfd, tcp->connect_timeout);
++				set_socket_timeout(tcp->sockfd, tcp->connect_timeout);
+ 
+ 				int rc = connect(tcp->sockfd, tcp->connect_addrinfo->ai_addr, tcp->connect_addrinfo->ai_addrlen);
+ 
+-				set_socket_timeout(sockfd, tcp->timeout);
++				set_socket_timeout(tcp->sockfd, tcp->timeout);
+ 
+ 				if (rc < 0
+ 					&& errno != EAGAIN
+-- 
+2.47.3
+
diff --git a/package/wget2/wget2.hash b/package/wget2/wget2.hash
index 0e5742aed4..63c90e664c 100644
--- a/package/wget2/wget2.hash
+++ b/package/wget2/wget2.hash
@@ -1,4 +1,4 @@
 # Locally calculated
-sha256  d7544b13e37f18e601244fce5f5f40688ac1d6ab9541e0fbb01a32ee1fb447b4  wget2-2.2.1.tar.gz
+sha256  4f1915b2a55a789a15f2f9ada7cc44bca81418e648f76fd88a7f4dd028b2149f  wget2-2.3.0.tar.gz
 sha256  e79e9c8a0c85d735ff98185918ec94ed7d175efc377012787aebcf3b80f0d90b  COPYING
 sha256  e3a994d82e644b03a792a930f574002658412f62407f5fee083f2555c5f23118  COPYING.LESSER
diff --git a/package/wget2/wget2.mk b/package/wget2/wget2.mk
index 21005bd708..58f95c2355 100644
--- a/package/wget2/wget2.mk
+++ b/package/wget2/wget2.mk
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-WGET2_VERSION = 2.2.1
+WGET2_VERSION = 2.3.0
 WGET2_SITE = $(BR2_GNU_MIRROR)/wget
 WGET2_DEPENDENCIES = host-pkgconf
 WGET2_LICENSE = GPL-3.0+, LGPL-3.0+
-- 
2.47.3

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/wget2: bump version to 2.3.0
  2026-10-22 19:50 [Buildroot] [PATCH 1/1] package/wget2: bump version to 2.3.0 Bernd Kuhls
@ 2026-10-22 21:19 ` Thomas Petazzoni via buildroot
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Petazzoni via buildroot @ 2026-10-22 21:19 UTC (permalink / raw)
  To: Bernd Kuhls; +Cc: buildroot

On Thu, Oct 22, 2026 at 09:50:40PM +0200, Bernd Kuhls wrote:
> https://lists.gnu.org/archive/html/wget-dev/2026-09/msg00031.html
> 
> Added upstream patch to fix a build error detected by the Gitlab
> pipelines with defconfigs br-arm-full-static, br-arm-full-nothread &
> bootlin-aarch64-glibc-old that would be introduced by this bump:
> 
> net.c: In function 'wget_tcp_write':
> net.c:996:24: error: 'sockfd' undeclared (first use in this function);
>  did you mean 'socket'?
> 
> Signed-off-by: Bernd Kuhls <bernd@kuhls.net>

Applied to master, thanks!

Best regards,

Thomas Petazzoni
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-10-22 21:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-22 19:50 [Buildroot] [PATCH 1/1] package/wget2: bump version to 2.3.0 Bernd Kuhls
2026-10-22 21:19 ` Thomas Petazzoni via buildroot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.