Makefile.inc0 revision 166638
150472Speter# $FreeBSD: head/gnu/usr.bin/binutils/Makefile.inc0 166638 2007-02-11 07:15:06Z marcel $ 233975Sjdp# 333975Sjdp# This is included explicitly at the top of each sub-Makefile. We can't 433975Sjdp# use the normal "Makefile.inc" mechanism, because we need some of these 533975Sjdp# definitions before the sub-Makefile is processed. 633975Sjdp 7130575SobrienVERSION= "2.15 [FreeBSD] 2004-05-23" 884947Sobrien 954748SmarcelTARGET_ARCH?= ${MACHINE_ARCH} 10130575Sobrien.if ${TARGET_ARCH} == "amd64" 11130575SobrienBINUTILS_ARCH=x86_64 12130575Sobrien.else 13130575SobrienBINUTILS_ARCH=${TARGET_ARCH} 14130575Sobrien.endif 15130575SobrienTARGET_TUPLE?= ${BINUTILS_ARCH}-obrien-freebsd 1644360Simp 1733975Sjdp# RELTOP is the relative path to this point in the source or object 1833975Sjdp# tree, from any subdirectory of same. It gets extra "../" prefixes 1933975Sjdp# added to it as we descend into subdirectories. 2084902SobrienRELTOP:= .. 2133975Sjdp 2284902SobrienRELSRC= ${RELTOP}/../../../contrib/binutils 2384902SobrienSRCDIR= ${.CURDIR}/${RELSRC} 2433975Sjdp 25166638Smarcel.if ${TARGET_ARCH} == "arm" || ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "powerpc" 26166638SmarcelCFLAGS+= -DBFD_DEFAULT_TARGET_SIZE=32 27166638Smarcel.else 28166638SmarcelCFLAGS+= -DBFD_DEFAULT_TARGET_SIZE=64 29166638Smarcel.endif 30166638Smarcel 3190353SobrienCFLAGS+= -I. 32103780Sobrien.if exists(${.CURDIR}/${TARGET_ARCH}) 33103780SobrienCFLAGS+= -I${.CURDIR}/${TARGET_ARCH} 3434495Sjdp.endif 3584902SobrienCFLAGS+= -I${.CURDIR} 36131832SobrienCFLAGS+= -I${.CURDIR}/${RELTOP}/libbfd 37130575SobrienCFLAGS+= -I${.OBJDIR}/${RELTOP}/libbfd 3884902SobrienCFLAGS+= -I${SRCDIR}/include 3934495Sjdp 40103780Sobrien.if exists(${.CURDIR}/${TARGET_ARCH}) 41103780Sobrien.PATH: ${.CURDIR}/${TARGET_ARCH} 4234495Sjdp.endif 4334495Sjdp 44103780SobrienARCHS= ${TARGET_ARCH} 4535709Sjb 4652927Sjb.for _arch in ${CROSS_ARCH} 4752927Sjb.if (${ARCHS:R:M${_arch:R}} == "") 4884902SobrienARCHS+= $(_arch) 4952927Sjb.endif 5052927Sjb.endfor 5152927Sjb 5235709Sjb.for _arch in ${ARCHS} 5335709Sjb.if exists(${.CURDIR}/Makefile.${_arch}) 5435709Sjb.include "${.CURDIR}/Makefile.${_arch}" 5534495Sjdp.endif 5635709Sjb.endfor 57