freebsd-ports/graphics/ocaml-images/Makefile

145 lines
3.7 KiB
Makefile
Raw Normal View History

# ex:ts=8
# Ports collection makefile for: ocaml-images
# Date created: Feb 7, 2003
# Whom: ijliao
#
# $FreeBSD$
#
PORTNAME= images
2010-03-26 22:11:48 +01:00
PORTVERSION= 3.0.2
2012-06-01 07:26:28 +02:00
PORTREVISION= 8
PORTEPOCH= 2
CATEGORIES= graphics
2010-03-26 22:11:48 +01:00
MASTER_SITES= ftp://ftp.inria.fr/INRIA/Projects/cristal/caml-light/bazar-ocaml/ \
http://caml.inria.fr/distrib/bazar-ocaml/
PKGNAMEPREFIX= ocaml-
DISTNAME= camlimages-${PORTVERSION}
EXTRACT_SUFX= .tgz
MAINTAINER= michael.grunewald@laposte.net
2003-02-20 19:08:19 +01:00
COMMENT= Objective Caml image processing library
2010-03-26 22:11:48 +01:00
BUILD_DEPENDS= ${LOCALBASE}/share/aclocal/ocaml.m4:${PORTSDIR}/lang/ocaml-autoconf
BROKEN= does not compile
2010-12-04 08:34:27 +01:00
USE_AUTOTOOLS= aclocal autoheader automake autoconf
2010-03-26 22:11:48 +01:00
ACLOCAL_ARGS= -I . -I ${LOCALBASE}/share/aclocal
AUTOMAKE_ARGS= --add-missing
USE_OCAML= yes
USE_OCAML_FINDLIB= yes
USE_OCAMLFIND_PLIST= yes
2010-03-26 22:11:48 +01:00
USE_OCAML_WASH= yes
OCAML_PKGDIRS= camlimages
USE_OCAML_LDCONFIG= yes
CPPFLAGS+= -I${LOCALBASE}/include
2012-06-01 07:26:28 +02:00
CFLAGS+= -I${LOCALBASE}/include/libpng15
LDFLAGS+= -L${LOCALBASE}/lib
MAKE_JOBS_UNSAFE= yes
2010-03-26 22:11:48 +01:00
OPTIONS= PNG "Enable PNG support" on \
JPEG "Enable JPEG support" on \
TIFF "Enable TIFF support" on \
XPM "Enable XPM support" on \
GIF "Enable GIF support" on \
FREETYPE "Enable text rendering via freetype" on \
GS "Enable PostScript support via Ghostscript" on \
2010-03-26 22:11:48 +01:00
GTK1 "Enable LablGTK1 support" off \
GTK2 "Enable LablGTK2 support (conflicts with LablGTK1)" off
.include <bsd.port.options.mk>
.if !defined(WITHOUT_PNG)
2012-06-01 07:26:28 +02:00
LIB_DEPENDS+= png15:${PORTSDIR}/graphics/png
2010-03-26 22:11:48 +01:00
CONFIGURE_ARGS+= --with-png
.else
CONFIGURE_ARGS+= --without-png
.endif
.if !defined(WITHOUT_JPEG)
LIB_DEPENDS+= jpeg.11:${PORTSDIR}/graphics/jpeg
CONFIGURE_ARGS+= --with-jpeg
.else
CONFIGURE_ARGS+= --without-jpeg
.endif
.if !defined(WITHOUT_TIFF)
LIB_DEPENDS+= tiff.4:${PORTSDIR}/graphics/tiff
CONFIGURE_ARGS+= --with-tiff
.else
CONFIGURE_ARGS+= --without-tiff
.endif
.if !defined(WITHOUT_XPM)
USE_XORG= xpm
2010-03-26 22:11:48 +01:00
CONFIGURE_ARGS+= --with-xpm
.else
CONFIGURE_ARGS+= --without-xpm
.endif
.if !defined(WITHOUT_GIF)
LIB_DEPENDS+= gif.5:${PORTSDIR}/graphics/giflib
2010-03-26 22:11:48 +01:00
CONFIGURE_ARGS+= --with-gif
.else
CONFIGURE_ARGS+= --without-gif
.endif
.if !defined(WITHOUT_FREETYPE)
USE_FREETYPE= yes
2010-03-26 22:11:48 +01:00
CONFIGURE_ARGS+= --with-freetype
.else
CONFIGURE_ARGS+= --without-freetype
.endif
.if defined(WITH_GS)
USE_GHOSTSCRIPT= yes
CONFIGURE_ARGS+= --with-gs
.else
CONFIGURE_ARGS+= --without-gs
.endif
.if defined(WITH_GTK1) && defined(WITH_GTK2)
IGNORE= you should select either LablGTK1 or LablGTK2, but not both
.endif
.if defined(WITH_GTK1)
CONFIGURE_ARGS+= --with-lablgtk
BUILD_DEPENDS+= lablgtk:${PORTSDIR}/x11-toolkits/ocaml-lablgtk
RUN_DEPENDS+= lablgtk:${PORTSDIR}/x11-toolkits/ocaml-lablgtk
.else
CONFIGURE_ARGS+= --without-lablgtk
.endif
.if defined(WITH_GTK2)
CONFIGURE_ARGS+= --with-lablgtk2
BUILD_DEPENDS+= lablgtk2:${PORTSDIR}/x11-toolkits/ocaml-lablgtk2
RUN_DEPENDS+= lablgtk2:${PORTSDIR}/x11-toolkits/ocaml-lablgtk2
.else
CONFIGURE_ARGS+= --without-lablgtk2
.endif
2010-03-26 22:11:48 +01:00
GNU_CONFIGURE= yes
#USE_GMAKE= yes
2004-03-24 04:13:47 +01:00
#the default docsdir gets expanded to ${PREFIX}/share/doc/images
#which isn't of much help when you are searching for the package docs
2010-03-26 22:11:48 +01:00
DOCSDIR= ${PREFIX}/share/doc/${PKGNAMEPREFIX}${PORTNAME}
DOCSFILES= CHANGES README LICENSE
.if !defined(NOPORTDOCS)
2010-03-26 22:11:48 +01:00
PORTDOCS= ${DOCSFILES} doc
.endif
2004-03-24 04:13:47 +01:00
post-install:
.if !defined(NOPORTDOCS)
2010-03-26 22:11:48 +01:00
@${MKDIR} ${DOCSDIR}/doc
@(cd ${WRKSRC} && ${COPYTREE_SHARE} \* ${DOCSDIR}/doc '-name "*.jpg" -o -name "*.html"')
@${INSTALL_DATA} ${DOCSFILES:S,^,${WRKSRC}/,g} ${DOCSDIR}/
.endif
2010-03-26 22:11:48 +01:00
@${ECHO_CMD} "lib/ocaml/stublibs/dllcamlimages.so" >> ${TMPPLIST}
@${ECHO_CMD} "lib/ocaml/stublibs/dllcamlimages_core.so" >> ${TMPPLIST}
@${ECHO_CMD} "@unexec ${RMDIR} %D/lib/ocaml/stublibs >/dev/null 2>&1 || ${TRUE}" >> ${TMPPLIST}
2004-03-24 04:13:47 +01:00
.include <bsd.port.mk>