Makefile.inc0 revision 126658
1# $FreeBSD: head/gnu/usr.bin/binutils/Makefile.inc0 126658 2004-03-05 16:12:31Z ache $
2#
3# This is included explicitly at the top of each sub-Makefile.  We can't
4# use the normal "Makefile.inc" mechanism, because we need some of these
5# definitions before the sub-Makefile is processed.
6
7VERSION=	"2.13.2 [FreeBSD] 2002-11-27"
8VERSION_DATE=	20021127
9
10TARGET_ARCH?=	${MACHINE_ARCH}
11
12# RELTOP is the relative path to this point in the source or object
13# tree, from any subdirectory of same.  It gets extra "../" prefixes
14# added to it as we descend into subdirectories.
15RELTOP:= ..
16
17RELSRC=	${RELTOP}/../../../contrib/binutils
18SRCDIR=	${.CURDIR}/${RELSRC}
19
20CFLAGS+= -D_GNU_SOURCE
21CFLAGS+= -I.
22.if exists(${.CURDIR}/${TARGET_ARCH})
23CFLAGS+= -I${.CURDIR}/${TARGET_ARCH}
24.endif
25CFLAGS+= -I${.CURDIR}
26CFLAGS+= -I${.CURDIR}/${RELTOP}/libbfd/${TARGET_ARCH}
27CFLAGS+= -I${SRCDIR}/include
28
29.if exists(${.CURDIR}/${TARGET_ARCH})
30.PATH: ${.CURDIR}/${TARGET_ARCH}
31.endif
32
33ARCHS=	${TARGET_ARCH}
34
35.for _arch in ${CROSS_ARCH}
36.if (${ARCHS:R:M${_arch:R}} == "")
37ARCHS+= $(_arch)
38.endif
39.endfor
40
41.for _arch in ${ARCHS}
42.if exists(${.CURDIR}/Makefile.${_arch})
43.include "${.CURDIR}/Makefile.${_arch}"
44.endif
45.endfor
46