blob: f618394030028ad694ec549ca0dcc49140b030d3 (
plain)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
# Created by: ijliao
# $FreeBSD$
PORTNAME= sdl
PORTVERSION= 0.9.1
PORTREVISION= 2
CATEGORIES= devel
MASTER_SITES= SF/ocaml${PORTNAME}/OCamlSDL/ocaml${PORTNAME}-${PORTVERSION}
PKGNAMEPREFIX= ocaml-
DISTNAME= ocamlsdl-${PORTVERSION}
MAINTAINER= ports@FreeBSD.org
COMMENT= OCaml interface to the SDL
LICENSE= LGPL21
BUILD_DEPENDS= ocaml-lablgl>0:graphics/ocaml-lablgl
OPTIONS_DEFINE= SDL_GFX SDL_IMAGE SDL_MIXER SDL_TTF DOCS
OPTIONS_DEFAULT=SDL_GFX SDL_IMAGE SDL_MIXER SDL_TTF
SDL_GFX_DESC= Enable SDL_gfx support
SDL_IMAGE_DESC= Enable SDL_image support
SDL_MIXER_DESC= Enable SDL_mixer support
SDL_TTF_DESC= Enable SDL_ttf support
USE_OCAML= yes
USE_OCAML_FINDLIB=yes
USE_OCAMLFIND_PLIST=yes
USE_OCAML_LDCONFIG=yes
USES= gmake
USE_SDL= sdl
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-lablgldir=${LOCALBASE} \
--with-sdl-prefix=${LOCALBASE} \
--with-installdir=${PREFIX}
DOCSDIR= ${OCAML_DOCSDIR}/${PORTNAME}
INFO= ocamlsdl
PORTDOCS= *
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MSDL_GFX}
USE_SDL+= gfx
.else
CONFIGURE_ARGS+=--disable-sdl-gfx
.endif
.if ${PORT_OPTIONS:MSDL_IMAGE}
USE_SDL+= image
.else
CONFIGURE_ARGS+=--disable-sdl-image
.endif
.if ${PORT_OPTIONS:MSDL_MIXER}
USE_SDL+= mixer
.else
CONFIGURE_ARGS+=--disable-sdl-mixer
.endif
.if ${PORT_OPTIONS:MSDL_TTF}
USE_SDL+= ttf
.else
CONFIGURE_ARGS+=--disable-sdl-ttf
.endif
post-install:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/ocaml/site-lib/sdl/dllsdlloaderstub.so
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/ocaml/site-lib/sdl/dllsdlttfstub.so
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/ocaml/site-lib/sdl/dllsdlgfxstub.so
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/ocaml/site-lib/sdl/dllsdlmixerstub.so
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/ocaml/site-lib/sdl/dllsdlstub.so
${INSTALL_DATA} ${WRKSRC}/doc/ocamlsdl.info ${STAGEDIR}${PREFIX}/${INFO_PATH}
@${MKDIR} ${STAGEDIR}${DOCSDIR}
(cd ${WRKSRC}/doc/html && ${INSTALL_DATA} * ${STAGEDIR}${DOCSDIR})
.include <bsd.port.mk>
|