diff --git a/.checkpackageignore b/.checkpackageignore index b793026881f2..0dcca5ebc7e2 100644 --- a/.checkpackageignore +++ b/.checkpackageignore @@ -271,12 +271,11 @@ package/am33x-cm3/0004-Makefile-add-fno-builtin.patch lib_patch.Upstream package/am33x-cm3/S93-am335x-pm-firmware-load lib_sysv.Variables package/android-tools/0001-Fix-makefiles-for-out-of-tree-build.patch lib_patch.Upstream package/android-tools/0002-Fix-adbd-for-non-Ubuntu-systems.patch lib_patch.Upstream -package/android-tools/0003-Fix-build-issue-with-uclibc.patch lib_patch.Upstream package/android-tools/0004-Fix-build-issue-with-musl.patch lib_patch.Upstream -package/android-tools/0005-Use-pkgconf-to-get-libs-deps.patch lib_patch.Upstream -package/android-tools/0006-fix-big-endian-build.patch lib_patch.Upstream -package/android-tools/0007-include-cdefs-h-when-needed.patch lib_patch.Upstream -package/android-tools/0008-Include-sysmacros.h-to-compile-with-glibc-2.28.patch lib_patch.Sob lib_patch.Upstream +package/android-tools/0005-makefiles-use-pkgconf-to-get-libs-deps.patch lib_patch.Upstream +package/android-tools/0006-Fix-build-on-big-endian-systems.patch lib_patch.Upstream +package/android-tools/0007-Include-cdefs.h-wherever-it-is-needed.patch lib_patch.Upstream +package/android-tools/0008-usb_linux.c-fix-minor-major-build-failure-due-to-gli.patch lib_patch.Upstream package/android-tools/0009-Fix-makefiles-for-out-of-tree-ext4_utils-build.patch lib_patch.Upstream package/android-tools/0010-adb-added-patch-for-openssl-1.1.0-compatibility.patch lib_patch.Upstream package/aoetools/0001-Change-shell-script-interpreter-from-bin-bash-to-bin.patch lib_patch.Upstream diff --git a/boot/grub2/readme.txt b/boot/grub2/readme.txt index 5d59fb4e2217..90866e83a9c1 100644 --- a/boot/grub2/readme.txt +++ b/boot/grub2/readme.txt @@ -10,20 +10,20 @@ Notes on using Grub2 for BIOS-based platforms is enough free space *before* the first partition to store Grub2. Leaving 1 MB of free space is safe. 3. Setup loop device and loop partitions - sudo losetup -f disk.img - sudo partx -a /dev/loop0 + loop_dev=$(sudo losetup -f disk.img) + sudo partx -a "$loop_dev" 4. Prepare the root partition - sudo mkfs.ext3 -L root /dev/loop0p1 - sudo mount /dev/loop0p1 /mnt + sudo mkfs.ext3 -L root "${loop_dev}p1" + sudo mount "${loop_dev}p1" /mnt sudo tar -C /mnt -xf output/images/rootfs.tar sudo umount /mnt 5. Install Grub2 sudo ./output/host/sbin/grub-bios-setup \ -b ./output/host/lib/grub/i386-pc/boot.img \ - -c ./output/images/grub.img -d . /dev/loop0 + -c ./output/images/grub.img -d . "$loop_dev" 6. Cleanup loop device - sudo partx -d /dev/loop0 - sudo losetup -d /dev/loop0 + sudo partx -d "$loop_dev" + sudo losetup -d "$loop_dev" 7. Your disk.img is ready! Using genimage @@ -65,22 +65,22 @@ Notes on using Grub2 for x86/x86_64 EFI-based platforms - Create a second partition, type 8300, for the root filesystem. 3. Setup loop device and loop partitions - sudo losetup -f disk.img - sudo partx -a /dev/loop0 + loop_dev=$(sudo losetup -f disk.img) + sudo partx -a "$loop_dev" 4. Prepare the boot partition - sudo mkfs.vfat -n boot /dev/loop0p1 - sudo mount /dev/loop0p1 /mnt + sudo mkfs.vfat -n boot "${loop_dev}p1" + sudo mount "${loop_dev}p1" /mnt sudo cp -a output/images/efi-part/* /mnt/ sudo cp output/images/bzImage /mnt/ sudo umount /mnt 5. Prepare the root partition - sudo mkfs.ext3 -L root /dev/loop0p2 - sudo mount /dev/loop0p2 /mnt + sudo mkfs.ext3 -L root "${loop_dev}p2" + sudo mount "${loop_dev}p2" /mnt sudo tar -C /mnt -xf output/images/rootfs.tar sudo umount /mnt 6 Cleanup loop device - sudo partx -d /dev/loop0 - sudo losetup -d /dev/loop0 + sudo partx -d "$loop_dev" + sudo losetup -d "$loop_dev" 7. Your disk.img is ready! To test your i386/x86-64 EFI image in Qemu diff --git a/package/alsa-lib/Config.in b/package/alsa-lib/Config.in index 447916a29fa2..6df03afe0ea1 100644 --- a/package/alsa-lib/Config.in +++ b/package/alsa-lib/Config.in @@ -69,6 +69,7 @@ config BR2_PACKAGE_ALSA_LIB_SEQ config BR2_PACKAGE_ALSA_LIB_UCM bool "ucm" default y + depends on BR2_USE_MMU # fork() select BR2_PACKAGE_ALSA_LIB_MIXER config BR2_PACKAGE_ALSA_LIB_ALISP diff --git a/package/android-tools/0001-Fix-makefiles-for-out-of-tree-build.patch b/package/android-tools/0001-Fix-makefiles-for-out-of-tree-build.patch index af0723620fe4..ad047657a173 100644 --- a/package/android-tools/0001-Fix-makefiles-for-out-of-tree-build.patch +++ b/package/android-tools/0001-Fix-makefiles-for-out-of-tree-build.patch @@ -1,4 +1,7 @@ -[PATCH] Fix makefiles for out-of-tree build +From 1fe49c34aa3e32e801af5c56293ec71ff6e7e2bc Mon Sep 17 00:00:00 2001 +From: Gary Bisson +Date: Sun, 1 Dec 2024 15:43:17 +0100 +Subject: [PATCH] Fix makefiles for out-of-tree build Signed-off-by: Gary Bisson --- @@ -158,5 +161,5 @@ index 9e8b751..94a069b 100644 LIBS+= -lz -lselinux -- -2.5.1 +2.47.0 diff --git a/package/android-tools/0002-Fix-adbd-for-non-Ubuntu-systems.patch b/package/android-tools/0002-Fix-adbd-for-non-Ubuntu-systems.patch index 35f6c8a3be25..7f39e6662b0f 100644 --- a/package/android-tools/0002-Fix-adbd-for-non-Ubuntu-systems.patch +++ b/package/android-tools/0002-Fix-adbd-for-non-Ubuntu-systems.patch @@ -1,4 +1,7 @@ -[PATCH] Fix adbd for non-Ubuntu systems +From d433d5c340f3b36de58ea8550fd140dbdaea13b4 Mon Sep 17 00:00:00 2001 +From: Gary Bisson +Date: Sun, 1 Dec 2024 15:43:33 +0100 +Subject: [PATCH] Fix adbd for non-Ubuntu systems Remove glib/dbus dependencies and partially restore services.c to be closer to the original source code in order to run on systems without @@ -7,7 +10,7 @@ sudo. Signed-off-by: Gary Bisson --- core/adbd/adb.c | 1 - - core/adbd/services.c | 160 ++++------------------------------------------- + core/adbd/services.c | 160 +++------------------------------------ debian/makefiles/adbd.mk | 4 +- 3 files changed, 14 insertions(+), 151 deletions(-) @@ -260,5 +263,5 @@ index 49dab8c..22c1816 100644 OBJS= $(patsubst %, %.o, $(basename $(SRCS))) -- -2.5.1 +2.47.0 diff --git a/package/android-tools/0003-Adjust-base64-function-handling.patch b/package/android-tools/0003-Adjust-base64-function-handling.patch new file mode 100644 index 000000000000..30a6e680b9c9 --- /dev/null +++ b/package/android-tools/0003-Adjust-base64-function-handling.patch @@ -0,0 +1,96 @@ +From 946dbb00fe4b2a75c688a470fc0c3924aa018a24 Mon Sep 17 00:00:00 2001 +From: Thomas Petazzoni +Date: Sun, 14 Jul 2024 11:39:49 +0200 +Subject: [PATCH] Adjust base64 function handling +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +In order to support libcs that do not provide b64_pton(), one of the +Debian patches adds a copy of b64_pton() and b64_ntop(). However, no +prototype is added for those functions, causing an "implicit +declaration" warning... or error depending on the compiler version +used: + +core/adbd/adb_auth_client.c:75:15: error: implicit declaration of function ‘b64_pton’ [-Wimplicit-function-declaration] + +This patch adds appropriate prototypes, but while at it, also renames +the internal copy of b64_*() functions to have an adb_ prefix in order +to clarify things and not clash with definitions potentially coming +from the C library. + +Upstream: N/A, we're too far from upstream +Signed-off-by: Thomas Petazzoni +--- + core/adb/adb_auth_client.c | 3 ++- + core/adbd/adb_auth_client.c | 3 ++- + core/adbd/base64.c | 4 ++-- + 3 files changed, 6 insertions(+), 4 deletions(-) + +diff --git a/core/adb/adb_auth_client.c b/core/adb/adb_auth_client.c +index 0b4913e..25b9828 100644 +--- a/core/adb/adb_auth_client.c ++++ b/core/adb/adb_auth_client.c +@@ -45,6 +45,7 @@ static char *key_paths[] = { + static fdevent listener_fde; + static int framework_fd = -1; + ++extern int adb_b64_pton(char const *src, u_char *target, size_t targsize); + + static void read_keys(const char *file, struct listnode *list) + { +@@ -72,7 +73,7 @@ static void read_keys(const char *file, struct listnode *list) + if (sep) + *sep = '\0'; + +- ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); ++ ret = adb_b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); + if (ret != sizeof(key->key)) { + D("%s: Invalid base64 data ret=%d\n", file, ret); + free(key); +diff --git a/core/adbd/adb_auth_client.c b/core/adbd/adb_auth_client.c +index 0b4913e..25b9828 100644 +--- a/core/adbd/adb_auth_client.c ++++ b/core/adbd/adb_auth_client.c +@@ -45,6 +45,7 @@ static char *key_paths[] = { + static fdevent listener_fde; + static int framework_fd = -1; + ++extern int adb_b64_pton(char const *src, u_char *target, size_t targsize); + + static void read_keys(const char *file, struct listnode *list) + { +@@ -72,7 +73,7 @@ static void read_keys(const char *file, struct listnode *list) + if (sep) + *sep = '\0'; + +- ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); ++ ret = adb_b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); + if (ret != sizeof(key->key)) { + D("%s: Invalid base64 data ret=%d\n", file, ret); + free(key); +diff --git a/core/adbd/base64.c b/core/adbd/base64.c +index 7270703..91fc1b2 100644 +--- a/core/adbd/base64.c ++++ b/core/adbd/base64.c +@@ -134,7 +134,7 @@ static const char Pad64 = '='; + */ + + int +-b64_ntop(src, srclength, target, targsize) ++adb_b64_ntop(src, srclength, target, targsize) + u_char const *src; + size_t srclength; + char *target; +@@ -212,7 +212,7 @@ b64_ntop(src, srclength, target, targsize) + */ + + int +-b64_pton(src, target, targsize) ++adb_b64_pton(src, target, targsize) + char const *src; + u_char *target; + size_t targsize; +-- +2.47.0 + diff --git a/package/android-tools/0003-Fix-build-issue-with-uclibc.patch b/package/android-tools/0003-Fix-build-issue-with-uclibc.patch deleted file mode 100644 index 95517c307b8f..000000000000 --- a/package/android-tools/0003-Fix-build-issue-with-uclibc.patch +++ /dev/null @@ -1,36 +0,0 @@ -[PATCH] Fix build issue with uclibc - -Signed-off-by: Gary Bisson ---- - core/adbd/adb_auth_client.c | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/core/adb/adb_auth_client.c b/core/adb/adb_auth_client.c -index 0b4913e..068d837 100644 ---- a/core/adb/adb_auth_client.c -+++ b/core/adb/adb_auth_client.c -@@ -72,7 +72,7 @@ static void read_keys(const char *file, struct listnode *list) - if (sep) - *sep = '\0'; - -- ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); -+ ret = b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); - if (ret != sizeof(key->key)) { - D("%s: Invalid base64 data ret=%d\n", file, ret); - free(key); -diff --git a/core/adbd/adb_auth_client.c b/core/adbd/adb_auth_client.c -index 0b4913e..068d837 100644 ---- a/core/adbd/adb_auth_client.c -+++ b/core/adbd/adb_auth_client.c -@@ -72,7 +72,7 @@ static void read_keys(const char *file, struct listnode *list) - if (sep) - *sep = '\0'; - -- ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); -+ ret = b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4); - if (ret != sizeof(key->key)) { - D("%s: Invalid base64 data ret=%d\n", file, ret); - free(key); --- -2.6.1 - diff --git a/package/android-tools/0004-Fix-build-issue-with-musl.patch b/package/android-tools/0004-Fix-build-issue-with-musl.patch index 964eb87a6dbe..affd75b25991 100644 --- a/package/android-tools/0004-Fix-build-issue-with-musl.patch +++ b/package/android-tools/0004-Fix-build-issue-with-musl.patch @@ -1,4 +1,7 @@ -[PATCH] Fix build issue with musl +From d14ca3e3362448590adaebacb76d4d8046f9b556 Mon Sep 17 00:00:00 2001 +From: Gary Bisson +Date: Sun, 1 Dec 2024 15:44:16 +0100 +Subject: [PATCH] Fix build issue with musl arpa/nameser.h doesn't use the same macro name to avoid several inclusions. @@ -8,19 +11,12 @@ TEMP_FAILURE_RETRY macro. Signed-off-by: Gary Bisson --- - core/adbd/arpa_nameser.h | 12 +++++++++--- - core/adbd/base64.c | 1 - - core/adbd/framebuffer_service.c | 1 + - core/adbd/qemu_pipe.h | 1 - - core/include/cutils/android_reboot.h | 8 ++++++-- - core/include/cutils/bitops.h | 10 ++++++---- - core/include/cutils/partition_utils.h | 8 ++++++-- - extras/ext4_utils/sha1.c | 3 --- - extras/ext4_utils/sha1.h | 13 ++++++------- - 9 files changed, 34 insertions(+), 23 deletions(-) + core/adbd/arpa_nameser.h | 3 +++ + core/adbd/framebuffer_service.c | 1 + + 2 files changed, 4 insertions(+) diff --git a/core/adbd/arpa_nameser.h b/core/adbd/arpa_nameser.h -index 438dc04..b2a28d6 100644 +index 438dc04..f3d2fee 100644 --- a/core/adbd/arpa_nameser.h +++ b/core/adbd/arpa_nameser.h @@ -52,6 +52,8 @@ @@ -32,7 +28,7 @@ index 438dc04..b2a28d6 100644 #define BIND_4_COMPAT -@@ -574,4 +579,5 @@ __END_DECLS +@@ -574,4 +576,5 @@ __END_DECLS #define XLOG(...) do {} while (0) #endif @@ -51,4 +47,5 @@ index 20c08d2..48e0241 100644 #include #include -- -2.6.1 +2.47.0 + diff --git a/package/android-tools/0005-Use-pkgconf-to-get-libs-deps.patch b/package/android-tools/0005-makefiles-use-pkgconf-to-get-libs-deps.patch similarity index 57% rename from package/android-tools/0005-Use-pkgconf-to-get-libs-deps.patch rename to package/android-tools/0005-makefiles-use-pkgconf-to-get-libs-deps.patch index 63ea1fb6a4d7..8136ac832d2a 100644 --- a/package/android-tools/0005-Use-pkgconf-to-get-libs-deps.patch +++ b/package/android-tools/0005-makefiles-use-pkgconf-to-get-libs-deps.patch @@ -1,4 +1,7 @@ -makefiles: use pkgconf to get libs deps +From 10f3f6fb75da72f155e72794d6647e4fa21a87d0 Mon Sep 17 00:00:00 2001 +From: Giulio Benetti +Date: Sun, 1 Dec 2024 15:45:01 +0100 +Subject: [PATCH] makefiles: use pkgconf to get libs deps LIBS lists library dependencies without taking into account static linking that need ordered listing and more libraries listed since differently from @@ -10,26 +13,36 @@ needed libraries are listed during linking. Signed-off-by: Giulio Benetti --- -diff -urpN android-tools-4.2.2+git20130218.orig/debian/makefiles/adbd.mk android-tools-4.2.2+git20130218/debian/makefiles/adbd.mk ---- android-tools-4.2.2+git20130218.orig/debian/makefiles/adbd.mk 2019-04-08 16:05:02.967710428 +0200 -+++ android-tools-4.2.2+git20130218/debian/makefiles/adbd.mk 2019-04-08 16:30:42.463084426 +0200 + debian/makefiles/adb.mk | 2 +- + debian/makefiles/adbd.mk | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/debian/makefiles/adb.mk b/debian/makefiles/adb.mk +index 654b9f1..a03c93a 100644 +--- a/debian/makefiles/adb.mk ++++ b/debian/makefiles/adb.mk +@@ -41,7 +41,7 @@ CPPFLAGS+= -DHAVE_TERMIO_H + CPPFLAGS+= -I$(SRCDIR)/core/adb + CPPFLAGS+= -I$(SRCDIR)/core/include + +-LIBS+= -lc -lpthread -lz -lcrypto ++LIBS+= -lc -lpthread -lz `pkg-config --libs libcrypto` + + OBJS= $(SRCS:.c=.o) + +diff --git a/debian/makefiles/adbd.mk b/debian/makefiles/adbd.mk +index 22c1816..a8eee3a 100644 +--- a/debian/makefiles/adbd.mk ++++ b/debian/makefiles/adbd.mk @@ -44,7 +44,7 @@ CPPFLAGS+= -DADBD_NON_ANDROID CPPFLAGS+= -I$(SRCDIR)/core/adbd CPPFLAGS+= -I$(SRCDIR)/core/include - + -LIBS+= -lc -lpthread -lz -lcrypto -lcrypt +LIBS+= -lc -lpthread -lz `pkg-config --libs libcrypto` -lcrypt - + OBJS= $(patsubst %, %.o, $(basename $(SRCS))) + +-- +2.47.0 -diff -urpN android-tools-4.2.2+git20130218.orig/debian/makefiles/adb.mk android-tools-4.2.2+git20130218/debian/makefiles/adb.mk ---- android-tools-4.2.2+git20130218.orig/debian/makefiles/adb.mk 2019-04-08 16:05:02.959701400 +0200 -+++ android-tools-4.2.2+git20130218/debian/makefiles/adb.mk 2019-04-08 16:31:06.529426250 +0200 -@@ -41,7 +41,7 @@ CPPFLAGS+= -DHAVE_TERMIO_H - CPPFLAGS+= -I$(SRCDIR)/core/adb - CPPFLAGS+= -I$(SRCDIR)/core/include - --LIBS+= -lc -lpthread -lz -lcrypto -+LIBS+= -lc -lpthread -lz `pkg-config --libs libcrypto` - - OBJS= $(SRCS:.c=.o) diff --git a/package/android-tools/0006-fix-big-endian-build.patch b/package/android-tools/0006-Fix-build-on-big-endian-systems.patch similarity index 75% rename from package/android-tools/0006-fix-big-endian-build.patch rename to package/android-tools/0006-Fix-build-on-big-endian-systems.patch index c35fdcb8c4cc..d7fcb1cf0fa1 100644 --- a/package/android-tools/0006-fix-big-endian-build.patch +++ b/package/android-tools/0006-Fix-build-on-big-endian-systems.patch @@ -1,4 +1,7 @@ -Fix build on big endian systems +From 8f7e9458dbfca969d3edc9cf409b3439e98f4c5a Mon Sep 17 00:00:00 2001 +From: Thomas Petazzoni +Date: Sun, 1 Dec 2024 15:45:26 +0100 +Subject: [PATCH] Fix build on big endian systems The usb_linux_client.c file defines cpu_to_le16/32 by using the C library htole16/32 function calls. However, cpu_to_le16/32 are used @@ -14,9 +17,13 @@ To solve this, we simply open-code cpu_to_le16/32 in a way that allows them to be used when initializing structures. Signed-off-by: Thomas Petazzoni +--- + core/adb/usb_linux_client.c | 11 +++++++++-- + core/adbd/usb_linux_client.c | 11 +++++++++-- + 2 files changed, 18 insertions(+), 4 deletions(-) -Index: b/core/adb/usb_linux_client.c -=================================================================== +diff --git a/core/adb/usb_linux_client.c b/core/adb/usb_linux_client.c +index fb1dad0..a981e96 100644 --- a/core/adb/usb_linux_client.c +++ b/core/adb/usb_linux_client.c @@ -34,8 +34,15 @@ @@ -37,8 +44,8 @@ Index: b/core/adb/usb_linux_client.c struct usb_handle { -Index: b/core/adbd/usb_linux_client.c -=================================================================== +diff --git a/core/adbd/usb_linux_client.c b/core/adbd/usb_linux_client.c +index 33875a8..0e4d200 100644 --- a/core/adbd/usb_linux_client.c +++ b/core/adbd/usb_linux_client.c @@ -34,8 +34,15 @@ @@ -59,3 +66,6 @@ Index: b/core/adbd/usb_linux_client.c struct usb_handle { +-- +2.47.0 + diff --git a/package/android-tools/0007-include-cdefs-h-when-needed.patch b/package/android-tools/0007-Include-cdefs.h-wherever-it-is-needed.patch similarity index 71% rename from package/android-tools/0007-include-cdefs-h-when-needed.patch rename to package/android-tools/0007-Include-cdefs.h-wherever-it-is-needed.patch index da4ee13a175e..d4e483c6d793 100644 --- a/package/android-tools/0007-include-cdefs-h-when-needed.patch +++ b/package/android-tools/0007-Include-cdefs.h-wherever-it-is-needed.patch @@ -1,4 +1,7 @@ -Include cdefs.h wherever it is needed +From d3f0157bf2ac1afc9a810ccbe188110df724129d Mon Sep 17 00:00:00 2001 +From: "Yann E. MORIN" +Date: Sun, 1 Dec 2024 15:46:15 +0100 +Subject: [PATCH] Include cdefs.h wherever it is needed cdefs.h is included from within a lot of glibc headers, so it almost invariably and automagically gets pulled in with glibc. @@ -11,12 +14,12 @@ So we must include it when we are going to use macros it provides. Signed-off-by: "Yann E. MORIN" --- - core/adbd/services.c | 1 + - core/libcutils/android_reboot.c | 1 + - 2 files changed, 2 insertions(+), 0 deletion(-) + core/adbd/services.c | 1 + + core/libcutils/android_reboot.c | 1 + + 2 files changed, 2 insertions(+) diff --git a/core/adbd/services.c b/core/adbd/services.c -index 20c08d2..48e0241 100644 +index 5adcefe..6de1951 100644 --- a/core/adbd/services.c +++ b/core/adbd/services.c @@ -20,6 +20,7 @@ @@ -28,7 +31,7 @@ index 20c08d2..48e0241 100644 #include "sysdeps.h" diff --git a/core/libcutils/android_reboot.c b/core/libcutils/android_reboot.c -index 20c08d2..48e0241 100644 +index 79c05f8..9386006 100644 --- a/core/libcutils/android_reboot.c +++ b/core/libcutils/android_reboot.c @@ -23,6 +23,7 @@ @@ -39,3 +42,6 @@ index 20c08d2..48e0241 100644 #include +-- +2.47.0 + diff --git a/package/android-tools/0008-Include-sysmacros.h-to-compile-with-glibc-2.28.patch b/package/android-tools/0008-Include-sysmacros.h-to-compile-with-glibc-2.28.patch deleted file mode 100644 index 77b457f6042f..000000000000 --- a/package/android-tools/0008-Include-sysmacros.h-to-compile-with-glibc-2.28.patch +++ /dev/null @@ -1,42 +0,0 @@ -usb_linux.c: fix minor()/major() build failure due to glibc 2.28 - -glibc 2.28 no longer includes from , -and therefore must be included explicitly when -major()/minor() are used. - -This commit adds a patch to directly include into -all usb_linux.c files where minor() and major() macros are used. - -diff -urpN host-android-tools-4.2.2+git20130218.orig/core/adb/usb_linux.c host-android-tools-4.2.2+git20130218/core/adb/usb_linux.c ---- host-android-tools-4.2.2+git20130218.orig/core/adb/usb_linux.c 2013-02-18 15:49:03.000000000 +0100 -+++ host-android-tools-4.2.2+git20130218/core/adb/usb_linux.c 2018-09-09 11:47:16.476292546 +0200 -@@ -20,6 +20,7 @@ - #include - - #include -+#include - #include - #include - #include -diff -urpN host-android-tools-4.2.2+git20130218.orig/core/adbd/usb_linux.c host-android-tools-4.2.2+git20130218/core/adbd/usb_linux.c ---- host-android-tools-4.2.2+git20130218.orig/core/adbd/usb_linux.c 2018-09-09 02:32:57.154503866 +0200 -+++ host-android-tools-4.2.2+git20130218/core/adbd/usb_linux.c 2018-09-09 11:47:28.148353880 +0200 -@@ -20,6 +20,7 @@ - #include - - #include -+#include - #include - #include - #include -diff -urpN host-android-tools-4.2.2+git20130218.orig/core/fastboot/usb_linux.c host-android-tools-4.2.2+git20130218/core/fastboot/usb_linux.c ---- host-android-tools-4.2.2+git20130218.orig/core/fastboot/usb_linux.c 2013-02-18 15:49:03.000000000 +0100 -+++ host-android-tools-4.2.2+git20130218/core/fastboot/usb_linux.c 2018-09-09 11:46:53.028169154 +0200 -@@ -33,6 +33,7 @@ - - #include - #include -+#include - #include - #include - #include diff --git a/package/android-tools/0008-usb_linux.c-fix-minor-major-build-failure-due-to-gli.patch b/package/android-tools/0008-usb_linux.c-fix-minor-major-build-failure-due-to-gli.patch new file mode 100644 index 000000000000..38b3b9a48233 --- /dev/null +++ b/package/android-tools/0008-usb_linux.c-fix-minor-major-build-failure-due-to-gli.patch @@ -0,0 +1,59 @@ +From 99c20bd08065d9c78d81ba7aa48a2a113ab28c26 Mon Sep 17 00:00:00 2001 +From: Giulio Benetti +Date: Sun, 1 Dec 2024 15:46:50 +0100 +Subject: [PATCH] usb_linux.c: fix minor()/major() build failure due to glibc + 2.28 + +glibc 2.28 no longer includes from , +and therefore must be included explicitly when +major()/minor() are used. + +This commit adds a patch to directly include into +all usb_linux.c files where minor() and major() macros are used. + +Signed-off-by: Giulio Benetti +--- + core/adb/usb_linux.c | 1 + + core/adbd/usb_linux.c | 1 + + core/fastboot/usb_linux.c | 1 + + 3 files changed, 3 insertions(+) + +diff --git a/core/adb/usb_linux.c b/core/adb/usb_linux.c +index 7bf2057..f748267 100644 +--- a/core/adb/usb_linux.c ++++ b/core/adb/usb_linux.c +@@ -20,6 +20,7 @@ + #include + + #include ++#include + #include + #include + #include +diff --git a/core/adbd/usb_linux.c b/core/adbd/usb_linux.c +index 7bf2057..f748267 100644 +--- a/core/adbd/usb_linux.c ++++ b/core/adbd/usb_linux.c +@@ -20,6 +20,7 @@ + #include + + #include ++#include + #include + #include + #include +diff --git a/core/fastboot/usb_linux.c b/core/fastboot/usb_linux.c +index b7a9ca3..2dac62b 100644 +--- a/core/fastboot/usb_linux.c ++++ b/core/fastboot/usb_linux.c +@@ -33,6 +33,7 @@ + + #include + #include ++#include + #include + #include + #include +-- +2.47.0 + diff --git a/package/android-tools/0009-Fix-makefiles-for-out-of-tree-ext4_utils-build.patch b/package/android-tools/0009-Fix-makefiles-for-out-of-tree-ext4_utils-build.patch index 80ea1ec1fee2..94216102cf43 100644 --- a/package/android-tools/0009-Fix-makefiles-for-out-of-tree-ext4_utils-build.patch +++ b/package/android-tools/0009-Fix-makefiles-for-out-of-tree-ext4_utils-build.patch @@ -1,4 +1,4 @@ -From d24abbec201975a5eb7f8589614cfb424b8c80b6 Mon Sep 17 00:00:00 2001 +From 3c4319da20fab4e48ec02e28f5b013b4a33b5fe4 Mon Sep 17 00:00:00 2001 From: Alex Kaplan Date: Sat, 10 Nov 2018 19:50:51 -0800 Subject: [PATCH] Fix makefiles for out-of-tree ext4_utils build @@ -44,5 +44,5 @@ index cb64916..c5904bf 100644 LIBS+= -lz -lselinux -- -2.7.4 +2.47.0 diff --git a/package/android-tools/0010-adb-added-patch-for-openssl-1.1.0-compatibility.patch b/package/android-tools/0010-adb-added-patch-for-openssl-1.1.0-compatibility.patch index 2de338368f4c..96ca5b737a2a 100644 --- a/package/android-tools/0010-adb-added-patch-for-openssl-1.1.0-compatibility.patch +++ b/package/android-tools/0010-adb-added-patch-for-openssl-1.1.0-compatibility.patch @@ -1,4 +1,4 @@ -From bb3da0e32be4f2260940edf3ee0f88103dfd0dcc Mon Sep 17 00:00:00 2001 +From 79bf5cdee607241434e0d1c5b72e724eb1d20102 Mon Sep 17 00:00:00 2001 From: Eneas U de Queiroz Date: Tue, 5 Feb 2019 01:12:19 +0200 Subject: [PATCH] adb: added patch for openssl 1.1.0 compatibility @@ -43,5 +43,5 @@ index 9039d42..debd2ef 100644 out: BN_free(n0inv); -- -2.14.1 +2.47.0 diff --git a/package/android-tools/0011-core-fastboot-fastboot.c-reorder-functions-to-avoid-.patch b/package/android-tools/0011-core-fastboot-fastboot.c-reorder-functions-to-avoid-.patch index b5592e6992db..17a7619bf05c 100644 --- a/package/android-tools/0011-core-fastboot-fastboot.c-reorder-functions-to-avoid-.patch +++ b/package/android-tools/0011-core-fastboot-fastboot.c-reorder-functions-to-avoid-.patch @@ -1,4 +1,4 @@ -From 9724d78fda4eb023f83d2fd30e665b436d7a7f97 Mon Sep 17 00:00:00 2001 +From 6919b6619a9c744d2220f7af6e211c50662ba94b Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Sun, 14 Jul 2024 11:41:10 +0200 Subject: [PATCH] core/fastboot/fastboot.c: reorder functions to avoid implicit @@ -50,5 +50,5 @@ index 3de6d7d..9b2c86f 100644 { if (match_fastboot_with_serial(info, NULL) == 0) { -- -2.45.2 +2.47.0 diff --git a/package/android-tools/0012-core-libsparse-sparse_read.c-add-missing-output_file.patch b/package/android-tools/0012-core-libsparse-sparse_read.c-add-missing-output_file.patch index 9a6a77eceb69..9e35a4782d5c 100644 --- a/package/android-tools/0012-core-libsparse-sparse_read.c-add-missing-output_file.patch +++ b/package/android-tools/0012-core-libsparse-sparse_read.c-add-missing-output_file.patch @@ -1,4 +1,4 @@ -From 2812c2005cfa4bfc5741651c8310e36f28c0327e Mon Sep 17 00:00:00 2001 +From 72b9e79c81a237f1839afb4fdee680eafdd180d9 Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Sun, 14 Jul 2024 11:41:56 +0200 Subject: [PATCH] core/libsparse/sparse_read.c: add missing output_file.h @@ -33,5 +33,5 @@ index 704bcfa..0a8f838 100644 #if defined(__APPLE__) && defined(__MACH__) #define lseek64 lseek -- -2.45.2 +2.47.0 diff --git a/package/android-tools/0013-extras-ext4_utils-make_ext4fs_main.c-disable-Android.patch b/package/android-tools/0013-extras-ext4_utils-make_ext4fs_main.c-disable-Android.patch index c11e88bf07e3..b6902982f7b9 100644 --- a/package/android-tools/0013-extras-ext4_utils-make_ext4fs_main.c-disable-Android.patch +++ b/package/android-tools/0013-extras-ext4_utils-make_ext4fs_main.c-disable-Android.patch @@ -1,4 +1,4 @@ -From 83f9bed233b86dd2bbf603611b13b673caeccb69 Mon Sep 17 00:00:00 2001 +From 01e86db8460d873aec15d658bfc717b026c0545f Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Sun, 14 Jul 2024 11:46:51 +0200 Subject: [PATCH] extras/ext4_utils/make_ext4fs_main.c: disable @@ -50,5 +50,5 @@ index 17d3735..cb58011 100644 if (!sehnd && mountpoint) { sehnd = selinux_android_file_context_handle(); -- -2.45.2 +2.47.0 diff --git a/package/android-tools/0014-core-adbd-adb.c-open-code-capset.patch b/package/android-tools/0014-core-adbd-adb.c-open-code-capset.patch index 1496b8bca438..36a9208c6040 100644 --- a/package/android-tools/0014-core-adbd-adb.c-open-code-capset.patch +++ b/package/android-tools/0014-core-adbd-adb.c-open-code-capset.patch @@ -1,4 +1,4 @@ -From 2b5060146b0890f7f1a63ef891af1358b8cdf9bc Mon Sep 17 00:00:00 2001 +From 850fd3f4a0384ebe492a466a9b1149060619aacb Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Sun, 14 Jul 2024 12:57:22 +0200 Subject: [PATCH] core/adbd/adb.c: open code capset() @@ -48,5 +48,5 @@ index 7fe6445..98b1de1 100644 D("Local port disabled\n"); } else { -- -2.45.2 +2.47.0 diff --git a/package/android-tools/0015-core-adbd-adb.c-include-correct-header-for-prctl.patch b/package/android-tools/0015-core-adbd-adb.c-include-correct-header-for-prctl.patch index cfbefecb2688..0a35dbcc741d 100644 --- a/package/android-tools/0015-core-adbd-adb.c-include-correct-header-for-prctl.patch +++ b/package/android-tools/0015-core-adbd-adb.c-include-correct-header-for-prctl.patch @@ -1,4 +1,4 @@ -From c14070011e070d8674cf3578708cbae433090a47 Mon Sep 17 00:00:00 2001 +From 8f351150de38641c8ce2e9b7f9a5cba29ccd8f7e Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni Date: Sun, 14 Jul 2024 13:00:02 +0200 Subject: [PATCH] core/adbd/adb.c: include correct header for prctl() @@ -30,5 +30,5 @@ index 98b1de1..10f420b 100644 #else #include "usb_vendors.h" -- -2.45.2 +2.47.0 diff --git a/package/android-tools/0016-extras-ext4_utils-make_ext4fs.c-define-__SANE_USERSP.patch b/package/android-tools/0016-extras-ext4_utils-make_ext4fs.c-define-__SANE_USERSP.patch new file mode 100644 index 000000000000..5f3650cc7764 --- /dev/null +++ b/package/android-tools/0016-extras-ext4_utils-make_ext4fs.c-define-__SANE_USERSP.patch @@ -0,0 +1,68 @@ +From 5db9529436f13b8c073a0310da3a1107f84645da Mon Sep 17 00:00:00 2001 +From: Thomas Petazzoni +Date: Wed, 4 Dec 2024 20:51:22 +0100 +Subject: [PATCH] extras/ext4_utils/make_ext4fs.c: define + __SANE_USERSPACE_TYPES__ +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +The Debian patch ppc64el-ftbfs.patch is already defining +__SANE_USERSPACE_TYPES__ in a few files to solve a conflict between +kernel header definitions and local definition of some types, on +powerpc64 and mips64. + +However, the Debian patch lacks an update to ext4_utils.c, and has the +definition too late in make_ext4fs.c. This commit therefore fixes +those two remaining issues, fixing: + +error: conflicting types for ‘u64’; have ‘long unsigned int’ + +Upstream: N/A, we're too far from upstream +Signed-off-by: Thomas Petazzoni +--- + extras/ext4_utils/ext4_utils.c | 5 ++++- + extras/ext4_utils/make_ext4fs.c | 4 ++++ + 2 files changed, 8 insertions(+), 1 deletion(-) + +diff --git a/extras/ext4_utils/ext4_utils.c b/extras/ext4_utils/ext4_utils.c +index e95f5cc..9f6836f 100644 +--- a/extras/ext4_utils/ext4_utils.c ++++ b/extras/ext4_utils/ext4_utils.c +@@ -14,6 +14,10 @@ + * limitations under the License. + */ + ++#if defined(__linux__) ++#define __SANE_USERSPACE_TYPES__ ++#endif ++ + #include "ext4_utils.h" + #include "uuid.h" + #include "allocate.h" +@@ -36,7 +40,6 @@ + #endif + + #if defined(__linux__) +-#define __SANE_USERSPACE_TYPES__ + #include + #elif defined(__APPLE__) && defined(__MACH__) + #include +diff --git a/extras/ext4_utils/make_ext4fs.c b/extras/ext4_utils/make_ext4fs.c +index 3124aed..332a213 100644 +--- a/extras/ext4_utils/make_ext4fs.c ++++ b/extras/ext4_utils/make_ext4fs.c +@@ -14,6 +14,10 @@ + * limitations under the License. + */ + ++#if defined(__linux__) ++#define __SANE_USERSPACE_TYPES__ ++#endif ++ + #include "make_ext4fs.h" + #include "ext4_utils.h" + #include "allocate.h" +-- +2.47.0 + diff --git a/package/gnutls/gnutls.mk b/package/gnutls/gnutls.mk index a5012b1b218b..2584f843ad84 100644 --- a/package/gnutls/gnutls.mk +++ b/package/gnutls/gnutls.mk @@ -62,11 +62,11 @@ HOST_GNUTLS_CONF_OPTS = \ --without-tpm \ --without-tpm2 \ --disable-openssl-compatibility \ - --without-libbrotli \ + --without-brotli \ --without-idn \ --without-p11-kit \ --without-zlib \ - --without-libzstd + --without-zstd ifeq ($(BR2_PACKAGE_GNUTLS_OPENSSL),y) GNUTLS_LICENSE += , GPL-3.0+ (gnutls-openssl library) @@ -77,10 +77,10 @@ GNUTLS_CONF_OPTS += --disable-openssl-compatibility endif ifeq ($(BR2_PACKAGE_BROTLI),y) -GNUTLS_CONF_OPTS += --with-libbrotli +GNUTLS_CONF_OPTS += --with-brotli GNUTLS_DEPENDENCIES += brotli else -GNUTLS_CONF_OPTS += --without-libbrotli +GNUTLS_CONF_OPTS += --without-brotli endif ifeq ($(BR2_PACKAGE_CRYPTODEV_LINUX),y) @@ -110,10 +110,10 @@ GNUTLS_CONF_OPTS += --without-zlib endif ifeq ($(BR2_PACKAGE_ZSTD),y) -GNUTLS_CONF_OPTS += --with-libzstd +GNUTLS_CONF_OPTS += --with-zstd GNUTLS_DEPENDENCIES += zstd else -GNUTLS_CONF_OPTS += --without-libzstd +GNUTLS_CONF_OPTS += --without-zstd endif # Provide a default CA cert location diff --git a/package/libvpl/Config.in b/package/libvpl/Config.in index b9e9a20fd775..5a370ed2e39a 100644 --- a/package/libvpl/Config.in +++ b/package/libvpl/Config.in @@ -1,6 +1,6 @@ config BR2_PACKAGE_LIBVPL_ARCH_SUPPORTS bool - default y if BR2_ARCH_IS_64 + default y if BR2_ARCH_IS_64 && !BR2_mips64 && !BR2_mips64el default y if BR2_arm config BR2_PACKAGE_LIBVPL diff --git a/package/musl/0003-use-hidden-visibility-for-C-entry-point-function-_st.patch b/package/musl/0003-use-hidden-visibility-for-C-entry-point-function-_st.patch new file mode 100644 index 000000000000..6359565cd72e --- /dev/null +++ b/package/musl/0003-use-hidden-visibility-for-C-entry-point-function-_st.patch @@ -0,0 +1,42 @@ +From 9c78557af0a5e521cdb46a4ca7630f2987d2523e Mon Sep 17 00:00:00 2001 +From: Rich Felker +Date: Sat, 10 Aug 2024 19:49:24 -0400 +Subject: [PATCH] use hidden visibility for C entry point function _start_c + +the file-level crt_arch.h asm fragments generally make direct +(non-PLT) calls from _start to _start_c, which is only valid when +there is a local, non-interposable definition for _start_c. generally, +the linker is expected to know that local definitions in a main +executable (as opposed to shared library) output are non-interposable, +making this work, but historically there have been linker bugs in this +area, and microblaze is reportedly still broken, flagging the +relocation for the call as a textrel. + +the equivalent _dlstart_c, called from the same crt_arch.h asm +fragments, has always used hidden visibility without problem, and +semantically it should be hidden, so make it hidden. this ensures the +direct call is always valid regardless of whether the linker properly +special-cases main executable output. + +Upstream: https://git.musl-libc.org/cgit/musl/commit/?id=9c78557af0a5e521cdb46a4ca7630f2987d2523e +Signed-off-by: J. Neuschäfer +--- + crt/crt1.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/crt/crt1.c b/crt/crt1.c +index 8fe8ab5d..10601215 100644 +--- a/crt/crt1.c ++++ b/crt/crt1.c +@@ -11,7 +11,7 @@ weak void _fini(); + int __libc_start_main(int (*)(), int, char **, + void (*)(), void(*)(), void(*)()); + +-void _start_c(long *p) ++hidden void _start_c(long *p) + { + int argc = p[0]; + char **argv = (void *)(p+1); +-- +2.45.2 + diff --git a/package/nfs-utils/nfs-utils.mk b/package/nfs-utils/nfs-utils.mk index b757e3e51dcf..9ea3bae79daa 100644 --- a/package/nfs-utils/nfs-utils.mk +++ b/package/nfs-utils/nfs-utils.mk @@ -79,7 +79,7 @@ NFS_UTILS_POST_INSTALL_TARGET_HOOKS += NFS_UTILS_INSTALL_FIXUP ifeq ($(BR2_INIT_SYSTEMD),y) NFS_UTILS_CONF_OPTS += --with-systemd=/usr/lib/systemd/system -NFS_UTILS_DEPENDENCIES += systemd +NFS_UTILS_DEPENDENCIES += systemd host-systemd else NFS_UTILS_CONF_OPTS += --without-systemd endif diff --git a/package/opkg/opkg.mk b/package/opkg/opkg.mk index 0323a49f0b3e..4922d8fc0f89 100644 --- a/package/opkg/opkg.mk +++ b/package/opkg/opkg.mk @@ -13,7 +13,7 @@ OPKG_INSTALL_STAGING = YES OPKG_CONF_OPTS = \ --enable-sha256 \ --without-acl \ - --without-xattrs + --without-xattr ifeq ($(BR2_PACKAGE_OPKG_GPG_SIGN),y) OPKG_CONF_OPTS += --enable-gpg diff --git a/package/polkit/0001-meson-disable-PIDFD-when-systemd-is-not-available.patch b/package/polkit/0001-meson-disable-PIDFD-when-systemd-is-not-available.patch new file mode 100644 index 000000000000..621b1feef7e5 --- /dev/null +++ b/package/polkit/0001-meson-disable-PIDFD-when-systemd-is-not-available.patch @@ -0,0 +1,53 @@ +From 51a1c5b5ab616fe0243b40baddb4864199bbe624 Mon Sep 17 00:00:00 2001 +From: Romain Naour +Date: Sat, 2 Nov 2024 23:33:16 +0100 +Subject: [PATCH] meson: disable PIDFD when systemd is not available + +Since the Polkit version bump 125, TestPolkitInitd fail due to an +upstream issue related to the new PIDFD support introduced in +Polkit 124 [1]. + +The PIDFD issue only affect OS without systemd. + +Only enable PIDFD support when systemd is available until +upstream fix the issue. + +Fixes: +https://gitlab.com/buildroot.org/buildroot/-/jobs/8199992596 + +[1] https://github.com/polkit-org/polkit/issues/451 + +Upstream: Not applicable + +Signed-off-by: Romain Naour +--- + meson.build | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/meson.build b/meson.build +index 302c189..5c247f4 100644 +--- a/meson.build ++++ b/meson.build +@@ -202,8 +202,6 @@ if enable_logind + endif + config_data.set('HAVE_LIBSYSTEMD', enable_logind) + +-config_data.set('HAVE_PIDFD_OPEN', cc.get_define('SYS_pidfd_open', prefix: '#include ') != '') +- + # systemd unit / sysuser / tmpfiles.d file installation directories + systemdsystemunitdir = get_option('systemdsystemunitdir') + systemd_dep = dependency('systemd', required : false) +@@ -222,6 +220,10 @@ else + tmpfiles_dir = '/usr/lib/tmpfiles.d' + endif + ++# PIDFD is broken with sysvinit based OS since 124 release ++# https://github.com/polkit-org/polkit/issues/451 ++config_data.set('HAVE_PIDFD_OPEN', systemd_dep.found() and cc.get_define('SYS_pidfd_open', prefix: '#include ') != '') ++ + # User for running polkitd + polkitd_user = get_option('polkitd_user') + config_data.set_quoted('POLKITD_USER', polkitd_user) +-- +2.45.0 + diff --git a/package/python-psycopg2/Config.in b/package/python-psycopg2/Config.in index 4aa86c76908b..6b07b0c06cc5 100644 --- a/package/python-psycopg2/Config.in +++ b/package/python-psycopg2/Config.in @@ -1,6 +1,8 @@ config BR2_PACKAGE_PYTHON_PSYCOPG2 bool "python-psycopg2" + depends on BR2_USE_MMU # postgresql depends on BR2_USE_WCHAR # postgresql + depends on !BR2_STATIC_LIBS # postgresql depends on !BR2_OPTIMIZE_FAST # postgresql select BR2_PACKAGE_POSTGRESQL help @@ -21,10 +23,11 @@ config BR2_PACKAGE_PYTHON_PSYCOPG2 customized thanks to a flexible objects adaptation system. Psycopg 2 is both Unicode and Python 3 friendly. - http://initd.org/psycopg/ + https://github.com/psycopg/psycopg2/ -comment "python-psycopg2 needs a toolchain w/ wchar" - depends on !BR2_USE_WCHAR +comment "python-psycopg2 needs a toolchain w/ dynamic library, wchar" + depends on BR2_USE_MMU + depends on BR2_STATIC_LIBS || !BR2_USE_WCHAR comment "python-psycopg2 can't be built with Optimize for fast" depends on BR2_OPTIMIZE_FAST diff --git a/package/rt-tests/rt-tests.mk b/package/rt-tests/rt-tests.mk index 419260db3c8d..e048ee94d096 100644 --- a/package/rt-tests/rt-tests.mk +++ b/package/rt-tests/rt-tests.mk @@ -4,7 +4,7 @@ # ################################################################################ -RT_TESTS_SITE = $(BR2_KERNEL_MIRROR)/linux/utils/rt-tests +RT_TESTS_SITE = $(BR2_KERNEL_MIRROR)/linux/utils/rt-tests/older RT_TESTS_SOURCE = rt-tests-$(RT_TESTS_VERSION).tar.xz RT_TESTS_VERSION = 2.7 RT_TESTS_LICENSE = GPL-2.0+ diff --git a/package/rust/rust.mk b/package/rust/rust.mk index 802aa0f4137f..29c03594d2a8 100644 --- a/package/rust/rust.mk +++ b/package/rust/rust.mk @@ -25,22 +25,6 @@ HOST_RUST_DEPENDENCIES = \ HOST_RUST_VERBOSITY = $(if $(VERBOSE),2,0) -# Some vendor crates contain Cargo.toml.orig files. The associated -# .cargo-checksum.json file will contain a checksum for Cargo.toml.orig but -# support/scripts/apply-patches.sh will delete them. This will cause the build -# to fail, as Cargo will not be able to find the file and verify the checksum. -# So, remove all Cargo.toml.orig entries from the affected .cargo-checksum.json -# files -define HOST_RUST_EXCLUDE_ORIG_FILES - for file in $$(find $(@D) -name '*.orig'); do \ - crate=$$(dirname $${file}); \ - fn=$${crate}/.cargo-checksum.json; \ - sed -i -e 's/"Cargo.toml.orig":"[a-z0-9]\+",//g' $${fn}; \ - done -endef - -HOST_RUST_POST_EXTRACT_HOOKS += HOST_RUST_EXCLUDE_ORIG_FILES - define HOST_RUST_CONFIGURE_CMDS ( \ echo '[build]'; \ diff --git a/package/sexpect/0001-Unconditionally-define-_GNU_SOURCE.patch b/package/sexpect/0001-Unconditionally-define-_GNU_SOURCE.patch new file mode 100644 index 000000000000..bb8b60f0c0d9 --- /dev/null +++ b/package/sexpect/0001-Unconditionally-define-_GNU_SOURCE.patch @@ -0,0 +1,69 @@ +From 7ef4ef027c5064502bba23869aed9d1595a4e301 Mon Sep 17 00:00:00 2001 +Message-ID: <7ef4ef027c5064502bba23869aed9d1595a4e301.1732873390.git.baruch@tkos.co.il> +From: Baruch Siach +Date: Fri, 29 Nov 2024 11:36:16 +0200 +Subject: [PATCH] Unconditionally define _GNU_SOURCE + +uClibc also uses _GNU_SOURCE to expose glibc compatible API extensions. +But toolchain built with uClibc don't define __gnu_linux__. This leads +to implicit declaration warnings at build time. With GCC 14 these +warnings become errors by default. + +For example: + +.../sexpect-2.3.14/server.c: In function 'expect_exact': +.../sexpect-2.3.14/server.c:630:17: error: implicit declaration of function 'strcasestr'; did you mean 'strcasecmp'? + [-Wimplicit-function-declaration] + 630 | found = strcasestr(g.expbuf, g.conn.pass.pattern); + | ^~~~~~~~~~ + | strcasecmp + +Define _GNU_SOURCE unconditionally to fix the build. + +Upstream: https://github.com/clarkwang/sexpect/pull/40 +Signed-off-by: Baruch Siach +--- + main.c | 2 -- + pty.c | 2 -- + server.c | 2 -- + 3 files changed, 6 deletions(-) + +diff --git a/main.c b/main.c +index 886050a887c1..2bc7c867e297 100644 +--- a/main.c ++++ b/main.c +@@ -1,7 +1,5 @@ + +-#if defined(__gnu_linux__) || defined(__CYGWIN__) + #define _GNU_SOURCE +-#endif + + #include + #include +diff --git a/pty.c b/pty.c +index bf4f6e99805e..f90325d87c77 100644 +--- a/pty.c ++++ b/pty.c +@@ -1,7 +1,5 @@ + +-#if defined(__gnu_linux__) || defined(__CYGWIN__) + #define _GNU_SOURCE +-#endif + + #include + #include +diff --git a/server.c b/server.c +index c7e41e0a7dc4..308852f08089 100644 +--- a/server.c ++++ b/server.c +@@ -1,7 +1,5 @@ + +-#if defined(__gnu_linux__) || defined(__CYGWIN__) + #define _GNU_SOURCE +-#endif + + #include + #include +-- +2.45.2 +