diff options
| -rw-r--r-- | meta/recipes-devtools/gcc/gcc-15.1.inc | 1 | ||||
| -rw-r--r-- | meta/recipes-devtools/gcc/gcc/0028-libsanitizer-Fix-build-with-glibc-2.42.patch | 77 |
2 files changed, 78 insertions, 0 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-15.1.inc b/meta/recipes-devtools/gcc/gcc-15.1.inc index 25688aab34..a9a453c8b2 100644 --- a/meta/recipes-devtools/gcc/gcc-15.1.inc +++ b/meta/recipes-devtools/gcc/gcc-15.1.inc | |||
| @@ -74,6 +74,7 @@ SRC_URI = "${BASEURI} \ | |||
| 74 | file://0026-arm-fully-validate-mem_noofs_operand-PR120351.patch \ | 74 | file://0026-arm-fully-validate-mem_noofs_operand-PR120351.patch \ |
| 75 | file://0026-fix-incorrect-preprocessor-line-numbers.patch \ | 75 | file://0026-fix-incorrect-preprocessor-line-numbers.patch \ |
| 76 | file://0027-aarch64-Fix-fma-steering-when-rename-fails-PR120119.patch \ | 76 | file://0027-aarch64-Fix-fma-steering-when-rename-fails-PR120119.patch \ |
| 77 | file://0028-libsanitizer-Fix-build-with-glibc-2.42.patch \ | ||
| 77 | " | 78 | " |
| 78 | 79 | ||
| 79 | UNPACKDIR = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/sources" | 80 | UNPACKDIR = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/sources" |
diff --git a/meta/recipes-devtools/gcc/gcc/0028-libsanitizer-Fix-build-with-glibc-2.42.patch b/meta/recipes-devtools/gcc/gcc/0028-libsanitizer-Fix-build-with-glibc-2.42.patch new file mode 100644 index 0000000000..58b186ee37 --- /dev/null +++ b/meta/recipes-devtools/gcc/gcc/0028-libsanitizer-Fix-build-with-glibc-2.42.patch | |||
| @@ -0,0 +1,77 @@ | |||
| 1 | From d32ece49d32b00448d967e7dbc6900fb25cbc775 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Florian Weimer <fweimer@redhat.com> | ||
| 3 | Date: Fri, 2 May 2025 17:41:43 +0200 | ||
| 4 | Subject: [PATCH] libsanitizer: Fix build with glibc 2.42 | ||
| 5 | |||
| 6 | The termio structure will be removed from glibc 2.42. It has | ||
| 7 | been deprecated since the late 80s/early 90s. | ||
| 8 | |||
| 9 | Cherry-picked from LLVM commit 59978b21ad9c65276ee8e14f26759691b8a65763 | ||
| 10 | ("[sanitizer_common] Remove interceptors for deprecated struct termio | ||
| 11 | (#137403)"). | ||
| 12 | |||
| 13 | Co-Authored-By: Tom Stellard <tstellar@redhat.com> | ||
| 14 | |||
| 15 | libsanitizer/ | ||
| 16 | |||
| 17 | * sanitizer_common/sanitizer_common_interceptors_ioctl.inc: Cherry | ||
| 18 | picked from LLVM commit 59978b21ad9c65276ee8e14f26759691b8a65763. | ||
| 19 | * sanitizer_common/sanitizer_platform_limits_posix.cpp: Likewise. | ||
| 20 | * sanitizer_common/sanitizer_platform_limits_posix.h: Likewise. | ||
| 21 | |||
| 22 | Upstream-Status: Backport [https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=d32ece49d32b00448d967e7dbc6900fb25cbc775] | ||
| 23 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 24 | --- | ||
| 25 | .../sanitizer_common_interceptors_ioctl.inc | 8 -------- | ||
| 26 | .../sanitizer_common/sanitizer_platform_limits_posix.cpp | 3 --- | ||
| 27 | .../sanitizer_common/sanitizer_platform_limits_posix.h | 1 - | ||
| 28 | 3 files changed, 12 deletions(-) | ||
| 29 | |||
| 30 | diff --git a/libsanitizer/sanitizer_common/sanitizer_common_interceptors_ioctl.inc b/libsanitizer/sanitizer_common/sanitizer_common_interceptors_ioctl.inc | ||
| 31 | index 49ec4097c90..dda11daa77f 100644 | ||
| 32 | --- a/libsanitizer/sanitizer_common/sanitizer_common_interceptors_ioctl.inc | ||
| 33 | +++ b/libsanitizer/sanitizer_common/sanitizer_common_interceptors_ioctl.inc | ||
| 34 | @@ -338,17 +338,9 @@ static void ioctl_table_fill() { | ||
| 35 | _(SOUND_PCM_WRITE_CHANNELS, WRITE, sizeof(int)); | ||
| 36 | _(SOUND_PCM_WRITE_FILTER, WRITE, sizeof(int)); | ||
| 37 | _(TCFLSH, NONE, 0); | ||
| 38 | -#if SANITIZER_GLIBC | ||
| 39 | - _(TCGETA, WRITE, struct_termio_sz); | ||
| 40 | -#endif | ||
| 41 | _(TCGETS, WRITE, struct_termios_sz); | ||
| 42 | _(TCSBRK, NONE, 0); | ||
| 43 | _(TCSBRKP, NONE, 0); | ||
| 44 | -#if SANITIZER_GLIBC | ||
| 45 | - _(TCSETA, READ, struct_termio_sz); | ||
| 46 | - _(TCSETAF, READ, struct_termio_sz); | ||
| 47 | - _(TCSETAW, READ, struct_termio_sz); | ||
| 48 | -#endif | ||
| 49 | _(TCSETS, READ, struct_termios_sz); | ||
| 50 | _(TCSETSF, READ, struct_termios_sz); | ||
| 51 | _(TCSETSW, READ, struct_termios_sz); | ||
| 52 | diff --git a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp | ||
| 53 | index c87d5ef42c9..7bbc6f2edac 100644 | ||
| 54 | --- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp | ||
| 55 | +++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp | ||
| 56 | @@ -485,9 +485,6 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr); | ||
| 57 | unsigned struct_input_id_sz = sizeof(struct input_id); | ||
| 58 | unsigned struct_mtpos_sz = sizeof(struct mtpos); | ||
| 59 | unsigned struct_rtentry_sz = sizeof(struct rtentry); | ||
| 60 | -#if SANITIZER_GLIBC || SANITIZER_ANDROID | ||
| 61 | - unsigned struct_termio_sz = sizeof(struct termio); | ||
| 62 | -#endif | ||
| 63 | unsigned struct_vt_consize_sz = sizeof(struct vt_consize); | ||
| 64 | unsigned struct_vt_sizes_sz = sizeof(struct vt_sizes); | ||
| 65 | unsigned struct_vt_stat_sz = sizeof(struct vt_stat); | ||
| 66 | diff --git a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | ||
| 67 | index c07f7cd0b0d..a80df656826 100644 | ||
| 68 | --- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | ||
| 69 | +++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | ||
| 70 | @@ -1029,7 +1029,6 @@ extern unsigned struct_hd_geometry_sz; | ||
| 71 | extern unsigned struct_input_absinfo_sz; | ||
| 72 | extern unsigned struct_input_id_sz; | ||
| 73 | extern unsigned struct_mtpos_sz; | ||
| 74 | -extern unsigned struct_termio_sz; | ||
| 75 | extern unsigned struct_vt_consize_sz; | ||
| 76 | extern unsigned struct_vt_sizes_sz; | ||
| 77 | extern unsigned struct_vt_stat_sz; | ||
