aboutsummaryrefslogtreecommitdiffstats
path: root/textproc
diff options
context:
space:
mode:
authormandree <mandree@FreeBSD.org>2013-10-26 06:32:09 +0800
committermandree <mandree@FreeBSD.org>2013-10-26 06:32:09 +0800
commit61f511b886e22f7e1030608c480f6c80a3b1d1d1 (patch)
tree6e9d8ce7355bef72791bca2ce4d6d0dbd8b3260b /textproc
parentbee3b0979868ad42f320cdaeabb5d7205e24c885 (diff)
downloadfreebsd-ports-gnome-61f511b886e22f7e1030608c480f6c80a3b1d1d1.tar.gz
freebsd-ports-gnome-61f511b886e22f7e1030608c480f6c80a3b1d1d1.tar.zst
freebsd-ports-gnome-61f511b886e22f7e1030608c480f6c80a3b1d1d1.zip
Fix dependency on passivetex if this option is enabled, reported by
Andriy Gapon and fix proposed by Hiroki Sato. Add xhtml2fo.xsl default XHTML1 -> FO style sheet from <http://www.antennahouse.com/XSLsample/XSLsample.htm> and install it into DATADIR; and add a pkg-message about its use. Submitted by: avg@ Obtained from: hrs@ PR: ports/183295
Diffstat (limited to 'textproc')
-rw-r--r--textproc/xmlto/Makefile33
-rw-r--r--textproc/xmlto/distinfo6
-rw-r--r--textproc/xmlto/files/patch-xmlto.in5
-rw-r--r--textproc/xmlto/files/pkg-message.in9
-rw-r--r--textproc/xmlto/pkg-plist1
5 files changed, 41 insertions, 13 deletions
diff --git a/textproc/xmlto/Makefile b/textproc/xmlto/Makefile
index 3535df9378c1..21758318f52e 100644
--- a/textproc/xmlto/Makefile
+++ b/textproc/xmlto/Makefile
@@ -3,9 +3,16 @@
PORTNAME= xmlto
PORTVERSION= 0.0.25
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= textproc
-MASTER_SITES= https://fedorahosted.org/releases/x/m/xmlto/
+MASTER_SITES= https://fedorahosted.org/releases/x/m/xmlto/:xmlto \
+ LOCAL/mandree/:xmlto \
+ http://www.antennahouse.com/XSLsample/sample-xsl-xhtml2fo/:xsl \
+ LOCAL/mandree/:xsl
+DISTFILES= ${PORTNAME}-${PORTVERSION}${EXTRACT_SUFX}:xmlto \
+ xhtml2fo.xsl:xsl
+DIST_SUBDIR= ${PORTNAME}
+EXTRACT_ONLY= ${PORTNAME}-${PORTVERSION}${EXTRACT_SUFX}
MAINTAINER= mandree@FreeBSD.org
COMMENT= Front-end to an XSL toolchain
@@ -22,11 +29,14 @@ BUILD_DEPENDS= ${BASH_CMD}:${PORTSDIR}/shells/bash \
${LOCALBASE}/share/xml/docbook/4.2/docbookx.dtd:${PORTSDIR}/textproc/docbook-xml
RUN_DEPENDS:= ${BUILD_DEPENDS}
-# TODO: make this a group for PDF output?
-OPTIONS_DEFINE= DBLATEX FOP PASSIVETEX
-DBLATEX_DESC= Add dependency on Dblatex
-FOP_DESC= Add dependency on FOP (needs Java)
-PASSIVETEX_DESC= - BROKEN - Add dependency on PassiveTeX
+SUB_FILES= pkg-message
+
+OPTIONS_GROUP= BACKEND
+OPTIONS_GROUP_BACKEND= DBLATEX FOP PASSIVETEX
+BACKEND_DESC= Postprocessor backends to enable
+DBLATEX_DESC= Add dependency on DBlatex (DB for DocBook)
+FOP_DESC= Add dependency on FOP (requires Java)
+PASSIVETEX_DESC= Add dependency on XMLTeX/PassiveTeX
USE_BZIP2= yes
GNU_CONFIGURE= yes
@@ -46,8 +56,7 @@ PORTDOCS= AUTHORS ChangeLog NEWS THANKS
.include <bsd.port.pre.mk>
.if ${PORT_OPTIONS:MPASSIVETEX}
-BUILD_DEPENDS+= ${LOCALBASE}/share/texmf-local/tex/passivetex/fotex.sty:${PORTSDIR}/print/passivetex
-BROKEN= the passivetex option is currently broken
+USE_TEX+= xmltex
.endif
.if ${PORT_OPTIONS:MFOP}
@@ -68,9 +77,11 @@ post-patch:
@# get rid of GNU-make-ism (BSD make defines $< only in suffix rules)
${REINPLACE_CMD} -e '/^GEN_MANPAGE/{s/\$$</$$>/;}' ${WRKSRC}/Makefile.in
-.if ${PORT_OPTIONS:MDOCS}
post-install:
- @${MKDIR} ${STAGEDIR}${DOCSDIR}
+ ${MKDIR} ${STAGEDIR}${DATADIR}
+ ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/xhtml2fo.xsl ${STAGEDIR}${DATADIR}/
+.if ${PORT_OPTIONS:MDOCS}
+ ${MKDIR} ${STAGEDIR}${DOCSDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR}
.endif
diff --git a/textproc/xmlto/distinfo b/textproc/xmlto/distinfo
index f4ca60612d06..8aa85f0a04f8 100644
--- a/textproc/xmlto/distinfo
+++ b/textproc/xmlto/distinfo
@@ -1,2 +1,4 @@
-SHA256 (xmlto-0.0.25.tar.bz2) = 361cb70d5d0b4b753db00b67ed8bc1d53d0bc96c407d0310aefe854470b7e536
-SIZE (xmlto-0.0.25.tar.bz2) = 116496
+SHA256 (xmlto/xmlto-0.0.25.tar.bz2) = 361cb70d5d0b4b753db00b67ed8bc1d53d0bc96c407d0310aefe854470b7e536
+SIZE (xmlto/xmlto-0.0.25.tar.bz2) = 116496
+SHA256 (xmlto/xhtml2fo.xsl) = 51984c86eda98fc70c2c0fa887626f44311634c5e3d1053cd2ada8cd2543ebd6
+SIZE (xmlto/xhtml2fo.xsl) = 63786
diff --git a/textproc/xmlto/files/patch-xmlto.in b/textproc/xmlto/files/patch-xmlto.in
index 07feb8a41709..483380beaa01 100644
--- a/textproc/xmlto/files/patch-xmlto.in
+++ b/textproc/xmlto/files/patch-xmlto.in
@@ -1,3 +1,8 @@
+This patch serves two purposes:
+
+#1 fix "noextensions" long option (accepted by upstream)
+#2 avoid that w3m or others pollute $HOME/
+
--- ./xmlto.in.orig 2011-11-29 12:49:57.000000000 +0100
+++ ./xmlto.in 2013-10-07 23:52:57.000000000 +0200
@@ -262,7 +262,7 @@
diff --git a/textproc/xmlto/files/pkg-message.in b/textproc/xmlto/files/pkg-message.in
new file mode 100644
index 000000000000..0969bf4dc1db
--- /dev/null
+++ b/textproc/xmlto/files/pkg-message.in
@@ -0,0 +1,9 @@
+For benefits of conversions away from XHTML1 through XSL-FO,
+a stylesheet xhtml2fo.xsl has been installed
+into %%DATADIR%%. Example use:
+
+ xmlto pdf -x %%DATADIR%%/xhtml2fo.xsl myXHTML1file.xml
+
+More style sheets for XHTML1 conversions can be found at
+<http://www.antennahouse.com/XSLsample/XSLsample.htm>
+under "Stylesheet for XHTML to XSL-FO transformation"
diff --git a/textproc/xmlto/pkg-plist b/textproc/xmlto/pkg-plist
index 2e45d6ff0f76..f7485a374273 100644
--- a/textproc/xmlto/pkg-plist
+++ b/textproc/xmlto/pkg-plist
@@ -36,6 +36,7 @@ man/man1/xmlto.1.gz
%%DATADIR%%/format/xhtml1/ps
%%DATADIR%%/format/xhtml1/svg
%%DATADIR%%/format/xhtml1/txt
+%%DATADIR%%/xhtml2fo.xsl
%%DATADIR%%/xmlto.mak
@dirrm %%DATADIR%%/format/xhtml1
@dirrm %%DATADIR%%/format/fo