1#	$OpenBSD: Makefile,v 1.16 2015/11/25 23:18:11 deraadt Exp $
2
3PROG=	atc
4CFLAGS+=-I${.CURDIR} -I.
5SRCS=	extern.c grammar.y graphics.c input.c lex.l list.c log.c \
6	main.c update.c
7MAN=	atc.6
8LDADD=	-ll -lm -lcurses
9DPADD=	${LIBL} ${LIBM} ${LIBCURSES}
10GAMES=	Game_List Killer crossover default easy game_2 \
11	Atlantis OHare Tic-Tac-Toe airports box crosshatch game_3 \
12	game_4 novice two-corners
13
14beforeinstall: 
15	@if [ ! -d ${DESTDIR}/usr/share/games/atc ]; then \
16                /bin/rm -f ${DESTDIR}/usr/share/games/atc ; \
17                mkdir -p ${DESTDIR}/usr/share/games/atc ; \
18                chown root:wheel ${DESTDIR}/usr/share/games/atc ; \
19                chmod 755 ${DESTDIR}/usr/share/games/atc ; \
20        else \
21                true ; \
22        fi
23	(cd ${.CURDIR}/games; ${INSTALL} ${INSTALL_COPY} \
24	    -o ${BINOWN} -g ${BINGRP} \
25	    -m 444 ${GAMES} ${DESTDIR}/usr/share/games/atc)
26
27.include <bsd.prog.mk>
28