aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--japanese/dvipsk/Makefile49
-rw-r--r--japanese/dvipsk/files/config.ps.ptex-tetex (renamed from japanese/dvipsk/files/config.ps)4
-rw-r--r--japanese/dvipsk/files/pkg-install.in41
-rw-r--r--japanese/dvipsk/files/ptex-kanji.map (renamed from japanese/dvipsk/files/kanji.map)0
-rw-r--r--japanese/dvipsk/pkg-plist20
5 files changed, 51 insertions, 63 deletions
diff --git a/japanese/dvipsk/Makefile b/japanese/dvipsk/Makefile
index c52d203e2a96..976107179813 100644
--- a/japanese/dvipsk/Makefile
+++ b/japanese/dvipsk/Makefile
@@ -7,6 +7,7 @@
PORTNAME= dvipsk
PORTVERSION= 5.92b
+PORTREVISION= 1
CATEGORIES= japanese print
MASTER_SITES= ftp://sunsite.informatik.rwth-aachen.de/pub/comp/tex/teTeX/2.0/distrib/ \
${MASTER_SITE_TEX_CTAN} \
@@ -21,14 +22,25 @@ DIST_SUBDIR= teTeX
MAINTAINER= hrs@FreeBSD.org
COMMENT= A DVI to PostScript translator + Japanese patch
-BUILD_DEPENDS= mktexlsr:${PORTSDIR}/print/teTeX
+BUILD_DEPENDS= tetex-modesw:${PORTSDIR}/print/tex-texmflocal \
+ ${LOCALBASE}/${TEXMF}/LICENSE.texmf:${PORTSDIR}/print/teTeX-texmf \
+ mktexlsr:${PORTSDIR}/print/teTeX-base \
+ ${LOCALBASE}/${TEXMF}/fonts/tfm/ptex/min10.tfm:${PORTSDIR}/japanese/ptex-tetex
+RUN_DEPENDS= tetex-modesw:${PORTSDIR}/print/tex-texmflocal \
+ ${LOCALBASE}/${TEXMF}/LICENSE.texmf:${PORTSDIR}/print/teTeX-texmf \
+ mktexlsr:${PORTSDIR}/print/teTeX-base \
+ ${LOCALBASE}/${TEXMF}/fonts/tfm/ptex/min10.tfm:${PORTSDIR}/japanese/ptex-tetex
LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
wwwcore.1:${PORTSDIR}/www/libwww \
t1.5:${PORTSDIR}/devel/t1lib
-RUN_DEPENDS= mktexlsr:${PORTSDIR}/print/teTeX
-WRKSRC= ${WRKDIR}/tetex-src-${VER_TETEX}
-PLIST_SUB= TEXMFDIR=${TEXMFDIR} MKTEXLSR=${MKTEXLSR}
+PATCH_WRKSRC= ${WRKDIR}/tetex-src-${VER_TETEX}/texk
+EXTRA_PATCHES= ${WRKDIR}/dvipsk-${PORTVERSION}-p${VER_JPATCH}.patch
+CONFIGURE_WRKSRC=${WRKDIR}/tetex-src-${VER_TETEX}
+BUILD_WRKSRC= ${WRKDIR}/tetex-src-${VER_TETEX}/texk/dvipsk
+INSTALL_WRKSRC= ${WRKDIR}/tetex-src-${VER_TETEX}/texk/dvipsk
+
+PLIST_SUB= TEXMF=${TEXMF} MKTEXLSR=${MKTEXLSR}
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --prefix=${PREFIX} \
--disable-multiplatform \
@@ -50,30 +62,27 @@ INFO= dvips
VER_TETEX= 2.0.2
VER_JPATCH= 1.6
MKTEXLSR?= ${LOCALBASE}/bin/mktexlsr
-TEXMFDIR?= share/texmf
+TEXMF?= share/texmf
LIBPNG_PREFIX?= ${LOCALBASE}
LIBWWW_PREFIX?= ${LOCALBASE}
LIBT1_PREFIX?= ${LOCALBASE}
-DVIPSKCNF= ${PREFIX}/${TEXMFDIR}/dvips/config/config.ps
-do-patch:
- cd ${WRKSRC}/texk &&\
- ${PATCH} -p0 < ${WRKDIR}/dvipsk-${PORTVERSION}-p${VER_JPATCH}.patch
- ${SED} -e 's,%%TEXMFCNF%%,${TEXMFCNF},g;s,%%DVIPSKCNF%%,${DVIPSKCNF},g;s,%%MKTEXLSR%%,${MKTEXLSR},g' \
+TETEX_MODESW= ${PREFIX}/bin/tetex-modesw
+PKGINSTALL_SUB= TETEX_MODESW=${TETEX_MODESW} \
+ MKTEXLSR=${MKTEXLSR}
+
+post-configure:
+ ${SED} ${PKGINSTALL_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
< ${FILESDIR}/pkg-install.in > ${PKGINSTALL}
${CHMOD} 0755 ${PKGINSTALL}
-do-build:
- cd ${WRKSRC}/texk/dvipsk &&\
- ${MAKE_ENV} ${MAKE} ${ALL_TARGET}
-
-do-install:
- cd ${WRKSRC}/texk/dvipsk &&\
- ${MAKE_ENV} ${MAKE} ${INSTALL_TARGET}
- ${INSTALL_DATA} ${FILESDIR}/kanji.map ${PREFIX}/${TEXMFDIR}/dvips/config
- ${INSTALL_DATA} ${FILESDIR}/config.ps ${PREFIX}/${TEXMFDIR}/dvips/config/config.ps.ptex-tetex
-
post-install:
+ ${INSTALL_DATA} \
+ ${FILESDIR}/ptex-kanji.map \
+ ${PREFIX}/${TEXMF}/dvips/ptex/ptex-kanji.map
+ ${INSTALL_DATA} \
+ ${FILESDIR}/config.ps.ptex-tetex \
+ ${PREFIX}/${TEXMF}/dvips/config/config.ps.ptex-tetex
@${PKGINSTALL} ${PKGNAME} POST-INSTALL
.include <bsd.port.mk>
diff --git a/japanese/dvipsk/files/config.ps b/japanese/dvipsk/files/config.ps.ptex-tetex
index 75887167b5c7..e238c93fcacc 100644
--- a/japanese/dvipsk/files/config.ps
+++ b/japanese/dvipsk/files/config.ps.ptex-tetex
@@ -1,5 +1,5 @@
-% teTeX's config.ps. Thomas Esser, 1998, public domain.
% $FreeBSD$
+% teTeX's config.ps. Thomas Esser, 1998, public domain.
% Memory available. Download the three-line PostScript file:
% %! Hey, we're PostScript
@@ -46,7 +46,7 @@ j
% This shows how to add your own map file.
% Remove the comment and adjust the name:
% p +myfonts.map
-p +kanji.map
+p +ptex-kanji.map
@ A4size 210mm 297mm
@+ %%PaperSize: A4
diff --git a/japanese/dvipsk/files/pkg-install.in b/japanese/dvipsk/files/pkg-install.in
index 0adf608d8b70..3f237b917e13 100644
--- a/japanese/dvipsk/files/pkg-install.in
+++ b/japanese/dvipsk/files/pkg-install.in
@@ -2,39 +2,18 @@
GREP=/usr/bin/grep
SED=/usr/bin/sed
-SUFFIX=ptex-tetex
+MODE=ptex-tetex
+
+MKTEXLSR=%%MKTEXLSR%%
+TETEX_MODESW=%%TETEX_MODESW%%
case $2 in
POST-INSTALL)
- if [ ! -f %%DVIPSKCNF%% ]; then
- cp %%DVIPSKCNF%%.${SUFFIX} %%DVIPSKCNF%%
- echo "Notice: installing %%DVIPSKCNF%%.${SUFFIX} -> %%DVIPSKCNF%%."
- %%MKTEXLSR%%
- elif ${SED} q < %%DVIPSKCNF%% | ${GREP} "public domain" > /dev/null 2>&1; then
- cp %%DVIPSKCNF%%.${SUFFIX} %%DVIPSKCNF%%
- echo "Notice: installing %%DVIPSKCNF%%.${SUFFIX} -> %%DVIPSKCNF%%."
- %%MKTEXLSR%%
- else
- echo "Notice: %%DVIPSKCNF%% is not installed."
- echo " Merge from %%DVIPSKCNF%%.${SUFFIX} manually."
- fi
-;;
+ %%TETEX_MODESW%% ${MODE} dvips forceinstall
+ %%MKTEXLSR%%
+ ;;
DEINSTALL)
- if [ -f %%DVIPSKCNF%% ]; then
- if ${SED} q < %%DVIPSKCNF%% | ${GREP} "public domain" > /dev/null 2>&1; then
- if [ -f %%DVIPSKCNF%%.tetex ]; then
- cp %%DVIPSKCNF%%.tetex %%DVIPSKCNF%%
- echo "Notice: installing %%DVIPSKCNF%%.tetex -> %%DVIPSKCNF%%."
- %%MKTEXLSR%%
- else
- rm -f %%DVIPSKCNF%%
- echo "Notice: %%DVIPSKCNF%% is removed."
- %%MKTEXLSR%%
- fi
- else
- echo "Notice: %%DVIPSKCNF%% is NOT removed."
- echo " Remove manually."
- fi
- fi
-;;
+ %%TETEX_MODESW%% default dvips forceinstall
+ %%MKTEXLSR%%
+ ;;
esac
diff --git a/japanese/dvipsk/files/kanji.map b/japanese/dvipsk/files/ptex-kanji.map
index 899c1c0f4d33..899c1c0f4d33 100644
--- a/japanese/dvipsk/files/kanji.map
+++ b/japanese/dvipsk/files/ptex-kanji.map
diff --git a/japanese/dvipsk/pkg-plist b/japanese/dvipsk/pkg-plist
index 4454e9a188f2..11bf5cc8aab9 100644
--- a/japanese/dvipsk/pkg-plist
+++ b/japanese/dvipsk/pkg-plist
@@ -1,13 +1,13 @@
@comment $FreeBSD$
bin/afm2tfm
bin/dvips
-%%TEXMFDIR%%/dvips/base/tex.pro
-%%TEXMFDIR%%/dvips/base/texps.pro
-%%TEXMFDIR%%/dvips/base/texc.pro
-%%TEXMFDIR%%/dvips/base/special.pro
-%%TEXMFDIR%%/dvips/base/finclude.pro
-%%TEXMFDIR%%/dvips/base/color.pro
-%%TEXMFDIR%%/dvips/base/crop.pro
-%%TEXMFDIR%%/dvips/base/hps.pro
-%%TEXMFDIR%%/dvips/config/kanji.map
-%%TEXMFDIR%%/dvips/config/config.ps.ptex-tetex
+%%TEXMF%%/dvips/base/tex.pro
+%%TEXMF%%/dvips/base/texps.pro
+%%TEXMF%%/dvips/base/texc.pro
+%%TEXMF%%/dvips/base/special.pro
+%%TEXMF%%/dvips/base/finclude.pro
+%%TEXMF%%/dvips/base/color.pro
+%%TEXMF%%/dvips/base/crop.pro
+%%TEXMF%%/dvips/base/hps.pro
+%%TEXMF%%/dvips/ptex/ptex-kanji.map
+%%TEXMF%%/dvips/config/config.ps.ptex-tetex