freebsd.h revision 229715
168479Simp/* Base configuration file for all FreeBSD targets. 268479Simp Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc. 368479Simp 468479SimpThis file is part of GCC. 568479Simp 668479SimpGCC is free software; you can redistribute it and/or modify 768479Simpit under the terms of the GNU General Public License as published by 868479Simpthe Free Software Foundation; either version 2, or (at your option) 968479Simpany later version. 1068479Simp 1168479SimpGCC is distributed in the hope that it will be useful, 1268479Simpbut WITHOUT ANY WARRANTY; without even the implied warranty of 1368479SimpMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 1468479SimpGNU General Public License for more details. 1568479Simp 1668479SimpYou should have received a copy of the GNU General Public License 1768479Simpalong with GCC; see the file COPYING. If not, write to 1868479Simpthe Free Software Foundation, 51 Franklin Street, Fifth Floor, 1968479SimpBoston, MA 02110-1301, USA. */ 2068479Simp 2168479Simp/* Common FreeBSD configuration. 2268479Simp All FreeBSD architectures should include this file, which will specify 2368479Simp their commonalities. 2468479Simp Adapted from gcc/config/i386/freebsd-elf.h by 2568479Simp David O'Brien <obrien@FreeBSD.org>. 2668479Simp Further work by David O'Brien <obrien@FreeBSD.org> and 27148145Strhodes Loren J. Rittle <ljrittle@acm.org>. */ 2868479Simp 2968479Simp/* $FreeBSD: head/contrib/gcc/config/freebsd.h 229715 2012-01-06 18:37:49Z andreast $ */ 3068479Simp 3168479Simp/* In case we need to know. */ 32148145Strhodes#define USING_CONFIG_FREEBSD 1 3368479Simp 34151046Strhodes/* This defines which switch letters take arguments. On FreeBSD, most of 35151046Strhodes the normal cases (defined in gcc.c) apply, and we also have -h* and 36148220Strhodes -z* options (for the linker) (coming from SVR4). 37148145Strhodes We also have -R (alias --rpath), no -z, --soname (-h), --assert etc. */ 3868479Simp 39148145Strhodes#undef SWITCH_TAKES_ARG 40148145Strhodes#define SWITCH_TAKES_ARG(CHAR) (FBSD_SWITCH_TAKES_ARG(CHAR)) 41151046Strhodes 42151046Strhodes#undef WORD_SWITCH_TAKES_ARG 43148145Strhodes#define WORD_SWITCH_TAKES_ARG(STR) (FBSD_WORD_SWITCH_TAKES_ARG(STR)) 44148145Strhodes 45148145Strhodes#undef TARGET_OS_CPP_BUILTINS 46148145Strhodes#define TARGET_OS_CPP_BUILTINS() FBSD_TARGET_OS_CPP_BUILTINS() 4768479Simp 4868479Simp#undef CPP_SPEC 4968479Simp#define CPP_SPEC FBSD_CPP_SPEC 50147848Simp 51134783Sbrueffer#undef STARTFILE_SPEC 52134783Sbrueffer#define STARTFILE_SPEC FBSD_STARTFILE_SPEC 53134783Sbrueffer 54147848Simp#undef ENDFILE_SPEC 55134783Sbrueffer#define ENDFILE_SPEC FBSD_ENDFILE_SPEC 56134783Sbrueffer 57134783Sbrueffer#undef LIB_SPEC 58150474Simp#define LIB_SPEC FBSD_LIB_SPEC 59147848Simp 60150474Simp 61150474Simp/************************[ Target stuff ]***********************************/ 62147872Simp 63149477Simp/* All FreeBSD Architectures support the ELF object file format. */ 64147872Simp#undef OBJECT_FORMAT_ELF 65147872Simp#define OBJECT_FORMAT_ELF 1 66147872Simp#undef TARGET_ELF 67147872Simp#define TARGET_ELF 1 68147872Simp 69147872Simp/* Don't assume anything about the header files. */ 70147872Simp#undef NO_IMPLICIT_EXTERN_C 71147872Simp#define NO_IMPLICIT_EXTERN_C 1 72147872Simp 73147872Simp/* Make gcc agree with FreeBSD's standard headers (<machine/ansi.h>, etc...) */ 74147872Simp#undef SIZE_TYPE 75147872Simp#define SIZE_TYPE FBSD_SIZE_TYPE 76147872Simp#undef PTRDIFF_TYPE 77147872Simp#define PTRDIFF_TYPE FBSD_PTRDIFF_TYPE 78147872Simp 79147872Simp#undef WCHAR_TYPE 80134783Sbrueffer#define WCHAR_TYPE "int" 81147848Simp#undef WCHAR_TYPE_SIZE 82147848Simp#define WCHAR_TYPE_SIZE 32 83147848Simp#undef WINT_TYPE 84147848Simp#define WINT_TYPE "int" 85147848Simp#undef WINT_TYPE_SIZE 86149477Simp#define WINT_TYPE_SIZE 32 87149477Simp 88149477Simp#ifdef FREEBSD_NATIVE 89149477Simp#define LIBSTDCXX_PROFILE "-lstdc++_p" 90149477Simp#endif 91149477Simp#define MATH_LIBRARY_PROFILE "-lm_p" 92149477Simp 93149477Simp/* Code generation parameters. */ 94149477Simp 95149477Simp/* Writing `int' for a bitfield forces int alignment for the structure. */ 96149477Simp/* XXX: ok for Alpha?? */ 9768479Simp#undef PCC_BITFIELD_TYPE_MATTERS 9868479Simp#define PCC_BITFIELD_TYPE_MATTERS 1 9968479Simp 10068479Simp/* Use periods rather than dollar signs in special g++ assembler names. 10168479Simp This ensures the configuration knows our system correctly so we can link 10279366Sru with libraries compiled with the native cc. */ 10368479Simp#undef NO_DOLLAR_IN_LABEL 10468479Simp 10568479Simp/* Define this so we can compile MS code for use with WINE. */ 10668479Simp#define HANDLE_PRAGMA_PACK_PUSH_POP 1 10768479Simp 10868479Simp#define TARGET_POSIX_IO 10968479Simp