diff options
author | Mikhail Teterin <mi@FreeBSD.org> | 2007-04-16 03:29:11 +0000 |
---|---|---|
committer | Mikhail Teterin <mi@FreeBSD.org> | 2007-04-16 03:29:11 +0000 |
commit | 9606e35d58cb77ce81ab3588d7386aefa82f4309 (patch) | |
tree | 90cfe1f434b8d6b82fc149c5d98142414754312b /textproc/htmldoc/Makefile | |
parent | a0a96fb91abb7412cb32fc5b9a75405ba115bfb7 (diff) | |
download | ports-9606e35d58cb77ce81ab3588d7386aefa82f4309.tar.gz ports-9606e35d58cb77ce81ab3588d7386aefa82f4309.zip |
Improve the port as follows:
1) do not extract, configure, build the bundled (old) PNG and JPEG
libraries;
2) do not compile the bundled md5 and rc4 algorithms (USE_OPENSSL);
3) do not compile the bundled snprintf.
The resulting executable is over twice smaller on my amd64 system. Bump
PORTREVISION.
Approved by: maintainer timeout
Notes
Notes:
svn path=/head/; revision=190061
Diffstat (limited to 'textproc/htmldoc/Makefile')
-rw-r--r-- | textproc/htmldoc/Makefile | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/textproc/htmldoc/Makefile b/textproc/htmldoc/Makefile index 28e5946131f7..4ed8bb9100a2 100644 --- a/textproc/htmldoc/Makefile +++ b/textproc/htmldoc/Makefile @@ -7,6 +7,7 @@ PORTNAME= htmldoc PORTVERSION= 1.8.27 +PORTREVISION= 1 CATEGORIES= textproc MASTER_SITES= ${MASTER_SITE_EASYSW} MASTER_SITE_SUBDIR= ${PORTNAME}/${PORTVERSION} @@ -15,9 +16,40 @@ DISTNAME= ${PORTNAME}-${PORTVERSION}-source MAINTAINER= jose@diasfernandes.pt COMMENT= Converts HTML to PDF and/or PostScript +LIB_DEPENDS= jpeg:${PORTSDIR}/graphics/jpeg \ + png:${PORTSDIR}/graphics/png + +OPTIONS= HTMLDOCGUI "Build GUI front-end" no +# .bz2 file is available since Aug 2, but we don't want to +# start mirroring _in addition to_ the .gz variant. When the +# vendor's release is updated again, we should switch to .bz2 +#USE_BZIP2= yes + GNU_CONFIGURE= yes +# Configure seems broken and ignores these ATM: +CONFIGURE_ARGS+=--enable-localjpeg --enable-localzlib --enable-localpng WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION} +EXCLUDE= png jpeg zlib htmldoc/md5* htmldoc/rc4* htmldoc/snprintf* +EXTRACT_AFTER_ARGS=| ${TAR} -xf - ${EXCLUDE:S,^,--exclude ,} MAN1= htmldoc.1 +post-patch: + ${REINPLACE_CMD} -e 's,@JPEG@ @ZLIB@ @PNG@ ,,' ${WRKSRC}/Makefile.in + ${REINPLACE_CMD} -e 's|@LDFLAGS@|-L${LOCALBASE}/lib @LDFLAGS@|' \ + -e 's|@JPEGINC@ @PNGINC@ @ZLIBINC@|-I${LOCALBASE}/include|' \ + ${WRKSRC}/Makedefs.in + # Remove redundant code: + ${REINPLACE_CMD} -Ee 's,(md5|snprintf|rc4)\.o,,g' \ + ${WRKSRC}/htmldoc/Makefile + +post-configure: + ${REINPLACE_CMD} -e \ + 's|../png/libpng.a ../zlib/libz.a ../jpeg/libjpeg.a|-ljpeg -lpng -lz|' ${WRKSRC}/Makedefs + +.include <bsd.port.pre.mk> -.include <bsd.port.mk> +.if !defined(WITHOUT_HTMLDOCGUI) +LIB_DEPENDS+= fltk:${PORTSDIR}/x11-toolkits/fltk +CONFIGURE_ARGS+=--enable-gui +.endif +.include <bsd.port.post.mk> |