summaryrefslogtreecommitdiff
path: root/games/apricots/Makefile
blob: 1b28b77191a3ec3c949d6fd5b7b1b7a33bbb2047 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Created by: Dmitry Marakasov <amdmi3@amdmi3.ru>
# $FreeBSD$

PORTNAME=	apricots
PORTVERSION=	0.2.6
PORTREVISION=	4
CATEGORIES=	games
MASTER_SITES=	http://www.fishies.org.uk/ \
		http://mirror.amdmi3.ru/distfiles/

MAINTAINER=	amdmi3@FreeBSD.org
COMMENT=	Fly a little plane around and shoot things and drop bombs

USE_AUTOTOOLS=	libtool
GNU_CONFIGURE=	yes
USE_GMAKE=	yes
USE_SDL=	sdl
USE_DOS2UNIX=	yes
MAKE_JOBS_SAFE=	yes

CPPFLAGS+=	-I${LOCALBASE}/include
LDFLAGS+=	-L${LOCALBASE}/lib

PORTDOCS=	README

DESKTOP_ENTRIES="Apricots" \
		"Fly a little plane around and shoot things and drop bombs" \
		"" \
		"apricots" \
		"Game;ArcadeGame;" \
		false

OPTIONS_DEFINE=	OPENAL
OPTIONS_DEFAULT=OPENAL

.include <bsd.port.options.mk>

.if ${PORT_OPTIONS:MOPENAL}
USE_OPENAL=	al alut
.endif

post-patch:
.if ${PORT_OPTIONS:MOPENAL}
	@${REINPLACE_CMD} -e '/^LIBS = / s|$$| -lopenal -lalut|' \
		${WRKSRC}/apricots/Makefile.in
.else
	@${REINPLACE_CMD} -e 's|-DAP_AUDIO_OPENAL||' ${WRKSRC}/configure
.endif
	@${REINPLACE_CMD} -e 's|-O2||' ${WRKSRC}/configure

.if ${PORT_OPTIONS:MDOCS}
post-install:
	${MKDIR} ${DOCSDIR}
.for f in ${PORTDOCS}
	${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
.endfor
.endif

.include <bsd.port.mk>