[BACK]Return to Makefile.inc CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / external / bsd / pcc

File: [cvs.NetBSD.org] / src / external / bsd / pcc / Makefile.inc (download)

Revision 1.17, Mon Mar 26 14:31:12 2012 UTC (2 years, 8 months ago) by plunky
Branch: MAIN
CVS Tags: yamt-pagecache-base9, yamt-pagecache-base8, yamt-pagecache-base7, yamt-pagecache-base6, yamt-pagecache-base5, yamt-pagecache-base4, riastradh-xf86-video-intel-2-7-1-pre-2-21-15, riastradh-drm2-base3, riastradh-drm2-base2, riastradh-drm2-base1, riastradh-drm2-base, riastradh-drm2, khorben-n900, agc-symver-base, agc-symver
Branch point for: tls-maxphys, tls-earlyentropy
Changes since 1.16: +2 -2 lines

update for pcc-20120325

#	$NetBSD: Makefile.inc,v 1.17 2012/03/26 14:31:12 plunky Exp $

PCC_DIR:=${.PARSEDIR}
PCC_DIST=${PCC_DIR}/dist/pcc
PCC_LIBS=${PCC_DIR}/dist/pcc-libs

# (these strings will be updated by the prepare-import.sh script)
PCC_VERSION=1.1.0.DEVEL
PCC_DATESTAMP=20120325

TARGOS = netbsd

.if ${MACHINE_ARCH} == "mipsel" || ${MACHINE_ARCH} == "mipseb"
TARGMACH = mips
.elif ${MACHINE_ARCH} == "x86_64"
TARGMACH = amd64
.else
TARGMACH = ${MACHINE_ARCH}
.endif

.if !exists(${PCC_DIST}/arch/${TARGMACH})
ERROR!= echo "ERROR: ${TARGMACH} not yet supported - write code!" >&2;echo
.endif

VERSSTR="pcc ${PCC_VERSION} ${PCC_DATESTAMP} for ${TARGOS}-${TARGMACH}"

CPPFLAGS+=	-DGCC_COMPAT
CPPFLAGS+=	-DPCC_DEBUG
CPPFLAGS+=	-DVERSSTR=${VERSSTR:Q}
CPPFLAGS+=	-Dos_${TARGOS}
CPPFLAGS+=	-Dmach_${TARGMACH}
CPPFLAGS+=	-I${PCC_DIR}/include

.include <bsd.endian.mk>

# We only build binaries from here where the pcc host and target architectures
# will be the same. For a cross-compiler, use the tools/pcc build.
#
.if ${TARGET_ENDIANNESS} == "1234"
CPPFLAGS+=	-DHOST_LITTLE_ENDIAN
CPPFLAGS+=	-DTARGET_LITTLE_ENDIAN
.elif ${TARGET_ENDIANNESS} == "4321"
CPPFLAGS+=	-DHOST_BIG_ENDIAN
CPPFLAGS+=	-DTARGET_BIG_ENDIAN
.else
ERROR!= echo "ERROR: Unknown TARGET_ENDIANNESS" >&2;echo
.endif

# top-level Makefile.inc
.include "../../../Makefile.inc"