Makefile.inc0 revision 130575
121308Sache# $FreeBSD: head/gnu/usr.bin/binutils/Makefile.inc0 130575 2004-06-16 07:09:44Z obrien $
221308Sache#
321308Sache# This is included explicitly at the top of each sub-Makefile.  We can't
421308Sache# use the normal "Makefile.inc" mechanism, because we need some of these
521308Sache# definitions before the sub-Makefile is processed.
621308Sache
721308SacheVERSION=	"2.15 [FreeBSD] 2004-05-23"
821308Sache
921308SacheTARGET_ARCH?=	${MACHINE_ARCH}
1021308Sache.if ${TARGET_ARCH} == "amd64"
1158310SacheBINUTILS_ARCH=x86_64
1221308Sache.else
1321308SacheBINUTILS_ARCH=${TARGET_ARCH}
1421308Sache.endif
1521308SacheTARGET_TUPLE?=	${BINUTILS_ARCH}-obrien-freebsd
1621308Sache
1721308Sache# RELTOP is the relative path to this point in the source or object
1821308Sache# tree, from any subdirectory of same.  It gets extra "../" prefixes
1921308Sache# added to it as we descend into subdirectories.
2021308SacheRELTOP:= ..
2121308Sache
2258310SacheRELSRC=	${RELTOP}/../../../contrib/binutils
2321308SacheSRCDIR=	${.CURDIR}/${RELSRC}
2421308Sache
2521308SacheCFLAGS+= -I.
2621308Sache.if exists(${.CURDIR}/${TARGET_ARCH})
2721308SacheCFLAGS+= -I${.CURDIR}/${TARGET_ARCH}
2821308Sache.endif
2921308SacheCFLAGS+= -I${.CURDIR}
3021308SacheCFLAGS+= -I${.CURDIR}/${RELTOP}/libbfd/${TARGET_ARCH}
3121308SacheCFLAGS+= -I${.OBJDIR}/${RELTOP}/libbfd
3221308SacheCFLAGS+= -I${SRCDIR}/include
3321308Sache
3421308Sache.if exists(${.CURDIR}/${TARGET_ARCH})
3521308Sache.PATH: ${.CURDIR}/${TARGET_ARCH}
3621308Sache.endif
3721308Sache
3821308SacheARCHS=	${TARGET_ARCH}
3921308Sache
4021308Sache.for _arch in ${CROSS_ARCH}
4121308Sache.if (${ARCHS:R:M${_arch:R}} == "")
4221308SacheARCHS+= $(_arch)
4321308Sache.endif
4421308Sache.endfor
4521308Sache
4621308Sache.for _arch in ${ARCHS}
4721308Sache.if exists(${.CURDIR}/Makefile.${_arch})
4821308Sache.include "${.CURDIR}/Makefile.${_arch}"
4921308Sache.endif
5058310Sache.endfor
5158310Sache