Bug 107195 - [patch] a2ps port does not support i18n
Summary: [patch] a2ps port does not support i18n
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Dirk Meyer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-12-25 17:00 UTC by Eugene Grosbein
Modified: 2006-12-29 18:45 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eugene Grosbein 2006-12-25 17:00:37 UTC
	ports/print/a2ps installs international encoding support
	of a2ps package but does not install additional files
	from vendor site needed to use this support.

Fix: The following pach to ports/print/a2ps-letter
	fetches and builds a2ps with its internationalization package
	if WITH_I18N knob was used. This is 'no-op' change otherwise.



Eugene Grosbein--N3Hd6Yux0wj2HdtX4ZEoQXQ2RN0Sfd29F6kRPb67BOTqHQkN
Content-Type: text/plain; name="file.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="file.diff"

diff -urN a2ps-letter.orig/Makefile a2ps-letter/Makefile
--- a2ps-letter.orig/Makefile	Sat May 20 20:09:12 2006
+++ a2ps-letter/Makefile	Mon Dec 25 23:40:47 2006
@@ -55,6 +55,27 @@
 PLIST_SUB+=	WITHEMACS="@comment "
 .endif
 
+.if defined(WITH_I18N)
+PLIST_SUB+=	WITHI18N=""
+I18N_PACKAGE=	i18n-fonts-0.1
+DISTFILES=	${DISTNAME}${EXTRACT_SUFX} ${I18N_PACKAGE}${EXTRACT_SUFX}
+
+pre-configure:
+	@cd ${WRKDIR}/${I18N_PACKAGE}/afm && ${ECHO} *.afm > afms.lst && \
+	${MV} *.afm ${WRKSRC}/afm && cd ../fonts && \
+	${MV} *.pfb ${WRKSRC}/fonts
+
+post-configure:
+	@cd ${WRKSRC}/fonts && { ${ECHO} ''; \
+	${ECHO} "pfb_fonts =" *.pfb; } >> Makefile && \
+	${REINPLACE_CMD} 's,^\(fonts_DATA = .*\),\1 $$(pfb_fonts),' Makefile
+	@cd ${WRKSRC}/afm && { ${ECHO} ''; \
+	${ECHO} "i18n_afms =" `cat ${WRKDIR}/${I18N_PACKAGE}/afm/afms.lst`; } >> Makefile && \
+	${REINPLACE_CMD} 's,^\(all_afms = .*\),\1 $$(i18n_afms),' Makefile
+.else
+PLIST_SUB+=	WITHI18N="@comment "
+.endif
+
 post-install:
 	${STRIP_CMD} ${PREFIX}/bin/a2ps
 .if defined(WITH_EMACS)
diff -urN a2ps-letter.orig/distinfo a2ps-letter/distinfo
--- a2ps-letter.orig/distinfo	Sun Nov 13 16:26:44 2005
+++ a2ps-letter/distinfo	Mon Dec 25 20:55:29 2006
@@ -1,3 +1,6 @@
 MD5 (a2ps-4.13b.tar.gz) = 0c8e0c31b08c14f7a7198ce967eb3281
 SHA256 (a2ps-4.13b.tar.gz) = f4d2ac6f09f44eeb82621530b1970afe88fd97cfe82da43b61069800d0c06d12
 SIZE (a2ps-4.13b.tar.gz) = 1944289
+MD5 (i18n-fonts-0.1.tar.gz) = fee1456d0e6e94af4fc5b5a1bb9687b7
+SHA256 (i18n-fonts-0.1.tar.gz) = 20628df682359044b8e5241c97a3c8da7a098aa260a7d281a87f67486a531786
+SIZE (i18n-fonts-0.1.tar.gz) = 352530
diff -urN a2ps-letter.orig/pkg-plist a2ps-letter/pkg-plist
--- a2ps-letter.orig/pkg-plist	Sun Jan 22 09:48:47 2006
+++ a2ps-letter/pkg-plist	Mon Dec 25 23:03:36 2006
@@ -47,6 +47,16 @@
 %%DATADIR%%/afm/ptmr.afm
 %%DATADIR%%/afm/pzcmi.afm
 %%DATADIR%%/afm/pzdr.afm
+%%WITHI18N%%%%DATADIR%%/afm/colle10.afm
+%%WITHI18N%%%%DATADIR%%/afm/colle8.afm
+%%WITHI18N%%%%DATADIR%%/afm/colle9.afm
+%%WITHI18N%%%%DATADIR%%/afm/crr35__i.afm
+%%WITHI18N%%%%DATADIR%%/afm/crr36__i.afm
+%%WITHI18N%%%%DATADIR%%/afm/crr55__i.afm
+%%WITHI18N%%%%DATADIR%%/afm/crr56__i.afm
+%%WITHI18N%%%%DATADIR%%/afm/textb18.afm
+%%WITHI18N%%%%DATADIR%%/afm/textb19.afm
+%%WITHI18N%%%%DATADIR%%/afm/textb20.afm
 %%DATADIR%%/encoding/ascii.edf
 %%DATADIR%%/encoding/encoding.map
 %%DATADIR%%/encoding/hp.edf
@@ -66,6 +76,16 @@
 %%DATADIR%%/encoding/mac.edf
 %%DATADIR%%/encoding/ms-cp1250.edf
 %%DATADIR%%/fonts/pcfont.pfa
+%%WITHI18N%%%%DATADIR%%/fonts/colle10.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/colle8.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/colle9.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/crr35__i.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/crr36__i.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/crr55__i.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/crr56__i.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/textb18.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/textb19.pfb
+%%WITHI18N%%%%DATADIR%%/fonts/textb20.pfb
 %%DATADIR%%/ogonkify/README
 %%DATADIR%%/ogonkify/adobe.enc
 %%DATADIR%%/ogonkify/afm/pcrb-o.afm
How-To-Repeat: 
	The following command fails:

$ a2ps -X koi8-r -o test.ps cyrillic.txt
a2ps: cannot find file `CourierISOC.afm'
Comment 1 Martin Wilke freebsd_committer 2006-12-25 17:34:29 UTC
Responsible Changed
From-To: freebsd-ports-bugs->dinoex

Over to maintainer.
Comment 2 dfilter service freebsd_committer 2006-12-29 18:18:01 UTC
dinoex      2006-12-29 18:17:54 UTC

  FreeBSD ports repository

  Modified files:
    print/a2ps-letter    Makefile distinfo pkg-plist 
  Log:
  - add option WITH_I18N
  PR:             107195
  Submitted by:   Eugene Grosbein
  
  Revision  Changes    Path
  1.63      +23 -0     ports/print/a2ps-letter/Makefile
  1.17      +3 -0      ports/print/a2ps-letter/distinfo
  1.33      +20 -0     ports/print/a2ps-letter/pkg-plist
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 3 Dirk Meyer freebsd_committer 2006-12-29 18:45:21 UTC
State Changed
From-To: open->closed

committed with cosmetic changes, thanks.