]> CyberLeo.Net >> Repos - FreeBSD/releng/8.1.git/blob - gnu/usr.bin/cc/Makefile.inc
Copy stable/8 to releng/8.1 in preparation for 8.1-RC1.
[FreeBSD/releng/8.1.git] / gnu / usr.bin / cc / Makefile.inc
1 # $FreeBSD$
2
3 .include "../Makefile.inc"
4
5 # Sometimes this is .include'd several times...
6 .if !defined(__CC_MAKEFILE_INC__)
7 __CC_MAKEFILE_INC__= ${MFILE}
8
9 GCCDIR= ${.CURDIR}/../../../../contrib/gcc
10 GCCLIB= ${.CURDIR}/../../../../contrib/gcclibs
11
12 .include "Makefile.tgt"
13
14 # Machine description.
15 MD_FILE=        ${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}.md
16 GCC_TARGET=     ${TARGET_ARCH}-undermydesk-freebsd
17
18 CFLAGS+=        -DIN_GCC -DHAVE_CONFIG_H
19 CFLAGS+=        -DPREFIX=\"${TOOLS_PREFIX}/usr\"
20 #CFLAGS+=       -DWANT_COMPILER_INVARIANTS
21 CSTD?=  gnu89
22
23 # If building 64-bit longs for the i386, "_LARGE_LONG" should also be defined
24 # to get the proper sizes in limits.h
25 .if defined(LONG_TYPE_SIZE)
26 CFLAGS+=        -DLONG_TYPE_SIZE=${LONG_TYPE_SIZE}
27 .endif
28
29 .if ${TARGET_ARCH} != ${MACHINE_ARCH}
30 CFLAGS+=        -DCROSS_COMPILE
31 .endif
32
33 .if defined(WANT_FORCE_OPTIMIZATION_DOWNGRADE)
34 CFLAGS+= -DFORCE_OPTIMIZATION_DOWNGRADE=${WANT_FORCE_OPTIMIZATION_DOWNGRADE}
35 .endif
36
37 .if exists(${.OBJDIR}/../cc_tools)
38 CFLAGS+=        -I${.OBJDIR}/../cc_tools
39 .endif
40 CFLAGS+=        -I${.CURDIR}/../cc_tools
41 # This must go after the -I for cc_tools to resolve ambiguities for hash.h
42 # correctly.
43 CFLAGS+=        -I${GCCDIR} -I${GCCDIR}/config
44
45 CFLAGS+=        -I${GCCLIB}/include
46 CFLAGS+=        -I${GCCLIB}/libcpp/include
47 CFLAGS+=        -I${GCCLIB}/libdecnumber
48
49 .if exists(${.OBJDIR}/../cc_int)
50 LIBBACKEND=     ${.OBJDIR}/../cc_int/libbackend.a
51 .else
52 LIBBACKEND=     ${.CURDIR}/../cc_int/libbackend.a
53 .endif
54
55 .if exists(${.OBJDIR}/../libiberty)
56 LIBIBERTY=      ${.OBJDIR}/../libiberty/libiberty.a
57 .else
58 LIBIBERTY=      ${.CURDIR}/../libiberty/libiberty.a
59 .endif
60
61 .if exists(${.OBJDIR}/../libcpp)
62 LIBCPP=         ${.OBJDIR}/../libcpp/libcpp.a
63 .else
64 LIBCPP=         ${.CURDIR}/../libcpp/libcpp.a
65 .endif
66
67 .if exists(${.OBJDIR}/../libdecnumber)
68 LIBDECNUMBER=   ${.OBJDIR}/../libdecnumber/libdecnumber.a
69 .else
70 LIBDECNUMBER=   ${.CURDIR}/../libdecnumber/libdecnumber.a
71 .endif
72
73 .endif # !__CC_MAKEFILE_INC__