summaryrefslogtreecommitdiff
path: root/fonts/adobe-cmaps/Makefile
blob: 627063505cc32a1681ea4331fe9f1fdb2c72cd7d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# $NetBSD: Makefile,v 1.17 2006/04/20 17:37:00 minskim Exp $

DISTNAME=	adobe-cmaps-20060419
CATEGORIES=	fonts print
MASTER_SITES=	# empty

CMAP_FILES=	ac15 ag15 ai0 aj16 aj20 ak12
RKSJ_FILES=	rksj-cmaps
CMAP_DISTFILES=	${CMAP_FILES:S/$/.tar.Z/} ${RKSJ_FILES:S/$/.tar.Z/}
.for FILE in ${CMAP_DISTFILES}
SITES_${FILE}+=	ftp://ftp.oreilly.com/pub/examples/nutshell/cjkv/adobe/
.endfor
DISTFILES+=	${CMAP_DISTFILES}
EXTRACT_ONLY=	${CMAP_DISTFILES}

PDFCORE=	chinese_s chinese_t japanese korean
PDFCORE_DISTFILES=	${PDFCORE:S/$/.zip/}
.for FILE in ${PDFCORE_DISTFILES}
SITES_${FILE}+=	http://partners.adobe.com/public/developer/en/pdf/
.endfor
DISTFILES+=	${PDFCORE_DISTFILES}

MAINTAINER=	minskim@NetBSD.org
HOMEPAGE=	http://partners.adobe.com/public/developer/opentype/
COMMENT=	Adobe CMap files for CJK

DIST_SUBDIR=	${PKGNAME_NOREV}
NO_CONFIGURE=	yes
NO_BUILD=	yes
USE_TOOLS+=	unzip

RESOURCEDIR=	${PREFIX}/share/Adobe/Resource

do-install:
	${INSTALL_DATA_DIR} ${RESOURCEDIR}
	for file in ${CMAP_DISTFILES}; do				\
		extract_file="${_DISTDIR}/$${file}"; export extract_file; \
		cd ${RESOURCEDIR}; ${EXTRACT_CMD};			\
	done
	for file in ${PDFCORE}; do					\
		${MKDIR} ${RESOURCEDIR}/pdfcorefonts/$${file};		\
		cd ${RESOURCEDIR}/pdfcorefonts/$${file};		\
		unzip -aaoq ${_DISTDIR}/$${file}.zip;			\
	done
	${INSTALL_DATA_DIR} ${RESOURCEDIR}/CMap
	cd ${RESOURCEDIR}; for dir in ${CMAP_FILES}; do			\
		for file in $${dir}/CMap/*; do				\
			${LN} -sf ../$${file} ${RESOURCEDIR}/CMap;	\
		done;							\
	done
	cd ${RESOURCEDIR}; for dir in ${RKSJ_FILES}; do			\
		for file in $${dir}/*; do				\
			${LN} -sf ../$${file} ${RESOURCEDIR}/CMap;	\
		done;							\
	done
	cd ${RESOURCEDIR}; for dir in ${PDFCORE}; do			\
		for file in pdfcorefonts/$${dir}/*; do			\
			case $${file} in				\
			*.pdf)	;;					\
			*)						\
				${RM} -f ${RESOURCEDIR}/CMap/`${BASENAME} $${file}`; \
				${LN} -sf ../$${file} ${RESOURCEDIR}/CMap; \
				;;					\
			esac;						\
		done;							\
	done

.include "../../mk/bsd.pkg.mk"