summaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorNiklas Hallqvist <niklas@cvs.openbsd.org>1996-03-09 01:33:41 +0000
committerNiklas Hallqvist <niklas@cvs.openbsd.org>1996-03-09 01:33:41 +0000
commit81fdb1c9d870ea7675764665befe8112a17eaa0a (patch)
tree4176753b70939297e9c4b7a50332f4d943bf6085 /games
parent6e59b9fd41c9f93eca7367bfbec065c8eddf8444 (diff)
Rudimentary support for compilation in a cross environment
Host tools will be compiled with HOSTCC instead of CC. Note, these are not complete in *any* way\!
Diffstat (limited to 'games')
-rw-r--r--games/adventure/Makefile3
-rw-r--r--games/fortune/strfile/Makefile10
-rw-r--r--games/hack/Makefile4
-rw-r--r--games/monop/Makefile3
-rw-r--r--games/phantasia/Makefile13
5 files changed, 25 insertions, 8 deletions
diff --git a/games/adventure/Makefile b/games/adventure/Makefile
index 8c2df60cc20..db789789b10 100644
--- a/games/adventure/Makefile
+++ b/games/adventure/Makefile
@@ -1,3 +1,4 @@
+# $OpenBSD: Makefile,v 1.2 1996/03/09 01:33:25 niklas Exp $
# $NetBSD: Makefile,v 1.3 1995/03/21 12:04:53 cgd Exp $
# @(#)Makefile 8.1 (Berkeley) 6/12/93
@@ -12,6 +13,6 @@ data.c: glorkz setup
./setup ${.CURDIR}/glorkz > data.c
setup: setup.c hdr.h
- ${CC} -o setup ${.CURDIR}/setup.c
+ ${HOSTCC} -o setup ${.CURDIR}/setup.c
.include <bsd.prog.mk>
diff --git a/games/fortune/strfile/Makefile b/games/fortune/strfile/Makefile
index a8847445274..f1e40ad15ad 100644
--- a/games/fortune/strfile/Makefile
+++ b/games/fortune/strfile/Makefile
@@ -1,7 +1,15 @@
+# $OpenBSD: Makefile,v 1.2 1996/03/09 01:33:26 niklas Exp $
# $NetBSD: Makefile,v 1.5 1995/03/23 08:28:44 cgd Exp $
# @(#)Makefile 8.1 (Berkeley) 5/31/93
-PROG= strfile
+PROG=
MAN= strfile.8
+CLEANFILES+= strfile
+
+all: strfile
+
+strfile: ${.CURDIR}/strfile.c
+ ${HOSTCC} ${CFLAGS} ${.CURDIR}/strfile.c -o $@
+
.include <bsd.prog.mk>
diff --git a/games/hack/Makefile b/games/hack/Makefile
index 4fa0fc045d0..aeeaae420b3 100644
--- a/games/hack/Makefile
+++ b/games/hack/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.16 1995/03/23 08:29:07 cgd Exp $
+# $OpenBSD: Makefile,v 1.2 1996/03/09 01:33:28 niklas Exp $
# @(#)Makefile 8.1 (Berkeley) 5/31/93
PROG= hack
@@ -27,7 +27,7 @@ hack.onames.h: makedefs def.objects.h
${.OBJDIR}/makedefs ${.CURDIR}/def.objects.h > hack.onames.h
makedefs: makedefs.c
- ${CC} ${CFLAGS} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} ${.CURDIR}/${.PREFIX}.c ${LDADD}
+ ${HOSTCC} ${CFLAGS} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} ${.CURDIR}/${.PREFIX}.c ${LDADD}
beforeinstall:
install -c -o games -g games -m 600 /dev/null \
diff --git a/games/monop/Makefile b/games/monop/Makefile
index 0b692e3d6c4..711fe8884dd 100644
--- a/games/monop/Makefile
+++ b/games/monop/Makefile
@@ -1,3 +1,4 @@
+# $OpenBSD: Makefile,v 1.2 1996/03/09 01:33:29 niklas Exp $
# $NetBSD: Makefile,v 1.12 1995/03/23 08:34:32 cgd Exp $
# @(#)Makefile 8.1 (Berkeley) 5/31/93
@@ -16,7 +17,7 @@ cards.pck: initdeck
${.OBJDIR}/initdeck ${.CURDIR}/cards.inp
initdeck: initdeck.c
- ${CC} ${CFLAGS} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} ${.CURDIR}/initdeck.c ${LDADD}
+ ${HOSTCC} ${CFLAGS} ${LDFLAGS} ${LDSTATIC} -o ${.TARGET} ${.CURDIR}/initdeck.c ${LDADD}
beforeinstall:
install -c -o ${BINOWN} -g ${BINGRP} -m 444 cards.pck \
diff --git a/games/phantasia/Makefile b/games/phantasia/Makefile
index aa068e8bd64..4b82358160b 100644
--- a/games/phantasia/Makefile
+++ b/games/phantasia/Makefile
@@ -1,3 +1,4 @@
+# $OpenBSD: Makefile,v 1.2 1996/03/09 01:33:30 niklas Exp $
# $NetBSD: Makefile,v 1.4 1995/03/24 03:58:22 cgd Exp $
# @(#)Makefile 8.1 (Berkeley) 5/31/93
@@ -11,8 +12,14 @@ CLEANFILES+=map setup setup.o
all: setup phantasia
-setup: phantglobs.o setup.o monsters.asc ${LIBM}
- ${CC} phantglobs.o setup.o -o ${.TARGET} -lm
+setup.o: setup.c
+ ${HOSTCC} -c setup.c -o ${.TARGET}
+
+phantglobs.o.bld: phantglobs.c
+ ${HOSTCC} -c phantglobs.c -o ${.TARGET}
+
+setup: phantglobs.o.bld setup.o monsters.asc ${LIBM}
+ ${HOSTCC} phantglobs.o.bld setup.o -o ${.TARGET} -lm
beforeinstall:
./setup -m ${.CURDIR}/monsters.asc
@@ -22,7 +29,7 @@ beforeinstall:
# PLOTDEVICE is used for plotting the map. Change as appropriate.
map: map.c
- ${CC} -O ${.CURDIR}/map.c -lplot -o ${.TARGET}
+ ${HOSTCC} -O ${.CURDIR}/map.c -lplot -o ${.TARGET}
./map | plot > /dev/tty
# XXX this rule shouldn't be here.