This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

[PATCH] DG/UX fixincludes


Patch to migrate DG/UX from fixinc.dgux to use fast-fixincludes.
Note that the file gcc/fixinc/fixinc.dgux can now be removed.

1999-06-10 Eric Raskin (ehr@listworks.com)

	* inclhack.def: Add DG/UX-specific fix for _int_varargs.h
	* mkfixinc.sh: Remove DG/UX-specific case

--- egcs-19990608-orig/gcc/fixinc/inclhack.def  Mon Jun  7 20:09:51 1999
+++ egcs-19990608/gcc/fixinc/inclhack.def       Wed Jun  9 16:21:04 1999
@@ -2439,4 +2439,78 @@ fix = {
 };
 
 
+/*
+ *  Completely replace <_int_varargs.h> with a file that includes gcc's
+ *  stdarg.h or varargs.h files as appropriate on DG/UX
+ */
+fix = {
+    hackname = dgux_int_varargs;
+    files    = _int_varargs.h;
+    shell    = "cat > /dev/null\n"
+               "cat << _EOF_\n"
+              "#ifndef __INT_VARARGS_H\n"
+              "#define __INT_VARARGS_H\n\n"
+
+              "/***************************************************************
*********/\n"
+              "/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/s
tdio.   */\n"
+              "/***************************************************************
*********/\n\n"
+
+              "/*\n"
+              "** This file is a DG internal header.  Never include this\n"
+              "** file directly.\n"
+              "*/\n\n"
+
+              "#ifndef ___int_features_h\n"
+              "#include <sys/_int_features.h>\n"
+              "#endif\n\n"
+
+              "#if !(defined(_VA_LIST) || defined(_VA_LIST_))\n"
+              "#define _VA_LIST\n"
+              "#define _VA_LIST_\n\n"
+
+              "#ifdef __LINT__\n\n"
+
+              "#ifdef __STDC__\n"
+              "typedef void * va_list;\n"
+              "#else\n"
+              "typedef char * va_list;\n"
+              "#endif\n\n"
+
+              "#else\n"
+              "#if _M88K_ANY\n\n"
+
+              "#if defined(__DCC__)\n\n"
+
+              "typedef struct {\n"
+              "      int     next_arg;\n"
+              "      int     *mem_ptr;\n"
+              "      int     *reg_ptr;\n"
+              "} va_list;\n\n"
+
+              "#else  /* ! defined(__DCC__) */\n\n"
+
+              "typedef struct {\n"
+              "      int  __va_arg;            /* argument number */\n"
+              "      int *__va_stk;            /* start of args passed on stack
 */\n"
+              "      int *__va_reg;            /* start of args passed in regs 
*/\n"
+              "} va_list;\n\n"
+
+              "#endif  /* ! defined(__DCC__) */\n\n"
+
+              "#elif _IX86_ANY\n\n"
+
+              "#if defined(__GNUC__) || defined(__STDC__)\n"
+              "typedef void * va_list;\n"
+              "#else\n"
+              "typedef char * va_list;\n"
+              "#endif\n\n"
+
+              "#endif  /*  _IX86_ANY */\n\n"
+
+              "#endif /* __LINT__ */\n"
+              "#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */\n"
+              "#endif  /*  #ifndef __INT_VARARGS_H  */\n"
+               "_EOF_";
+};
+
 /*EOF*/

--- egcs-19990608-orig/gcc/fixinc/mkfixinc.sh   Fri May 14 22:21:35 1999
+++ egcs-19990608/gcc/fixinc/mkfixinc.sh        Thu Jun 10 08:59:43 1999
@@ -58,11 +58,6 @@ case $machine in
                fixincludes=fixinc.ptx
                ;;
 
-       i[34567]86-dg-dgux* | \
-       m88k-dg-dgux*)
-               fixincludes=fixinc.dgux
-               ;;
-
        i[34567]86-*-sco3.2v5* | \
        i[34567]86-*-sco3.2v4*)
                fixincludes=fixinc.sco


------------------------------------------------------------------------
Eric H. Raskin                            Voice: 914-769-7100 x321
President, CSC Division                   Fax:    914-769-8070
The Listworks Corp.                       E-Mail: ehr@listworks.com
1 Campus Drive
Pleasantville, NY 10570


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]