summaryrefslogtreecommitdiff
path: root/devel/ocaml-findlib/Makefile
blob: cfb82b4ec088f15cf0519a9349d2f06000de2c78 (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
# $NetBSD: Makefile,v 1.2 2006/05/20 13:47:43 rillig Exp $
#

DISTNAME=		findlib-1.1.2pl1
PKGNAME=		ocaml-${DISTNAME}
PKGREVISION=		1
CATEGORIES=		devel
MASTER_SITES=		http://www.ocaml-programming.de/packages/

MAINTAINER=		rillig@NetBSD.org
HOMEPAGE=		http://www.ocaml-programming.de/packages/
COMMENT=		Library finder for OCaml

USE_TOOLS+=		gmake
USE_PKGLOCALEDIR=	yes
HAS_CONFIGURE=		yes
CONFIGURE_ARGS+=	-bindir ${PREFIX}/bin
CONFIGURE_ARGS+=	-mandir ${PREFIX}/${PKGMANDIR}
CONFIGURE_ARGS+=	-config ${PKG_SYSCONFDIR}/ocamlfind.conf

EGDIR=			${PREFIX}/share/examples/ocaml-findlib
INSTALL_MAKE_FLAGS+=	OCAMLFIND_CONF=${EGDIR}/ocamlfind.conf
INSTALLATION_DIRS=	libexec

CONF_FILES=		${EGDIR}/ocamlfind.conf ${PKG_SYSCONFDIR}/ocamlfind.conf

USE_TOOLS+=		fgrep:run sh:run
SUBST_CLASSES+=		ofr
SUBST_STAGE.ofr=	pre-configure
SUBST_FILES.ofr=	ocaml-findlib-register.sh
SUBST_SED.ofr=		-e 's,@SH@,'${SH:Q}','
SUBST_SED.ofr+=		-e 's,@PREFIX@,${PREFIX},'
SUBST_SED.ofr+=		-e 's,@FGREP@,'${FGREP:Q}','

post-extract:
	${CP} ${FILESDIR}/ocaml-findlib-register.sh ${WRKSRC}

post-install:
	${INSTALL_SCRIPT} ${WRKSRC}/ocaml-findlib-register.sh ${PREFIX}/libexec/ocaml-findlib-register

.include "../../lang/ocaml/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"