1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-25 00:51:21 +00:00
freebsd-ports/graphics/ocaml-images/Makefile
Stefan Eßer b7f05445c0 Add WWW entries to port Makefiles
It has been common practice to have one or more URLs at the end of the
ports' pkg-descr files, one per line and prefixed with "WWW:". These
URLs should point at a project website or other relevant resources.

Access to these URLs required processing of the pkg-descr files, and
they have often become stale over time. If more than one such URL was
present in a pkg-descr file, only the first one was tarnsfered into
the port INDEX, but for many ports only the last line did contain the
port specific URL to further information.

There have been several proposals to make a project URL available as
a macro in the ports' Makefiles, over time.

This commit implements such a proposal and moves one of the WWW: entries
of each pkg-descr file into the respective port's Makefile. A heuristic
attempts to identify the most relevant URL in case there is more than
one WWW: entry in some pkg-descr file. URLs that are not moved into the
Makefile are prefixed with "See also:" instead of "WWW:" in the pkg-descr
files in order to preserve them.

There are 1256 ports that had no WWW: entries in pkg-descr files. These
ports will not be touched in this commit.

The portlint port has been adjusted to expect a WWW entry in each port
Makefile, and to flag any remaining "WWW:" lines in pkg-descr files as
deprecated.

Approved by:		portmgr (tcberner)
2022-09-07 23:10:59 +02:00

87 lines
2.1 KiB
Makefile

PORTNAME= images
PORTVERSION= 4.0.1
PORTREVISION= 10
PORTEPOCH= 2
CATEGORIES= graphics
MASTER_SITES= https://bitbucket.org/camlspotter/camlimages/get/
PKGNAMEPREFIX= ocaml-
DISTNAME= v${PORTVERSION}
DIST_SUBDIR= ocaml-images
MAINTAINER= michael.grunewald@laposte.net
COMMENT= Objective Caml image processing library
WWW= http://pauillac.inria.fr/camlimages/
BROKEN= does not build: broken plist
BUILD_DEPENDS= ${LOCALBASE}/share/aclocal/ocaml.m4:lang/ocaml-autoconf
BUILD_DEPENDS+= omake:devel/omake
USE_OCAML= yes
USE_OCAML_FINDLIB= yes
OCAML_PKGDIRS= camlimages
OCAML_LDLIBS= ${OCAML_SITELIBDIR}/camlimages
OMAKESUBS+= -e s@%%INCLUDESPORTS%%@${LOCALBASE}/include@
OMAKESUBS+= -e s@%%INCLUDESX11%%@${LOCALBASE}/include/X11@
OMAKESUBS+= -e s@%%INCLUDESPNG%%@${LOCALBASE}/include/libpng15@
OMAKESUBS+= -e s@%%LDFLAGSPORTS%%@-L${LOCALBASE}/lib@
OMAKE= omake 'PREFIX=${STAGEDIR}${PREFIX}'
OMARGS= --dotomake .omake --force-dotomake
WRKSRC= ${WRKDIR}/camlspotter-camlimages-c803efa9d5d3
MAKE_JOBS_UNSAFE= yes
OPTIONS_DEFINE= PNG JPEG TIFF XPM GIF GHOSTSCRIPT GTK2 DOCS
OPTIONS_DEFAULT=PNG JPEG TIFF XPM GIF GHOSTSCRIPT
OPTIONS_SUB= yes
PNG_CONFIGURE_WITH= png
PNG_LIB_DEPENDS= libpng.so:graphics/png
JPEG_CONFIGURE_WITH= jpeg
JPEG_USES= jpeg
TIFF_CONFIGURE_WITH= tiff
TIFF_LIB_DEPENDS= libtiff.so:graphics/tiff
XPM_CONFIGURE_WITH= xpm
GIF_CONFIGURE_WITH= gif
GIF_LIB_DEPENDS= libgif.so:graphics/giflib
FREETYPE_USES= pkgconfig
FREETYPE_CONFIGURE_WITH=freetype
FREETYPE_LIB_DEPENDS= libfreetype.so:print/freetype2
GHOSTSCRIPT_CONFIGURE_WITH= gs
GHOSTSCRIPT_USES= ghostscript
GTK2_CONFIGURE_WITH= liblgtk2
GTK2_BUILD_DEPENDS= lablgtk2:x11-toolkits/ocaml-lablgtk2
GTK2_RUN_DEPENDS= lablgtk2:x11-toolkits/ocaml-lablgtk2
BINARY_ALIAS= freetype-config=true
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MXPM}
USES+= xorg
USE_XORG= xpm
.endif
do-configure:
@(cd ${WRKSRC} && ${REINPLACE_CMD} ${OMAKESUBS} OMakefile)
(cd ${WRKSRC} && ${OMAKE} ${OMARGS} configure)
do-build:
(cd ${WRKSRC} && ${OMAKE} ${OMARGS})
do-install:
@${MKDIR} ${STAGEDIR}${PREFIX}/${OCAML_LDLIBS}
(cd ${WRKSRC} && ${OMAKE} ${OMARGS} install)
.include <bsd.port.mk>