freebsd64.h revision 123561
174462Salfred/* Definitions for AMD x86-64 running FreeBSD with ELF format
274462Salfred   Copyright (C) 2002 Free Software Foundation, Inc.
31901Swollman   Contributed by David O'Brien <obrien@FreeBSD.org>
41901Swollman
51901SwollmanThis file is part of GNU CC.
61901Swollman
71901SwollmanGNU CC is free software; you can redistribute it and/or modify
81901Swollmanit under the terms of the GNU General Public License as published by
91901Swollmanthe Free Software Foundation; either version 2, or (at your option)
108870Srgrimesany later version.
111901Swollman
121901SwollmanGNU CC is distributed in the hope that it will be useful,
131901Swollmanbut WITHOUT ANY WARRANTY; without even the implied warranty of
148870SrgrimesMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
151901SwollmanGNU General Public License for more details.
161901Swollman
171901SwollmanYou should have received a copy of the GNU General Public License
181901Swollmanalong with GNU CC; see the file COPYING.  If not, write to
191901Swollmanthe Free Software Foundation, 59 Temple Place - Suite 330,
201901SwollmanBoston, MA 02111-1307, USA.  */
211901Swollman
228870Srgrimes/* $FreeBSD: head/contrib/gcc/config/i386/freebsd64.h 123561 2003-12-16 05:40:06Z obrien $ */
231901Swollman
241901Swollman
251901Swollman#undef  TARGET_VERSION
268870Srgrimes#define TARGET_VERSION fprintf (stderr, " (FreeBSD/x86-64 ELF)");
271901Swollman
281901Swollman#undef  FBSD_TARGET_CPU_CPP_BUILTINS
291901Swollman#define FBSD_TARGET_CPU_CPP_BUILTINS()		\
301901Swollman  do						\
311901Swollman    {						\
321901Swollman      if (TARGET_64BIT)				\
3374462Salfred	{					\
3474462Salfred	  builtin_define ("__LP64__");		\
351901Swollman	}					\
3692990Sobrien    }						\
3792990Sobrien  while (0)
381901Swollman
391901Swollman/* Provide a LINK_SPEC appropriate for the FreeBSD/x86-64 ELF target.
401901Swollman   This is a copy of LINK_SPEC from <i386/freebsd.h> tweaked for
411901Swollman   the x86-64 target.  */
421901Swollman
431901Swollman#undef	LINK_SPEC
441901Swollman#define LINK_SPEC "\
451901Swollman  %{m32:-m elf_i386_fbsd -Y P,/usr/lib/i386} \
461901Swollman  %{Wl,*:%*} \
4785138Salfred  %{v:-V} \
481901Swollman  %{assert*} %{R*} %{rpath*} %{defsym*} \
491901Swollman  %{shared:-Bshareable %{h*} %{soname*}} \
5075094Siedowse    %{!shared: \
5174462Salfred      %{!static: \
5274462Salfred        %{rdynamic:-export-dynamic} \
5374462Salfred	%{!dynamic-linker:-dynamic-linker /libexec/ld-elf.so.1}} \
5474462Salfred    %{static:-Bstatic}} \
5511666Sphk  %{symbolic:-Bsymbolic}"
561901Swollman