ia64.h (EXTRA_SPECS): Remove cpp_cpu.

* config/ia64/ia64.h (EXTRA_SPECS): Remove cpp_cpu.
	(CPP_CPU_SPEC): Remove.
	(TARGET_CPU_CPP_BUILTINS): New.
	* config/ia64/hpux.h (CPP_PREDEFINES): Remove.
	(CPP_SPEC): Remove.
	(TARGET_OS_CPP_BUILTINS): New.
	* config/ia64/linux.h (CPP_PREDEFINES): Remove.
	(TARGET_OS_CPP_BUILTINS): New.
	* config/ia64/aix.h (CPP_SPEC): Move some stuff to
	TARGET_OS_CPP_BUILTINS.
	(CPP_PREDEFINES): Remove.
	(CPLUSPLUS_CPP_SPEC): Remove.
	(TARGET_OS_CPP_BUILTINS): New.

From-SVN: r56771
This commit is contained in:
Steve Ellcey 2002-09-03 21:09:54 +00:00 committed by Steve Ellcey
parent 5e25fa2263
commit 57016b4723
5 changed files with 91 additions and 57 deletions

View File

@ -1,3 +1,19 @@
2002-09-03 Steve Ellcey <sje@cup.hp.com>
* config/ia64/ia64.h (EXTRA_SPECS): Remove cpp_cpu.
(CPP_CPU_SPEC): Remove.
(TARGET_CPU_CPP_BUILTINS): New.
* config/ia64/hpux.h (CPP_PREDEFINES): Remove.
(CPP_SPEC): Remove.
(TARGET_OS_CPP_BUILTINS): New.
* config/ia64/linux.h (CPP_PREDEFINES): Remove.
(TARGET_OS_CPP_BUILTINS): New.
* config/ia64/aix.h (CPP_SPEC): Move some stuff to
TARGET_OS_CPP_BUILTINS.
(CPP_PREDEFINES): Remove.
(CPLUSPLUS_CPP_SPEC): Remove.
(TARGET_OS_CPP_BUILTINS): New.
2002-09-03 Richard Henderson <rth@redhat.com>
* Makefile.in (USER_H): Add ginclude/float.h.

View File

@ -71,32 +71,36 @@ Boston, MA 02111-1307, USA. */
/* Define this so we can compile MS code for use with WINE. */
#define HANDLE_PRAGMA_PACK_PUSH_POP
/* Target OS builtins. */
#define TARGET_OS_CPP_BUILTINS() \
do { \
if (iso_flag) \
builtin_define("_ANSI_C_SOURCE"); \
builtin_define("_AIX"); \
builtin_define("_AIX64"); \
builtin_define("unix"); \
builtin_assert("system=unix"); \
builtin_assert("system=aix"); \
builtin_define("__64BIT__"); \
builtin_define("_LONG_LONG"); \
builtin_define("_IA64"); \
builtin_define("__int128=__size128_t"); \
if (c_language == clk_cplusplus) \
{ \
builtin_define("_XOPEN_SOURCE=500"); \
builtin_define("_XOPEN_SOURCE_EXTENDED=1"); \
builtin_define("_LARGE_FILE_API"); \
builtin_define("_ALL_SOURCE"); \
} \
} while (0)
/* A C string constant that tells the GNU CC driver program options to pass to
CPP. It can also specify how to translate options you give to GNU CC into
options for GNU CC to pass to the CPP. */
/* If -ansi, we need to define _ANSI_C_SOURCE to get the right headers. */
#undef CPP_SPEC
#define CPP_SPEC "\
%{mcpu=itanium:-D__itanium__} %{mbig-endian:-D__BIG_ENDIAN__} \
%{ansi:-D_ANSI_C_SOURCE} \
%{posix:-D_POSIX_SOURCE} \
%{cpp_cpu}"
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "\
-D_AIX -D_AIX64 -D_LONGLONG -Dunix \
-Asystem=unix -Asystem=aix \
-D__64BIT__ -D_LONG_LONG -D_IA64 -D__int128=__size128_t"
/* The GNU C++ standard library requires that these macros be defined. */
#undef CPLUSPLUS_CPP_SPEC
#define CPLUSPLUS_CPP_SPEC \
"-D_XOPEN_SOURCE=500 \
-D_XOPEN_SOURCE_EXTENDED=1 \
-D_LARGE_FILE_API \
-D_ALL_SOURCE \
%{cpp_cpu}"
%{posix:-D_POSIX_SOURCE}"
/* Define this for shared library support. */

View File

