The important part of this patch is the change to inclhack.def. The new
fixincl.x was manually generated using AutoGen.
Index: fixincludes/inclhack.def
===================================================================
--- fixincludes/inclhack.def.orig
+++ fixincludes/inclhack.def
@@ -1206,6 +1206,31 @@ fix = {
+ * GCC 4.2 doesn't recognize __has_extension and __has_feature.
+ hackname = darwin_has_extension;
+ select = "__has_extension\\([A-Za-z_]*\\)";
+ test_text = "#if __has_extension(attribute_unavailable_with_message)";
+ hackname = darwin_has_feature;
+ select = "__has_feature\\([A-Za-z_]*\\)";
+ test_text = "#if __has_feature(objc_arc)";
/* APPLE LOCAL begin for-fsf-4_4 5133297 */
* On darwin8 and earlier, mach-o/swap.h isn't properly guarded
Index: fixincludes/fixincl.x
===================================================================
--- fixincludes/fixincl.x.orig
+++ fixincludes/fixincl.x
/* -*- buffer-read-only: t -*- vi: set ro:
* DO NOT EDIT THIS FILE (fixincl.x)
- * It has been AutoGen-ed Friday July 20, 2007 at 02:14:34 PM PDT
+ * It has been AutoGen-ed
* From the definitions inclhack.def
* and the template file fixincl
-/* DO NOT CVS-MERGE THIS FILE, EITHER Fri Jul 20 14:14:34 PDT 2007
+/* DO NOT CVS-MERGE THIS FILE, EITHER Mon Jun 1 01:47:00 EDT 2015
* You must regenerate it. Use the ./genfixes script.
* certain ANSI-incompatible system header files which are fixed to work
* correctly with ANSI C and placed in a directory that GNU C will search.