b1f622bc6b40b003fd18cff26ed4591c394dee02
[dragonfly.git] / gnu / usr.bin / cc44 / Makefile.inc
1 .if !target(__<cc.Makefile.inc>__)
2 __<cc.Makefile.inc>__:
3
4 GCCCOMPLETEVER= 4.4.7
5 GCCDATESTAMP=   2012.03.13
6 GCCPOINTVER=    ${GCCCOMPLETEVER:R}
7 GCCSHORTVER=    ${GCCPOINTVER:S/.//}
8
9 GCCDOCSUFFIX=   ${GCCSHORTVER}
10
11 CSTD?=          gnu89
12
13 CFLAGS+=        -DGCCPOINTVER=\"${GCCPOINTVER}\"
14 CFLAGS+=        -DGCCSHORTVER=\"${GCCSHORTVER}\"
15 CFLAGS+=        -DBASEVER=\"${GCCCOMPLETEVER}\"
16
17 CFLAGS+=        -DDEFAULT_TARGET_VERSION=\"${version}\"
18 CFLAGS+=        -DDEFAULT_TARGET_MACHINE=\"${target_machine}\"
19
20 BINDIR?=        /usr/libexec/gcc${GCCSHORTVER}
21 .include "../Makefile.inc"
22
23 GCCDIR=         ${.CURDIR}/${TOP_PREFIX}/../../../../contrib/gcc-${GCCPOINTVER}
24 OTOPDIR=        ${.OBJDIR}/${TOP_PREFIX}/..
25 STOPDIR=        ${.CURDIR}/${TOP_PREFIX}/..
26
27 TOOLDIR=        ${OTOPDIR}/cc_tools/tools
28
29 CFLAGS+=        -I${OTOPDIR}/cc_prep -I${STOPDIR}/cc_prep -I${STOPDIR}/cc_prep/config
30 CFLAGS+=        -I${GCCDIR}/gcc -I${GCCDIR}/gcc/config -I${GCCDIR}/include
31 CFLAGS+=        -I${GCCDIR}/libcpp/include
32 CFLAGS+=        -I${GCCDIR}/libdecnumber -I${GCCDIR}/libdecnumber/dpd
33 CFLAGS+=        -I${OTOPDIR}/libdecnumber
34 CFLAGS+=        -I${STOPDIR}/../gmp
35 CFLAGS+=        -I${.CURDIR}/${TOP_PREFIX}/../../../../contrib/mpfr/src
36 CFLAGS+=        -I${STOPDIR}/../mpfr
37 CFLAGS+=        -I${GCCDIR}/gcc/config/${GCC_CPU} -I${TOOLDIR}
38
39 CFLAGS+=        -DIN_GCC -DHAVE_CONFIG_H
40 CFLAGS+=        -DPREFIX=\"${TOOLS_PREFIX}/usr\"
41 CFLAGS+=        -DPREFIX2=\"${USRDATA_PREFIX}/usr\"
42
43 .include "Makefile.tgt"
44
45 .if ${TARGET_ARCH} != ${MACHINE_ARCH}
46 CFLAGS+=        -DCROSS_COMPILE
47 .endif
48
49 .if defined(GCC_LANG_DIR)
50 .PATH:  ${GCCDIR}/${GCC_LANG_DIR}
51 .endif
52
53 .if !defined(GCC_NO_PATH)
54 .PATH:  ${OTOPDIR}/cc_prep ${STOPDIR}/cc_prep ${GCCDIR}/gcc
55 .PATH:  ${GCCDIR}/gcc/config/${GCC_CPU} ${TOOLDIR}
56 .endif
57
58 LIBIBERTY=      ${OTOPDIR}/libiberty/libiberty.a
59 LIBBACKEND=     ${OTOPDIR}/libbackend/libbackend.a
60 LIBCPP=         ${OTOPDIR}/libcpp/libcpp.a
61 LIBDECNUMBER=   ${OTOPDIR}/libdecnumber/libdecnumber.a
62
63 LIBGMP=         ${OTOPDIR}/../gmp/libgmp.a
64 LIBMPFR=        ${OTOPDIR}/../mpfr/libmpfr.a
65
66 GMPLIBS=        ${LIBMPFR} ${LIBGMP}
67 STDLIBS=        ${LIBCPP} ${LIBIBERTY} ${LIBDECNUMBER} 
68 BACKENDLIBS=    ${GMPLIBS}
69
70 .if !defined(GCC_NO_LIBS)
71 LDADD+= ${STDLIBS}
72 DPADD+= ${STDLIBS}
73 .endif
74
75 .endif