binutils214 stage 2/4.
[dragonfly.git] / gnu / usr.bin / cc / Makefile.inc
CommitLineData
984263bc 1# $FreeBSD: src/gnu/usr.bin/cc/Makefile.inc,v 1.49.2.6 2002/11/15 18:18:38 ru Exp $
17030342 2# $DragonFly: src/gnu/usr.bin/cc/Attic/Makefile.inc,v 1.7 2004/02/02 05:43:11 dillon Exp $
984263bc 3
d998769c 4MY_CCVER=gcc2
645f509d 5MY_BINUTILS=binutils212
17030342 6BINDIR?=/usr/libexec/gcc2
984263bc
MD
7.include "../Makefile.inc"
8
9# Sometimes this is .include'd several times...
10.if !defined(__CC_MAKEFILE_INC__)
11__CC_MAKEFILE_INC__= ${MFILE}
12
13GCCDIR= ${.CURDIR}/../../../../contrib/gcc
14
15TARGET_ARCH?= ${MACHINE_ARCH}
16
17# Machine description.
18MD_FILE= ${GCCDIR}/config/${TARGET_ARCH}/${TARGET_ARCH}.md
d77e8324 19target= ${TARGET_ARCH}-unknown-dragonfly
984263bc
MD
20
21# These architectures are Cygnus's default for enabling Haifa.
22.if ${TARGET_ARCH} == "alpha"
23USE_EGCS_HAIFA= 1
24.endif
25
26version!= grep version_string ${GCCDIR}/version.c \
27 | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'
28
29CFLAGS+= -DIN_GCC -DHAVE_CONFIG_H
30CFLAGS+= -DPREFIX=\"${TOOLS_PREFIX}/usr\"
31
32# If building 64-bit longs for the i386, "_LARGE_LONG" should also be defined
33# to get the proper sizes in limits.h
34.if defined(LONG_TYPE_SIZE)
35CFLAGS+= -DLONG_TYPE_SIZE=${LONG_TYPE_SIZE}
36.endif
37
38.if defined(USE_EGCS_HAIFA)
39CFLAGS+= -DHAIFA
40.endif
41
42.if ${TARGET_ARCH} != ${MACHINE_ARCH}
43CFLAGS+= -DCROSS_COMPILE
44.endif
45
46.if defined(WANT_FORCE_OPTIMIZATION_DOWNGRADE)
47CFLAGS+= -DFORCE_OPTIMIZATION_DOWNGRADE=${WANT_FORCE_OPTIMIZATION_DOWNGRADE}
48.endif
49
50.if exists(${.OBJDIR}/../cc_tools)
51CFLAGS+= -I${.OBJDIR}/../cc_tools
52.endif
53CFLAGS+= -I${.CURDIR}/../cc_tools
54# This must go after the -I for cc_tools to resolve ambiguities for hash.h
55# correctly.
56CFLAGS+= -I${GCCDIR} -I${GCCDIR}/config
57
58.if exists(${.OBJDIR}/../cc_int)
59LIBCC_INT= ${.OBJDIR}/../cc_int/libcc_int.a
60.else
61LIBCC_INT= ${.CURDIR}/../cc_int/libcc_int.a
62.endif
63
64.endif # !__CC_MAKEFILE_INC__