diff options
author | peter <peter@FreeBSD.org> | 2003-06-26 03:51:57 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2003-06-26 03:51:57 +0000 |
commit | 289e79b907dd648e5c22a0678baf44a585511b35 (patch) | |
tree | 096ff24ee5a884c1dabbe49274b851335a0ef193 /sys/boot/ficl | |
parent | 5d98ddee251e0ad9fcfe740b27b439d8c124e36b (diff) | |
download | FreeBSD-src-289e79b907dd648e5c22a0678baf44a585511b35.zip FreeBSD-src-289e79b907dd648e5c22a0678baf44a585511b35.tar.gz |
Build on amd64. Yes, I know this isn't particularly nice.
Diffstat (limited to 'sys/boot/ficl')
-rw-r--r-- | sys/boot/ficl/Makefile | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/sys/boot/ficl/Makefile b/sys/boot/ficl/Makefile index 6302da6..d3b8924 100644 --- a/sys/boot/ficl/Makefile +++ b/sys/boot/ficl/Makefile @@ -1,5 +1,9 @@ # $FreeBSD$ # +.if ${MACHINE_ARCH} == "amd64" +.MAKEFLAGS: MACHINE_ARCH=i386 MACHINE=i386 REALLY_AMD64=true +.endif + .PATH: ${.CURDIR}/${MACHINE_ARCH} BASE_SRCS= dict.c ficl.c fileaccess.c float.c loader.c math64.c \ prefix.c search.c stack.c tools.c vm.c words.c @@ -37,8 +41,24 @@ SOFTWORDS= softcore.fr jhlocal.fr marker.fr freebsd.fr ficllocal.fr \ # Optional OO extension softwords #SOFTWORDS+= oo.fr classes.fr +.if defined(REALLY_AMD64) +CFLAGS+= -m32 -I. +LDFLAGS= -m elf_i386_fbsd +.endif + CFLAGS+= -I${.CURDIR} -I${.CURDIR}/${MACHINE_ARCH} -I${.CURDIR}/../common softcore.c: ${SOFTWORDS} softcore.awk (cd ${.CURDIR}/softwords; cat ${SOFTWORDS} \ | awk -f softcore.awk -v datestamp="`LC_ALL=C date`") > ${.TARGET} + +.if defined(REALLY_AMD64) +${SRCS:M*.c:R:S/$/.o/g}: machine + +beforedepend ${OBJS}: machine + +machine: + ln -sf ${.CURDIR}/../../i386/include machine + +CLEANFILES+= machine +.endif |