pmaports/cross/gcc-x86_64/0042-libsanitizer-struct_sock_fprog_sz.patch
Oliver Smith 060e35c8df
cross/gcc-*: upgrade to 15.2.0-r3
Regenerate the cross/gcc packages against Alpine's aports with
pmbootstrap's current main branch.

Related: 05d31c9bcf
Signed-off-by: Oliver Smith <ollieparanoid@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8240>
2026-04-12 12:30:11 +00:00

31 lines
1.3 KiB
Diff

Provide struct_sock_fprog_sz on Linux, rather than on Linux+glibc.
With `#include <linux/filter.h>` `struct sock_fprog` is available when
linux headers are available. It seems that glibc is just including that header
as an implementation detail, while musl does not.
--- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp 2025-08-08 08:51:45.621434001 +0200
+++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp 2026-02-25 20:29:28.519492722 +0100
@@ -74,6 +74,7 @@
#include <sys/vt.h>
#include <linux/cdrom.h>
#include <linux/fd.h>
+#include <linux/filter.h>
#if SANITIZER_ANDROID
#include <linux/fs.h>
#endif
@@ -507,6 +508,7 @@ unsigned struct_ElfW_Phdr_sz = sizeof(El
unsigned struct_seq_event_rec_sz = sizeof(struct seq_event_rec);
unsigned struct_synth_info_sz = sizeof(struct synth_info);
unsigned struct_vt_mode_sz = sizeof(struct vt_mode);
+ unsigned struct_sock_fprog_sz = sizeof(struct sock_fprog);
#endif // SANITIZER_LINUX
#if SANITIZER_GLIBC
@@ -534,7 +536,6 @@ unsigned struct_ElfW_Phdr_sz = sizeof(El
unsigned struct_audio_buf_info_sz = sizeof(struct audio_buf_info);
unsigned struct_ppp_stats_sz = sizeof(struct ppp_stats);
- unsigned struct_sock_fprog_sz = sizeof(struct sock_fprog);
# endif // SANITIZER_GLIBC
# if !SANITIZER_ANDROID && !SANITIZER_APPLE