Looks reasonable to me. I don't see a patch to the testing results tho.
The "SVN-MERGE" warns against using subversion merging the file instead
of rebuilding and replacing it. The text for "SVN-MERGE" lives in the
template used to create the "fixincl.x" file.
On 8/28/25 06:56, Jonathan Wakely wrote:
Ping
Original: https://gcc.gnu.org/pipermail/gcc-patches/2025-August/692933.html
On 20/08/25 17:30 +0100, Jonathan Wakely wrote:
The pthread_incomplete_struct_argument fix was intended for ancient
versions of Glibc (only 2.3.3 and 2.3.4, I believe). From Glibc 2.3.5
the pthread.h header already included the change to use a pointer
instead of an array, so the fixinclude was no longer used.
However, the https://sourceware.org/bugzilla/show_bug.cgi?id=26647 fix
changed the __setjmpbuf declaration to use struct __jmp_buf_tag __env[1]
again, which caused this fixinclude to start matching again. This means
that GCC now installs a "fixed" pthread.h with a change to a declaration
that guarded by #if ! __GNUC_PREREQ (11, 0), i.e. it's not even relevant
for modern versions of GCC. The "fixed" pthread.h causes problems for
users because of changes to internal implementation details of the
pthread_cond_t type, which require the "fixed" pthread.h to be updated
with mkheaders if Glibc is updated.
This change adds a bypass to the fixinclude, so that it no longer
matches modern Glibc versions, and only applies to glibc versions 2.3.3
and 2.3.4 as originally intended.
fixincludes/ChangeLog:
PR bootstrap/118009
PR bootstrap/119089
* inclhack.def (pthread_incomplete_struct_argument): Add bypass.
* fixincl.x: Regenerate.
---
Tested x86_64-linux.
OK for trunk?
And release branches?
Aside: should we change the comment talking about SVN-MERGE?
fixincludes/fixincl.x | 15 +++++++++++----
fixincludes/inclhack.def | 1 +
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/fixincludes/fixincl.x b/fixincludes/fixincl.x
index 819c02c483c7..d28262ef9eeb 100644
--- a/fixincludes/fixincl.x
+++ b/fixincludes/fixincl.x
@@ -2,11 +2,11 @@
*
* DO NOT EDIT THIS FILE (fixincl.x)
*
- * It has been AutoGen-ed August 15, 2025 at 05:30:32 PM by AutoGen
5.18.16
+ * It has been AutoGen-ed August 19, 2025 at 04:54:32 PM by AutoGen
5.18.16
* From the definitions inclhack.def
* and the template file fixincl
*/
-/* DO NOT SVN-MERGE THIS FILE, EITHER Fri Aug 15 17:30:32 CEST 2025
+/* DO NOT SVN-MERGE THIS FILE, EITHER Tue Aug 19 16:54:32 BST 2025
*
* You must regenerate it. Use the ./genfixes script.
*
@@ -7547,8 +7547,15 @@ tSCC zPthread_Incomplete_Struct_ArgumentList[] =
tSCC zPthread_Incomplete_Struct_ArgumentSelect0[] =
"struct __jmp_buf_tag";
-#define PTHREAD_INCOMPLETE_STRUCT_ARGUMENT_TEST_CT 1
+/*
+ * content bypass pattern - skip fix if pattern found
+ */
+tSCC zPthread_Incomplete_Struct_ArgumentBypass0[] =
+ "bits/types/struct___jmp_buf_tag.h";
+
+#define PTHREAD_INCOMPLETE_STRUCT_ARGUMENT_TEST_CT 2
static tTestDesc aPthread_Incomplete_Struct_ArgumentTests[] = {
+ { TT_NEGREP, zPthread_Incomplete_Struct_ArgumentBypass0,
(regex_t*)NULL },
{ TT_EGREP, zPthread_Incomplete_Struct_ArgumentSelect0,
(regex_t*)NULL }, };
/*
@@ -11202,7 +11209,7 @@ static const char* apzX11_SprintfPatch[] = {
*
* List of all fixes
*/
-#define REGEX_COUNT 318
+#define REGEX_COUNT 319
#define MACH_LIST_SIZE_LIMIT 187
#define FIX_COUNT 274
diff --git a/fixincludes/inclhack.def b/fixincludes/inclhack.def
index 35ccaf03c4fa..71777cb10e73 100644
--- a/fixincludes/inclhack.def
+++ b/fixincludes/inclhack.def
@@ -3803,6 +3803,7 @@ fix = {
hackname = pthread_incomplete_struct_argument;
files = pthread.h;
select = "struct __jmp_buf_tag";
+ bypass = "bits/types/struct___jmp_buf_tag.h";
c_fix = format;
c_fix_arg = "%1 *%2%3";
c_fix_arg = "^(extern int __sigsetjmp \\(struct __jmp_buf_tag) "