2ce70215a8
Not very many overall changes. Main ones include 1. Support for powerpc, arm32 and vax 2. Makefile.gcc can now be included by anything which depends on gcc versions. If the version installed isn't 2.95.3 it'll add itself as a BUILD_DEPENDS. (XXX: any of the makefile's in pkgsrc should be checked and change to use this) 3. Remove special PLIST.NetBSD-sparc as it's no longer needed 4. Change post-extract loop to pick up any arch files from FILESDIR without having to hardcode all the archs 5. Remove arch restrictions as this should work on any arch supported by the main source tree as of 03/28/02 6. Add PKGREVISION as this clearly isn't stock 2.95.3 (it doesn't change gcc --version so version checks won't care).
73 lines
2.2 KiB
C
73 lines
2.2 KiB
C
/* Start with SVR4 defaults. */
|
|
#include <rs6000/sysv4.h>
|
|
|
|
/* Get generic NetBSD definitions. */
|
|
|
|
#define NETBSD_ELF
|
|
#include <netbsd.h>
|
|
|
|
#undef SDB_DEBUGGING_INFO
|
|
#define SDB_DEBUGGING_INFO
|
|
#undef DBX_DEBUGGING_INFO
|
|
#define DBX_DEBUGGING_INFO
|
|
|
|
#undef PREFERRED_DEBUGGING_TYPE
|
|
#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
|
|
|
|
/* Names to predefine in the preprocessor for this target machine. */
|
|
#undef CPP_PREDEFINES
|
|
#define CPP_PREDEFINES "\
|
|
-D__powerpc__ -D__NetBSD__ -D__ELF__ \
|
|
-Asystem(unix) -Asystem(NetBSD) -Acpu(powerpc) -Amachine(powerpc)"
|
|
|
|
/* Make gcc agree with <machine/ansi.h> */
|
|
|
|
#undef WCHAR_TYPE
|
|
#define WCHAR_TYPE "int"
|
|
|
|
#undef WCHAR_TYPE_SIZE
|
|
#define WCHAR_TYPE_SIZE 32
|
|
|
|
/* Don't default to pcc-struct-return, because gcc is the only compiler, and
|
|
we want to retain compatibility with older gcc versions. */
|
|
#define DEFAULT_PCC_STRUCT_RETURN 0
|
|
|
|
/* XXX Duplicated from sysv4.h --thorpej@netbsd.org
|
|
Pass -mppc to the assembler, since that is what powerpc.h currently
|
|
implies */
|
|
#undef ASM_SPEC
|
|
#define ASM_SPEC \
|
|
"-u \
|
|
%{mcpu=601: -m601} %{!mcpu=601: -mppc} \
|
|
%{V} %{v:%{!V:-V}} %{Qy:} %{!Qn:-Qy} %{n} %{T} %{Ym,*} %{Yd,*} %{Wa,*:%*} \
|
|
%{mrelocatable} \
|
|
%{mlittle} %{mlittle-endian} %{mbig} %{mbig-endian}"
|
|
|
|
/* The `multiple' instructions may not be universally implemented.
|
|
We avoid their use here. */
|
|
#undef CC1_SPEC
|
|
#define CC1_SPEC "-mno-multiple"
|
|
|
|
/* Provide a LINK_SPEC approriate for NetBSD. */
|
|
#undef LINK_SPEC
|
|
#define LINK_SPEC " \
|
|
%{O*:-O3} %{!O*:-O1} \
|
|
%{assert*} %{R*} \
|
|
%{shared:-shared} \
|
|
%{!shared: \
|
|
-dc -dp \
|
|
%{!nostdlib:%{!r*:%{!e*:-e _start}}} \
|
|
%{!static: \
|
|
%{rdynamic:-export-dynamic} \
|
|
%{!dynamic-linker:-dynamic-linker /usr/libexec/ld.elf_so}} \
|
|
%{static:-static}}"
|
|
|
|
/* XXX Sort of a mix of ../netbsd.h and sysv4.h --thorpej@netbsd.org
|
|
Provide a CPP_SPEC appropriate for NetBSD. Currently we just deal with
|
|
the GCC option `-posix' and the calling convention definition. */
|
|
|
|
#undef CPP_SPEC
|
|
#define CPP_SPEC "\
|
|
%{posix:-D_POSIX_SOURCE} \
|
|
%{msoft-float:-D_SOFT_FLOAT} \
|
|
%{mcall-sysv: -D_CALL_SYSV} %{mcall-aix: -D_CALL_AIX} %{!mcall-sysv: %{!mcall-aix: -D_CALL_SYSV}}"
|