diff options
Diffstat (limited to 'fixincludes/fixincl.x')
-rw-r--r-- | fixincludes/fixincl.x | 70 |
1 files changed, 65 insertions, 5 deletions
diff --git a/fixincludes/fixincl.x b/fixincludes/fixincl.x index 0e283966615..120728ee052 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 Wednesday December 31, 2008 at 02:49:07 PM CET + * It has been AutoGen-ed Wednesday December 31, 2008 at 11:51:30 PM CET * From the definitions inclhack.def * and the template file fixincl */ -/* DO NOT SVN-MERGE THIS FILE, EITHER Wed Dec 31 14:49:07 CET 2008 +/* DO NOT SVN-MERGE THIS FILE, EITHER Wed Dec 31 23:51:30 CET 2008 * * You must regenerate it. Use the ./genfixes script. * @@ -15,7 +15,7 @@ * 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. * - * This file contains 178 fixup descriptions. + * This file contains 179 fixup descriptions. * * See README for more information. * @@ -4699,6 +4699,60 @@ static const char* apzNodeent_SyntaxPatch[] = { /* * * * * * * * * * * * * * * * * * * * * * * * * * * + * Description of Openbsd_Null_Definition fix + */ +tSCC zOpenbsd_Null_DefinitionName[] = + "openbsd_null_definition"; + +/* + * File name selection pattern + */ +tSCC zOpenbsd_Null_DefinitionList[] = + "locale.h\0stddef.h\0stdio.h\0string.h\0time.h\0unistd.h\0wchar.h\0sys/param.h\0"; +/* + * Machine/OS name selection pattern + */ +tSCC* apzOpenbsd_Null_DefinitionMachs[] = { + "*-*-openbsd*", + (const char*)NULL }; + +/* + * content selection pattern - do fix if pattern found + */ +tSCC zOpenbsd_Null_DefinitionSelect0[] = + "__GNUG__"; + +#define OPENBSD_NULL_DEFINITION_TEST_CT 1 +static tTestDesc aOpenbsd_Null_DefinitionTests[] = { + { TT_EGREP, zOpenbsd_Null_DefinitionSelect0, (regex_t*)NULL }, }; + +/* + * Fix Command Arguments for Openbsd_Null_Definition + */ +static const char* apzOpenbsd_Null_DefinitionPatch[] = { + "format", + "#ifndef NULL\n\ +#ifdef __cplusplus\n\ +#ifdef __GNUG__\n\ +#define NULL\t__null\n\ +#else\t /* ! __GNUG__ */\n\ +#define NULL\t0L\n\ +#endif\t /* __GNUG__ */\n\ +#else\t /* ! __cplusplus */\n\ +#define NULL\t((void *)0)\n\ +#endif\t /* __cplusplus */\n\ +#endif\t /* !NULL */", + "^#ifndef[ \t]*NULL\n\ +^#ifdef[ \t]*__GNUG__\n\ +^#define[ \t]*NULL[ \t]*__null\n\ +^#else\n\ +^#define[ \t]*NULL[ \t]*0L\n\ +^#endif\n\ +^#endif", + (char*)NULL }; + +/* * * * * * * * * * * * * * * * * * * * * * * * * * + * * Description of Obstack_Lvalue_Cast fix */ tSCC zObstack_Lvalue_CastName[] = @@ -7219,9 +7273,9 @@ static const char* apzX11_SprintfPatch[] = { * * List of all fixes */ -#define REGEX_COUNT 224 +#define REGEX_COUNT 225 #define MACH_LIST_SIZE_LIMIT 181 -#define FIX_COUNT 178 +#define FIX_COUNT 179 /* * Enumerate the fixes @@ -7343,6 +7397,7 @@ typedef enum { NEXT_VOLITILE_FIXIDX, NEXT_WAIT_UNION_FIXIDX, NODEENT_SYNTAX_FIXIDX, + OPENBSD_NULL_DEFINITION_FIXIDX, OBSTACK_LVALUE_CAST_FIXIDX, OPENBSD_VA_START_FIXIDX, OSF_NAMESPACE_A_FIXIDX, @@ -7988,6 +8043,11 @@ tFixDesc fixDescList[ FIX_COUNT ] = { NODEENT_SYNTAX_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE, aNodeent_SyntaxTests, apzNodeent_SyntaxPatch, 0 }, + { zOpenbsd_Null_DefinitionName, zOpenbsd_Null_DefinitionList, + apzOpenbsd_Null_DefinitionMachs, + OPENBSD_NULL_DEFINITION_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE, + aOpenbsd_Null_DefinitionTests, apzOpenbsd_Null_DefinitionPatch, 0 }, + { zObstack_Lvalue_CastName, zObstack_Lvalue_CastList, apzObstack_Lvalue_CastMachs, OBSTACK_LVALUE_CAST_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE, |