alloca.h: New file.

* tests/base/alloca.h: New file.
	* inclhack.def (hppa_hpux11_alloca): New fix.
	* fixincl.x: Regenerate.

From-SVN: r245364
This commit is contained in:
John David Anglin 2017-02-11 21:11:44 +00:00
parent 99ebfe9075
commit 7d3235372a
4 changed files with 93 additions and 5 deletions

View File

@ -1,3 +1,9 @@
2017-02-11 John David Anglin <danglin@gcc.gnu.org>
* tests/base/alloca.h: New file.
* inclhack.def (hppa_hpux11_alloca): New fix.
* fixincl.x: Regenerate.
2017-01-17 Jakub Jelinek <jakub@redhat.com>
PR other/79046

View File

@ -2,11 +2,11 @@
*
* DO NOT EDIT THIS FILE (fixincl.x)
*
* It has been AutoGen-ed January 12, 2017 at 11:46:34 AM by AutoGen 5.16.2
* It has been AutoGen-ed Saturday February 11, 2017 at 04:09:01 PM EST
* From the definitions inclhack.def
* and the template file fixincl
*/
/* DO NOT SVN-MERGE THIS FILE, EITHER Thu Jan 12 11:46:34 2017
/* DO NOT SVN-MERGE THIS FILE, EITHER Sat 11 Feb 2017 16:09:01 EST
*
* 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 246 fixup descriptions.
* This file contains 247 fixup descriptions.
*
* See README for more information.
*
@ -4340,6 +4340,46 @@ static const char* apzHpux10_Stdio_DeclarationsPatch[] = {
# endif /* __STDC__) || __cplusplus */\n",
(char*)NULL };
/* * * * * * * * * * * * * * * * * * * * * * * * * *
*
* Description of Hppa_Hpux11_Alloca fix
*/
tSCC zHppa_Hpux11_AllocaName[] =
"hppa_hpux11_alloca";
/*
* File name selection pattern
*/
tSCC zHppa_Hpux11_AllocaList[] =
"alloca.h\0";
/*
* Machine/OS name selection pattern
*/
tSCC* apzHppa_Hpux11_AllocaMachs[] = {
"hppa*-*-hpux11*",
(const char*)NULL };
/*
* content selection pattern - do fix if pattern found
*/
tSCC zHppa_Hpux11_AllocaSelect0[] =
"#ifndef _STDDEF_INCLUDED";
#define HPPA_HPUX11_ALLOCA_TEST_CT 1
static tTestDesc aHppa_Hpux11_AllocaTests[] = {
{ TT_EGREP, zHppa_Hpux11_AllocaSelect0, (regex_t*)NULL }, };
/*
* Fix Command Arguments for Hppa_Hpux11_Alloca
*/
static const char* apzHppa_Hpux11_AllocaPatch[] = {
"format",
"#ifndef _SYS_STDSYMS_INCLUDED\n\
# include <sys/stdsyms.h>\n\
#endif /* _SYS_STDSYMS_INCLUDED */\n\n\
%0",
(char*)NULL };
/* * * * * * * * * * * * * * * * * * * * * * * * * *
*
* Description of Hpux11_Abs fix
@ -10062,9 +10102,9 @@ static const char* apzX11_SprintfPatch[] = {
*
* List of all fixes
*/
#define REGEX_COUNT 283
#define REGEX_COUNT 284
#define MACH_LIST_SIZE_LIMIT 187
#define FIX_COUNT 246
#define FIX_COUNT 247
/*
* Enumerate the fixes
@ -10170,6 +10210,7 @@ typedef enum {
HPUX10_CTYPE_DECLARATIONS1_FIXIDX,
HPUX10_CTYPE_DECLARATIONS2_FIXIDX,
HPUX10_STDIO_DECLARATIONS_FIXIDX,
HPPA_HPUX11_ALLOCA_FIXIDX,
HPUX11_ABS_FIXIDX,
HPUX11_LWP_RWLOCK_VALID_FIXIDX,
HPUX11_EXTERN_SENDFILE_FIXIDX,
@ -10819,6 +10860,11 @@ tFixDesc fixDescList[ FIX_COUNT ] = {
HPUX10_STDIO_DECLARATIONS_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
aHpux10_Stdio_DeclarationsTests, apzHpux10_Stdio_DeclarationsPatch, 0 },
{ zHppa_Hpux11_AllocaName, zHppa_Hpux11_AllocaList,
apzHppa_Hpux11_AllocaMachs,
HPPA_HPUX11_ALLOCA_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
aHppa_Hpux11_AllocaTests, apzHppa_Hpux11_AllocaPatch, 0 },
{ zHpux11_AbsName, zHpux11_AbsList,
apzHpux11_AbsMachs,
HPUX11_ABS_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,

View File

@ -2274,6 +2274,24 @@ fix = {
test_text = "# define _iob __iob\n";
};
/*
* The HP-UX stddef.h is replaced by gcc's. It doesn't include sys/stdsyms.h.
* As a result, we need to include sys/stdsyms.h in alloca.h.
*/
fix = {
hackname = hppa_hpux11_alloca;
mach = "hppa*-*-hpux11*";
files = alloca.h;
select = "#ifndef _STDDEF_INCLUDED";
c_fix = format;
c_fix_arg = "#ifndef _SYS_STDSYMS_INCLUDED\n"
"# include <sys/stdsyms.h>\n"
"#endif /* _SYS_STDSYMS_INCLUDED */\n\n"
"%0";
test_text = "#ifndef _STDDEF_INCLUDED";
};
/*
* Make sure hpux defines abs in header.
*/

View File

@ -0,0 +1,18 @@
/* DO NOT EDIT THIS FILE.
It has been auto-edited by fixincludes from:
"fixinc/tests/inc/alloca.h"
This had to be done to correct non-standard usages in the
original, manufacturer supplied header file. */
#if defined( HPPA_HPUX11_ALLOCA_CHECK )
#ifndef _SYS_STDSYMS_INCLUDED
# include <sys/stdsyms.h>
#endif /* _SYS_STDSYMS_INCLUDED */
#ifndef _STDDEF_INCLUDED
#endif /* HPPA_HPUX11_ALLOCA_CHECK */