@ -25,26 +25,29 @@ Boston, MA 02111-1307, USA. */
#define TARGET_VERSION fprintf (stderr, " (IA-64) HP-UX");
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "\
-D__IA64__ -D__hpux -D__hpux__ -Dhpux -Dunix \
-D__BIG_ENDIAN__ -D_LONGLONG \
-Asystem=hpux -Asystem=posix -Asystem=unix \
-D_UINT128_T"
/* -D__fpreg=long double is needed to compensate for the lack of __fpreg
which is a primitive type in HP C but does not exist in GNU C. Same
for __float80 and __float128. These types appear in HP-UX header
files and so must have some definition. */
#undef CPP_SPEC
#define CPP_SPEC "\
%{mcpu=itanium:-D__itanium__} \
%{mlp64:-D__LP64__ -D_LP64} \
%{!ansi:%{!std=c*:%{!std=i*: -D_HPUX_SOURCE -D__STDC_EXT__}}} \
-D__fpreg=long\\ double \
-D__float80=long\\ double \
-D__float128=long\\ double"
/* Target OS builtins. */
/* -D__fpreg=long double is needed to compensate for
the lack of __fpreg which is a primative type in
HP C but does not exist in GNU C. */
#define TARGET_OS_CPP_BUILTINS() \
do { \
builtin_assert("system=hpux"); \
builtin_assert("system=posix"); \
builtin_assert("system=unix"); \
builtin_define_std("hpux"); \
builtin_define_std("unix"); \
builtin_define("__IA64__"); \
builtin_define("_LONGLONG"); \
builtin_define("_UINT128_T"); \
builtin_define("__fpreg=long double"); \
builtin_define("__float80=long double"); \
builtin_define("__float128=long double"); \
if (c_language == clk_cplusplus || !flag_iso) \
{ \
builtin_define("_HPUX_SOURCE"); \
builtin_define("__STDC_EXT__"); \
} \
} while (0)
#undef ASM_EXTRA_SPEC
#define ASM_EXTRA_SPEC "%{milp32:-milp32} %{mlp64:-mlp64}"

View File

@ -31,13 +31,26 @@ Boston, MA 02111-1307, USA. */
/* Run-time target specifications */
#define EXTRA_SPECS \
{ "cpp_cpu", CPP_CPU_SPEC }, \
{ "asm_extra", ASM_EXTRA_SPEC },
/* Target CPU builtins. */
#define TARGET_CPU_CPP_BUILTINS() \
do { \
builtin_assert("cpu=ia64"); \
builtin_assert("machine=ia64"); \
builtin_define("__ia64"); \
builtin_define("__ia64__"); \
builtin_define("__itanium__"); \
builtin_define("__ELF__"); \
if (!TARGET_ILP32) \
{ \
builtin_define("_LP64"); \
builtin_define("__LP64__"); \
} \
if (TARGET_BIG_ENDIAN) \
builtin_define("__BIG_ENDIAN__"); \
} while (0)
#define CPP_CPU_SPEC " \
-Acpu=ia64 -Amachine=ia64 -D__ia64 -D__ia64__ %{!milp32:-D_LP64 -D__LP64__} \
-D__ELF__"
#define EXTRA_SPECS \
{ "asm_extra", ASM_EXTRA_SPEC },
#define CC1_SPEC "%(cc1_cpu) "
@ -208,13 +221,6 @@ extern const char *ia64_tls_size_string;
/* Driver configuration */
/* A C string constant that tells the GNU CC driver program options to pass to
CPP. It can also specify how to translate options you give to GNU CC into
options for GNU CC to pass to the CPP. */
#define CPP_SPEC \
"%{mcpu=itanium:-D__itanium__} %{mbig-endian:-D__BIG_ENDIAN__} %(cpp_cpu)"
/* A C string constant that tells the GNU CC driver program options to pass to
`cc1'. It can also specify how to translate options you give to GNU CC into
options for GNU CC to pass to the `cc1'. */

View File

@ -9,10 +9,15 @@
#undef CC1_SPEC
#define CC1_SPEC "%{profile:-p} %{G*}"
/* ??? Maybe this should be in sysv4.h? */
#define CPP_PREDEFINES "\
-D__gnu_linux__ -D__linux -D__linux__ -D_LONGLONG \
-Dlinux -Dunix -Asystem=linux"
/* Target OS builtins. */
#define TARGET_OS_CPP_BUILTINS() \
do { \
builtin_assert("system=linux"); \
builtin_define_std("linux"); \
builtin_define_std("unix"); \
builtin_define("__gnu_linux__"); \
builtin_define("_LONGLONG"); \
} while (0)
/* Need to override linux.h STARTFILE_SPEC, since it has crtbeginT.o in. */
#undef STARTFILE_SPEC