openbsd-ports/devel/coccinelle/Makefile
chrisz 1c78f0bc94 Bump revision after ocaml update.
ok from anil and @jasper
2012-12-03 20:08:46 +00:00

71 lines
1.7 KiB
Makefile

# $OpenBSD: Makefile,v 1.21 2012/12/03 20:08:46 chrisz Exp $
SHARED_ONLY = Yes
COMMENT = program matching and transformation engine
# if updating, check for any additional use of diff/grep which
# may need to be switched to gdiff/ggrep
DISTNAME = coccinelle-1.0.0-rc15
REVISION = 2
PKGNAME = ${DISTNAME:S/-rc/rc/}
EXTRACT_SUFX = .tgz
CATEGORIES = devel
HOMEPAGE = http://coccinelle.lip6.fr/
# GPLv2 only
PERMIT_PACKAGE_CDROM = Yes
PERMIT_PACKAGE_FTP = Yes
PERMIT_DISTFILES_CDROM = Yes
PERMIT_DISTFILES_FTP = Yes
WANTLIB += c curses m pthread util pcre ${MODPY_WANTLIB}
MASTER_SITES = ${HOMEPAGE}distrib/
MODULES = lang/ocaml \
lang/python
BUILD_DEPENDS = ${RUN_DEPENDS}
RUN_DEPENDS = devel/ocaml-pcre \
sysutils/findlib \
sysutils/ggrep \
textproc/gdiff
REGRESS_DEPENDS = ${FULLPKGPATH}
# asks questions at the end if it does better than expected
REGRESS_IS_INTERACTIVE = Yes
CONFIGURE_STYLE = gnu
CONFIGURE_ENV = MAKE_PROGRAM=${MAKE_PROGRAM}
# The PKG_CHECK_MODULES autoconf macro doesn't have a way to use .private
CONFIGURE_ENV += PYTHON_LIBS="`pkg-config --static --libs python`"
CONFIGURE_ARGS = --with-python=${MODPY_BIN}
USE_GMAKE = Yes
REGRESS_TARGET = test
.include <bsd.port.arch.mk>
.if ${PROPERTIES:Mocaml_native_dynlink}
# word builds both: opt AND byte
ALL_TARGET = world
.else
# all-release builds either opt OR byte
ALL_TARGET = all-release
.endif
pre-configure:
perl -pi -e s,/usr/local,${TRUEPREFIX},g ${WRKSRC}/scripts/spatch*
post-install:
${MODPY_BIN} ${MODPY_LIBDIR}/compileall.py \
${PREFIX}/share/coccinelle/python/coccilib
mv \
${PREFIX}/share/coccinelle/dllpycaml_stubs.so \
${PREFIX}/lib/ocaml/stublibs/
.include <bsd.port.mk>