⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 inclhack.def

📁 gcc-2.95.3 Linux下最常用的C编译器
💻 DEF
📖 第 1 页 / 共 5 页
字号:
          "extern caddr_t mmap ();\\\n"          "#endif /* !defined(__STDC__) */\\\n";};#endif/* *  Add a #define of _SIGACTION_ into <sys/signal.h>. */#ifdef SVR4fix = {    hackname = svr4_sigaction;    files    = sys/signal.h;    sed      = "/^struct sigaction {/i\\\n"               "#define _SIGACTION_";    sed      = 's/(void *(\*)())/(void (*)(int))/';};#endif/* *  Put storage class at start of decl, to avoid warning. */#ifdef SVR4fix = {    hackname = svr4_storage_class;    files    = rpc/types.h;    select   = 'const extern';    sed      = 's/const extern/extern const/g';};#endif/* *  Fix return value of mem{ccpy,chr,cpy,set} and str{len,spn,cspn} *  in string.h on sysV68 *  Correct the return type for strlen in string.h on Lynx. *  Correct the argument type for ffs in string.h on Alpha OSF/1 V2.0. *  Add missing const for strdup on OSF/1 V3.0. *  On sysV88 layout is slightly different. */fix = {    hackname = systypes;    files  = "sys/types.h";    files  = "stdlib.h";    files  = "sys/stdtypes.h";    files  = "stddef.h";    files  = "memory.h";    files  = "unistd.h";    select = "typedef[ \t]+[a-z_][ \ta-z_]*[ \t]"             "(size|ptrdiff|wchar)_t";      sed  = "/^[ \t]*\\*[ \t]*typedef unsigned int size_t;/N";      sed  = "s/^\\([ \t]*\\*[ \t]*typedef unsigned int size_t;\\n"               "[ \t]*\\*\\/\\)/\\1\\\n"             "#ifndef __SIZE_TYPE__\\\n"             "#define __SIZE_TYPE__ long unsigned int\\\n"             "#endif\\\n"             "typedef __SIZE_TYPE__ size_t;\\\n/";      sed  = "/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]size_t/i\\\n"                   "#ifndef __SIZE_TYPE__\\\n"                   "#define __SIZE_TYPE__ long unsigned int\\\n"                   "#endif\n";      sed  = "s/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]size_t/"               "typedef __SIZE_TYPE__ size_t/";      sed  = "/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]ptrdiff_t/i\\\n"                   "#ifndef __PTRDIFF_TYPE__\\\n"                   "#define __PTRDIFF_TYPE__ long int\\\n"                   "#endif\n";      sed  = "s/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]ptrdiff_t/"               "typedef __PTRDIFF_TYPE__ ptrdiff_t/";      sed  = "/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]wchar_t/i\\\n"                   "#ifndef __WCHAR_TYPE__\\\n"                   "#define __WCHAR_TYPE__ int\\\n"                   "#endif\\\n"                   "#ifndef __cplusplus\n";      sed  = "/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]wchar_t/a\\\n"                   "#endif\n";      sed  = "s/typedef[ \t][ \t]*[a-z_][ \ta-z_]*[ \t]wchar_t/"               "typedef __WCHAR_TYPE__ wchar_t/";};/* *  Fix return type of exit and abort in <stdlib.h> on SunOS 4.1. *  Also wrap protection around size_t for m88k-sysv3 systems. *  We use a funny name to ensure it follows 'systypes' fix. */fix = {    hackname = systypes_for_aix;    files    = sys/types.h;    select   = "typedef[ \t][ \t]*[A-Za-z_][ \tA-Za-z_]*[ \t]size_t";    bypass   = "_GCC_SIZE_T";    sed    = "/typedef[ \t][ \t]*[A-Za-z_][ \tA-Za-z_]*[ \t]size_t/i\\\n"                 "#ifndef _GCC_SIZE_T\\\n"                 "#define _GCC_SIZE_T\n";    sed    = "/typedef[ \t][ \t]*[A-Za-z_][ \tA-Za-z_]*[ \t]size_t/a\\\n"                 "#endif\n";};/* *  if the #if says _cplusplus, not the double underscore __cplusplus *  that it should be */fix = {    hackname = sysv68_string;    files    = string.h;    sed = "s/extern[ \t]*int[ \t]*strlen();/extern unsigned int strlen();/";    sed = "s/extern[ \t]*int[ \t]*ffs[ \t]*(long);/extern int ffs(int);/";    sed = "s/strdup(char \\*s1);/strdup(const char *s1);/";    sed = "/^extern char$/N";    sed = "s/^extern char\\(\\n\t\\*memccpy(),\\)$/extern void\\1/";    sed = "/^\tstrncmp(),$/N";    sed = "s/^\\(\tstrncmp()\\),\\n\\(\tstrlen(),\\)$/\\1;\\\n"          "extern unsigned int\\\n\\2/";    sed = "/^extern int$/N";    sed = "s/^extern int\\(\\n\tstrlen(),\\)/extern size_t\\1/";};/* *  Fix return type of exit and abort in <stdlib.h> *  Also wrap protection around size_t. */fix = {    hackname = sysz_stdlib_for_sun;    files    = stdlib.h;    sed   = "s/int\tabort/void\tabort/g";    sed   = "s/int\tfree/void\tfree/g";    sed   = "s/char[ \t]*\\*[ \t]*calloc/void \\*\tcalloc/g";    sed   = "s/char[ \t]*\\*[ \t]*malloc/void \\*\tmalloc/g";    sed   = "s/char[ \t]*\\*[ \t]*realloc/void \\*\trealloc/g";    sed   = "s/char[ \t]*\\*[ \t]*bsearch/void \\*\tbsearch/g";    sed   = "s/int[ \t][ \t]*exit/void\texit/g";    sed   = "/typedef[ \ta-zA-Z_]*[ \t]size_t[ \t]*;/i\\\n"                "#ifndef _GCC_SIZE_T\\\n"                "#define _GCC_SIZE_T\n";    sed   = "/typedef[ \ta-zA-Z_]*[ \t]size_t[ \t]*;/a\\\n"                "#endif\n";};/* *  Fix this Sun file to avoid interfering with stddef.h. *  We use a funny name to ensure it follows 'systypes' fix. */fix = {    hackname = sysz_stdtypes_for_sun;    files = sys/stdtypes.h;    sed   = "/[\t ]size_t.*;/i\\\n"              "#ifndef _GCC_SIZE_T\\\n"              "#define _GCC_SIZE_T\n";    sed   = "/[\t ]size_t.*;/a\\\n"              "#endif\n";    sed   = "/[\t ]ptrdiff_t.*;/i\\\n"              "#ifndef _GCC_PTRDIFF_T\\\n"              "#define _GCC_PTRDIFF_T\n";    sed   = "/[\t ]ptrdiff_t.*;/a\\\n"              "#endif\n";    sed   = "/[\t ]wchar_t.*;/i\\\n"              "#ifndef _GCC_WCHAR_T\\\n"              "#define _GCC_WCHAR_T\n";    sed   = "/[\t ]wchar_t.*;/a\\\n"              "#endif\n";};/* *  Fix this file to avoid interfering with stddef.h, *  but don't mistakenly match ssize_t present in AIX for the ps/2, *  or typedefs which use (but do not set) size_t. */fix = {    hackname = tinfo_cplusplus;    files    = tinfo.h;    sed      = "s/[ \t]_cplusplus/ __cplusplus/";};/* *  Cancel out ansi_compat.h on Ultrix.  Replace it with empty file. */fix = {    hackname = ultrix_ansi_compat;    files    = ansi_compat.h;    select   = ULTRIX;    sed      = "1i\\\n/* This file intentionally left blank. */\n";    sed      = "1,$d";};/* * Ultrix V4.[35] puts the declaration of uname before the definition * of struct utsname, so the prototype (added by fixproto) causes havoc. */fix = {    hackname = ultrix_fix_fixproto;    files    = sys/utsname.h;    select   = ULTRIX;    sed      = "/^[ \t]*extern[ \t]*int[ \t]*uname();$/i\\\n"               "struct utsname;\n";};/* *  parameter to atof not const on DECstation Ultrix V4.0 and NEWS-OS 4.2R. *  also get rid of bogus inline definitions in HP-UX 8.0 */fix = {    hackname = ultrix_atof_param;    files    = math.h;    sed = "s@atof(\\([ \t]*char[ \t]*\\*[^)]*\\))@atof(const \\1)@";    sed = "s@inline int abs(int [a-z][a-z]*) {.*}@extern \"C\" int abs(int);@";    sed = "s@inline double abs(double [a-z][a-z]*) {.*}@@";    sed = "s@inline int sqr(int [a-z][a-z]*) {.*}@@";    sed = "s@inline double sqr(double [a-z][a-z]*) {.*}@@";};/* *  parameters not const on DECstation Ultrix V4.0 and OSF/1. */fix = {    hackname = ultrix_const;    files    = stdio.h;    sed   = 's@perror( char \*__s );@perror( const char *__s );@';    sed   = 's@fputs( char \*__s,@fputs( const char *__s,@';    sed   = 's@fopen( char \*__filename, char \*__type );@'              'fopen( const char *__filename, const char *__type );@';    sed   = 's@fwrite( void \*__ptr,@fwrite( const void *__ptr,@';    sed   = 's@fscanf( FILE \*__stream, char \*__format,@'              'fscanf( FILE *__stream, const char *__format,@';    sed   = 's@scanf( char \*__format,@scanf( const char *__format,@';    sed   = 's@sscanf( char \*__s, char \*__format,@'              'sscanf( const char *__s, const char *__format,@';    sed   = 's@popen(char \*, char \*);@popen(const char *, const char *);@';    sed   = 's@tempnam(char\*,char\*);@tempnam(const char*,const char*);@';};/* *  Check for bad #ifdef line (in Ultrix 4.1) */fix = {    hackname = ultrix_ifdef;    select   = "#ifdef KERNEL";    files    = sys/file.h;    sed      = "s/#ifdef KERNEL/#if defined(KERNEL)/";};/* *  Avoid nested comments on Ultrix 4.3. */fix = {    hackname = ultrix_nested_cmnt;    files    = rpc/svc.h;    sed      = "s@^\\( \\*\tint protocol;  \\)/\\*@\\1*/ /*@";};/* *  Check for superfluous `static' (in Ultrix 4.2) *  On Ultrix 4.3, includes of other files (r3_cpu.h,r4_cpu.h) is broken. */fix = {    hackname = ultrix_static;    files  = machine/cpu.h;    select = '#include "r[34]_cpu';    sed    = "s/^static struct tlb_pid_state/struct tlb_pid_state/";    sed    = 's/^#include "r3_cpu\.h"$/#include <machine\/r3_cpu\.h>/';    sed    = 's/^#include "r4_cpu\.h"$/#include <machine\/r4_cpu\.h>/';};/* *  Fix multiple defines for NULL */fix = {    hackname = undefine_null;    select = "^#[ \t]*define[ \t]*[ \t]NULL[ \t]";    bypass = "#[ \t]*(ifn|un)def[ \t]*[ \t]NULL($|[ \t])";    sed    = "/^#[ \t]*define[ \t][ \t]*NULL[ \t]/i\\\n"                "#undef NULL\n";};/* *  Fix definitions of macros used by va-i960.h in VxWorks header file. */fix = {    hackname = va_i960_macro;    files    = arch/i960/archI960.h;    select   = "__(vsiz|vali|vpad|alignof__)";    sed = "s/__vsiz/__vxvsiz/";    sed = "s/__vali/__vxvali/";    sed = "s/__vpad/__vxvpad/";    sed = "s/__alignof__/__vxalignof__/";};/* *  AIX headers define NULL to be cast to a void pointer, *  which is illegal in ANSI C++. */fix = {    hackname = void_null;    files    = curses.h;    files    = dbm.h;    files    = locale.h;    files    = stdio.h;    files    = stdlib.h;    files    = string.h;    files    = time.h;    files    = unistd.h;    files    = sys/dir.h;    files    = sys/param.h;    files    = sys/types.h;    select   = "#[ \t]*define[ \t][ \t]*NULL[ \t].*void";    sed      = "s/^#[ \t]*define[ \t]*NULL[ \t]*((void[ \t]*\\*)0)"                "/#define NULL 0/";};/* *  Make VxWorks header which is almost gcc ready fully gcc ready. */fix = {    hackname = vxworks_gcc_problem;    files    = types/vxTypesBase.h;    select   = "__GNUC_TYPEOF_FEATURE_BROKEN_USE_DEFAULT_UNTIL_FIXED__";    sed = "s/#ifdef __GNUC_TYPEOF_FEATURE_BROKEN_USE_DEFAULT_UNTIL_FIXED__/"          "#if 1/";    sed = "/[ \t]size_t/i\\\n"        "#ifndef _GCC_SIZE_T\\\n"        "#define _GCC_SIZE_T\n";    sed = "/[ \t]size_t/a\\\n"        "#endif\n";    sed = "/[ \t]ptrdiff_t/i\\\n"        "#ifndef _GCC_PTRDIFF_T\\\n"        "#define _GCC_PTRDIFF_T\n";    sed = "/[ \t]ptrdiff_t/a\\\n"        "#endif\n";    sed = "/[ \t]wchar_t/i\\\n"        "#ifndef _GCC_WCHAR_T\\\n"        "#define _GCC_WCHAR_T\n";    sed = "/[ \t]wchar_t/a\\\n"        "#endif\n";};/* *  Fix VxWorks <time.h> to not require including <vxTypes.h>. */fix = {    hackname = vxworks_needs_vxtypes;    files    = time.h;    select   = "uint_t[ \t][ \t]*_clocks_per_sec";    sed      = "s/uint_t/unsigned int/";};/* *  Fix VxWorks <sys/stat.h> to not require including <vxWorks.h>. */fix = {    hackname = vxworks_needs_vxworks;    files    = sys/stat.h;    test     = " -r types/vxTypesOld.h";    test     = " -n \"`egrep '#include' $file`\"";    test     = " -n \"`egrep ULONG $file`\"";    select   = "#[ \t]define[ \t][ \t]*__INCstath";    sed = "/#[ \t]define[ \t][ \t]*__INCstath/a\\\n"          "#include <types/vxTypesOld.h>\n";};/* *  Another bad dependency in VxWorks 5.2 <time.h>. */fix = {    hackname = vxworks_time;    files    = time.h;    select   = "VOIDFUNCPTR";    test     = " -r vxWorks.h";    sed      = "/VOIDFUNCPTR/i\\\n"               "#ifndef __gcc_VOIDFUNCPTR_defined\\\n"               "#ifdef __cplusplus\\\n"               "typedef void (*__gcc_VOIDFUNCPTR) (...);\\\n"               "#else\\\n"               "typedef void (*__gcc_VOIDFUNCPTR) ();\\\n"               "#endif\\\n"               "#define __gcc_VOIDFUNCPTR_defined\\\n"               "#endif\n";    sed      = "s/VOIDFUNCPTR/__gcc_VOIDFUNCPTR/g";};/* *  There are several name conflicts with C++ reserved words in X11 header *  files.  These are fixed in some versions, so don't do the fixes if *  we find __cplusplus in the file.  These were found on the RS/6000. */fix = {    hackname = x11_class;    files    = X11/ShellP.h;    bypass   = __cplusplus;    sed      = "/char \\*class;/i\\\n"                   "#ifdef __cplusplus\\\n"                   "\tchar *c_class;\\\n"                   "#else\n";    sed      = "/char \\*class;/a\\\n"                   "#endif\n";};/* *  class in Xm/BaseClassI.h */fix = {    hackname = x11_class_usage;    files    = Xm/BaseClassI.h;    bypass   = "__cplusplus";    sed      = "s/ class[)]/ c_class)/g";};/* *  new in Xm/Traversal.h */fix = {    hackname = x11_new;    files    = Xm/Traversal.h;    bypass   = __cplusplus;    sed      = "/Widget\told, new;/i\\\n"                   "#ifdef 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -