From patchwork Fri Jul 24 09:56:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Petr_=C5=A0tetiar?= X-Patchwork-Id: 1335551 X-Patchwork-Delegate: ynezz@true.cz Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.openwrt.org (client-ip=2001:8b0:10b:1231::1; helo=merlin.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=true.cz Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=merlin.20170209 header.b=yEQTl3Uo; dkim-atps=neutral Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) (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 4BCl4f5FKFz9sSy for ; Fri, 24 Jul 2020 19:57:54 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=JBdIuiTBv3VOaqaD7LOgOkuuPI1/ZNpubRz6e2SqUcs=; b=yEQTl3UoYgWrYkoVgJGzjbmZ2d DnK8pVtUNroBsYHtTn2pLaX1Ic5HnZdQxRuzaY4xiuvYN6SzjFW0OHedtk4VBX7YJhOJLDlDsyg63 D9a3O3eNauWMvOIzFz0rKTQ+UUeDJSLEFBxeld7NKXZ/0W12PMAU1fQl1y5CV+zQOqMFFOGpvAAkL 6OJmBgYmUho/HgXI34yTMvRIss64sRJYb5MptSU9eGKKyaKa93J4GhmzO6mx1E1WP24/HAfvk8T9b 1WnPxw9NIEnIXiwfHHQUmRPimLKdR9/oQn/iYqrJDRnJ3Zk5IpWX+wNFLIhEm+OyGWfv30OxS56Ml ILSWUyMQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jyuRZ-0005Ui-6c; Fri, 24 Jul 2020 09:56:45 +0000 Received: from smtp-out.xnet.cz ([178.217.244.18]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jyuRT-0005Tx-4p for openwrt-devel@lists.openwrt.org; Fri, 24 Jul 2020 09:56:41 +0000 Received: from meh.true.cz (meh.true.cz [108.61.167.218]) (Authenticated sender: petr@true.cz) by smtp-out.xnet.cz (Postfix) with ESMTPSA id 1C5523F7A; Fri, 24 Jul 2020 11:56:31 +0200 (CEST) Received: by meh.true.cz (OpenSMTPD) with ESMTP id 076477eb; Fri, 24 Jul 2020 11:56:14 +0200 (CEST) From: =?utf-8?q?Petr_=C5=A0tetiar?= To: openwrt-devel@lists.openwrt.org Subject: [PATCH] busybox: bump to 1.32.0 Date: Fri, 24 Jul 2020 11:56:27 +0200 Message-Id: <20200724095627.7056-1-ynezz@true.cz> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200724_055639_463463_DAD9A048 X-CRM114-Status: GOOD ( 16.14 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 SPF_NONE SPF: sender does not publish an SPF Record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Petr_=C5=A0tetiar?= Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org Refreshed patches. Removed upstreamed patches: 001-remove-stime-function-calls.patch 110-no_static_libgcc.patch Run tested on x86_64 under QEMU. Signed-off-by: Petr Štetiar --- package/utils/busybox/Makefile | 4 +- .../001-remove-stime-function-calls.patch | 84 ------------------- .../patches/110-no_static_libgcc.patch | 11 --- .../busybox/patches/120-lto-jobserver.patch | 6 +- .../patches/200-udhcpc_reduce_msgs.patch | 4 +- .../patches/201-udhcpc_changed_ifindex.patch | 2 +- .../203-udhcpc_renew_no_deconfig.patch | 2 +- .../patches/230-add_nslookup_lede.patch | 6 +- .../busybox/patches/250-date-k-flag.patch | 14 ++-- 9 files changed, 19 insertions(+), 114 deletions(-) delete mode 100644 package/utils/busybox/patches/001-remove-stime-function-calls.patch delete mode 100644 package/utils/busybox/patches/110-no_static_libgcc.patch diff --git a/package/utils/busybox/Makefile b/package/utils/busybox/Makefile index 01441d1e87d1..4a5e0aab0d59 100644 --- a/package/utils/busybox/Makefile +++ b/package/utils/busybox/Makefile @@ -8,14 +8,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=busybox -PKG_VERSION:=1.31.1 +PKG_VERSION:=1.32.0 PKG_RELEASE:=1 PKG_FLAGS:=essential PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=https://www.busybox.net/downloads \ http://sources.buildroot.net -PKG_HASH:=d0f940a72f648943c1f2211e0e3117387c31d765137d92bd8284a3fb9752a998 +PKG_HASH:=c35d87f1d04b2b153d33c275c2632e40d388a88f19a9e71727e0bbbff51fe689 PKG_BUILD_DEPENDS:=BUSYBOX_CONFIG_PAM:libpam PKG_BUILD_PARALLEL:=1 diff --git a/package/utils/busybox/patches/001-remove-stime-function-calls.patch b/package/utils/busybox/patches/001-remove-stime-function-calls.patch deleted file mode 100644 index ccf9bef35657..000000000000 --- a/package/utils/busybox/patches/001-remove-stime-function-calls.patch +++ /dev/null @@ -1,84 +0,0 @@ -From d3539be8f27b8cbfdfee460fe08299158f08bcd9 Mon Sep 17 00:00:00 2001 -From: Alistair Francis -Date: Tue, 19 Nov 2019 13:06:40 +0100 -Subject: Remove stime() function calls - -stime() has been deprecated in glibc 2.31 and replaced with -clock_settime(). Let's replace the stime() function calls with -clock_settime() in preperation. - -function old new delta -rdate_main 197 224 +27 -clock_settime - 27 +27 -date_main 926 941 +15 -stime 37 - -37 ------------------------------------------------------------------------------- -(add/remove: 2/2 grow/shrink: 2/0 up/down: 69/-37) Total: 32 bytes - -Signed-off-by: Alistair Francis -Signed-off-by: Denys Vlasenko ---- - coreutils/date.c | 6 +++++- - libbb/missing_syscalls.c | 8 -------- - util-linux/rdate.c | 8 ++++++-- - 3 files changed, 11 insertions(+), 11 deletions(-) - ---- a/coreutils/date.c -+++ b/coreutils/date.c -@@ -279,6 +279,9 @@ int date_main(int argc UNUSED_PARAM, cha - time(&ts.tv_sec); - #endif - } -+#if !ENABLE_FEATURE_DATE_NANO -+ ts.tv_nsec = 0; -+#endif - localtime_r(&ts.tv_sec, &tm_time); - - /* If date string is given, update tm_time, and maybe set date */ -@@ -301,9 +304,10 @@ int date_main(int argc UNUSED_PARAM, cha - if (date_str[0] != '@') - tm_time.tm_isdst = -1; - ts.tv_sec = validate_tm_time(date_str, &tm_time); -+ ts.tv_nsec = 0; - - /* if setting time, set it */ -- if ((opt & OPT_SET) && stime(&ts.tv_sec) < 0) { -+ if ((opt & OPT_SET) && clock_settime(CLOCK_REALTIME, &ts) < 0) { - bb_perror_msg("can't set date"); - } - } ---- a/libbb/missing_syscalls.c -+++ b/libbb/missing_syscalls.c -@@ -15,14 +15,6 @@ pid_t getsid(pid_t pid) - return syscall(__NR_getsid, pid); - } - --int stime(const time_t *t) --{ -- struct timeval tv; -- tv.tv_sec = *t; -- tv.tv_usec = 0; -- return settimeofday(&tv, NULL); --} -- - int sethostname(const char *name, size_t len) - { - return syscall(__NR_sethostname, name, len); ---- a/util-linux/rdate.c -+++ b/util-linux/rdate.c -@@ -95,9 +95,13 @@ int rdate_main(int argc UNUSED_PARAM, ch - if (!(flags & 2)) { /* no -p (-s may be present) */ - if (time(NULL) == remote_time) - bb_error_msg("current time matches remote time"); -- else -- if (stime(&remote_time) < 0) -+ else { -+ struct timespec ts; -+ ts.tv_sec = remote_time; -+ ts.tv_nsec = 0; -+ if (clock_settime(CLOCK_REALTIME, &ts) < 0) - bb_perror_msg_and_die("can't set time of day"); -+ } - } - - if (flags != 1) /* not lone -s */ diff --git a/package/utils/busybox/patches/110-no_static_libgcc.patch b/package/utils/busybox/patches/110-no_static_libgcc.patch deleted file mode 100644 index 2148a09e006e..000000000000 --- a/package/utils/busybox/patches/110-no_static_libgcc.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/Makefile.flags -+++ b/Makefile.flags -@@ -51,7 +51,7 @@ CFLAGS += $(call cc-option,-fno-builtin- - # -fno-guess-branch-probability: prohibit pseudo-random guessing - # of branch probabilities (hopefully makes bloatcheck more stable): - CFLAGS += $(call cc-option,-fno-guess-branch-probability,) --CFLAGS += $(call cc-option,-funsigned-char -static-libgcc,) -+CFLAGS += $(call cc-option,-funsigned-char,) - CFLAGS += $(call cc-option,-falign-functions=1 -falign-jumps=1 -falign-labels=1 -falign-loops=1,) - # Defeat .eh_frame bloat (gcc 4.6.3 x86-32 defconfig: 20% smaller busybox binary): - CFLAGS += $(call cc-option,-fno-unwind-tables,) diff --git a/package/utils/busybox/patches/120-lto-jobserver.patch b/package/utils/busybox/patches/120-lto-jobserver.patch index 99c5b5120172..d4f997e6d82d 100644 --- a/package/utils/busybox/patches/120-lto-jobserver.patch +++ b/package/utils/busybox/patches/120-lto-jobserver.patch @@ -1,6 +1,6 @@ --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include -@@ -130,7 +130,7 @@ make-cmd = $(subst \#,\\\#,$(subst $$,$$ +@@ -131,7 +131,7 @@ make-cmd = $(subst \#,\\\#,$(subst $$,$$ # if_changed = $(if $(strip $(filter-out $(PHONY),$?) \ $(call arg-check, $(cmd_$(1)), $(cmd_$@)) ), \ @@ -9,7 +9,7 @@ $(echo-cmd) $(cmd_$(1)); \ echo 'cmd_$@ := $(make-cmd)' > $(@D)/.$(@F).cmd) -@@ -139,7 +139,7 @@ if_changed = $(if $(strip $(filter-out $ +@@ -140,7 +140,7 @@ if_changed = $(if $(strip $(filter-out $ if_changed_dep = $(if $(strip $(filter-out $(PHONY),$?) \ $(filter-out FORCE $(wildcard $^),$^) \ $(call arg-check, $(cmd_$(1)), $(cmd_$@)) ), \ @@ -18,7 +18,7 @@ $(echo-cmd) $(cmd_$(1)); \ scripts/basic/fixdep $(depfile) $@ '$(make-cmd)' > $(@D)/.$(@F).tmp; \ rm -f $(depfile); \ -@@ -150,5 +150,5 @@ if_changed_dep = $(if $(strip $(filter-o +@@ -151,5 +151,5 @@ if_changed_dep = $(if $(strip $(filter-o # and if so will execute $(rule_foo) if_changed_rule = $(if $(strip $(filter-out $(PHONY),$?) \ $(call arg-check, $(cmd_$(1)), $(cmd_$@)) ),\ diff --git a/package/utils/busybox/patches/200-udhcpc_reduce_msgs.patch b/package/utils/busybox/patches/200-udhcpc_reduce_msgs.patch index 4bab25a8d578..162f92260b7b 100644 --- a/package/utils/busybox/patches/200-udhcpc_reduce_msgs.patch +++ b/package/utils/busybox/patches/200-udhcpc_reduce_msgs.patch @@ -1,6 +1,6 @@ --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c -@@ -713,6 +713,7 @@ static int bcast_or_ucast(struct dhcp_pa +@@ -673,6 +673,7 @@ static int bcast_or_ucast(struct dhcp_pa static NOINLINE int send_discover(uint32_t xid, uint32_t requested) { struct dhcp_packet packet; @@ -8,7 +8,7 @@ /* Fill in: op, htype, hlen, cookie, chaddr fields, * random xid field (we override it below), -@@ -730,6 +731,7 @@ static NOINLINE int send_discover(uint32 +@@ -690,6 +691,7 @@ static NOINLINE int send_discover(uint32 */ add_client_options(&packet); diff --git a/package/utils/busybox/patches/201-udhcpc_changed_ifindex.patch b/package/utils/busybox/patches/201-udhcpc_changed_ifindex.patch index 256b049d9e26..e5a0941e5fbf 100644 --- a/package/utils/busybox/patches/201-udhcpc_changed_ifindex.patch +++ b/package/utils/busybox/patches/201-udhcpc_changed_ifindex.patch @@ -1,6 +1,6 @@ --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c -@@ -1416,6 +1416,12 @@ int udhcpc_main(int argc UNUSED_PARAM, c +@@ -1376,6 +1376,12 @@ int udhcpc_main(int argc UNUSED_PARAM, c /* silence "uninitialized!" warning */ unsigned timestamp_before_wait = timestamp_before_wait; diff --git a/package/utils/busybox/patches/203-udhcpc_renew_no_deconfig.patch b/package/utils/busybox/patches/203-udhcpc_renew_no_deconfig.patch index 3d3c0cc403ea..ea81c91c9b61 100644 --- a/package/utils/busybox/patches/203-udhcpc_renew_no_deconfig.patch +++ b/package/utils/busybox/patches/203-udhcpc_renew_no_deconfig.patch @@ -1,6 +1,6 @@ --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c -@@ -1126,7 +1126,6 @@ static void perform_renew(void) +@@ -1086,7 +1086,6 @@ static void perform_renew(void) client_data.state = RENEW_REQUESTED; break; case RENEW_REQUESTED: /* impatient are we? fine, square 1 */ diff --git a/package/utils/busybox/patches/230-add_nslookup_lede.patch b/package/utils/busybox/patches/230-add_nslookup_lede.patch index f0ac4b51c15a..9b0947fdc941 100644 --- a/package/utils/busybox/patches/230-add_nslookup_lede.patch +++ b/package/utils/busybox/patches/230-add_nslookup_lede.patch @@ -19,9 +19,9 @@ Signed-off-by: Jo-Philipp Wich --- a/Makefile.flags +++ b/Makefile.flags -@@ -134,6 +134,12 @@ else - LDLIBS += m - endif +@@ -157,6 +157,12 @@ endif + # libm may be needed for dc, awk, ntpd + # librt may be needed for clock_gettime() +# nslookup_lede might need the resolv library +RESOLV_AVAILABLE := $(shell echo 'int main(void){res_init();return 0;}' >resolvtest.c; $(CC) $(CFLAGS) -include resolv.h -lresolv -o /dev/null resolvtest.c >/dev/null 2>&1 && echo "y"; rm resolvtest.c) diff --git a/package/utils/busybox/patches/250-date-k-flag.patch b/package/utils/busybox/patches/250-date-k-flag.patch index 5aadbb233c6a..bbdd1a30df3b 100644 --- a/package/utils/busybox/patches/250-date-k-flag.patch +++ b/package/utils/busybox/patches/250-date-k-flag.patch @@ -1,6 +1,6 @@ --- a/coreutils/date.c +++ b/coreutils/date.c -@@ -123,6 +123,7 @@ +@@ -122,6 +122,7 @@ //usage: IF_FEATURE_DATE_ISOFMT( //usage: "\n -D FMT Use FMT (strptime format) for -d TIME conversion" //usage: ) @@ -8,7 +8,7 @@ //usage: "\n" //usage: "\nRecognized TIME formats:" //usage: "\n hh:mm[:ss]" -@@ -139,9 +140,8 @@ +@@ -138,9 +139,8 @@ #include "libbb.h" #include "common_bufsiz.h" @@ -20,7 +20,7 @@ enum { OPT_RFC2822 = (1 << 0), /* R */ -@@ -149,8 +149,9 @@ enum { +@@ -148,8 +148,9 @@ enum { OPT_UTC = (1 << 2), /* u */ OPT_DATE = (1 << 3), /* d */ OPT_REFERENCE = (1 << 4), /* r */ @@ -32,7 +32,7 @@ }; #if ENABLE_LONG_OPTS -@@ -162,6 +163,7 @@ static const char date_longopts[] ALIGN1 +@@ -161,6 +162,7 @@ static const char date_longopts[] ALIGN1 /* "universal\0" No_argument "u" */ "date\0" Required_argument "d" "reference\0" Required_argument "r" @@ -40,7 +40,7 @@ ; #endif -@@ -181,6 +183,8 @@ static void maybe_set_utc(int opt) +@@ -180,6 +182,8 @@ static void maybe_set_utc(int opt) int date_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; int date_main(int argc UNUSED_PARAM, char **argv) { @@ -49,7 +49,7 @@ struct timespec ts; struct tm tm_time; char buf_fmt_dt2str[64]; -@@ -193,7 +197,7 @@ int date_main(int argc UNUSED_PARAM, cha +@@ -192,7 +196,7 @@ int date_main(int argc UNUSED_PARAM, cha char *isofmt_arg = NULL; opt = getopt32long(argv, "^" @@ -58,7 +58,7 @@ IF_FEATURE_DATE_ISOFMT("I::D:") "\0" "d--s:s--d" -@@ -256,6 +260,31 @@ int date_main(int argc UNUSED_PARAM, cha +@@ -255,6 +259,31 @@ int date_main(int argc UNUSED_PARAM, cha if (*argv) bb_show_usage();