diff options
author | TAKATSU Tomonari <tota@FreeBSD.org> | 2011-09-19 13:58:11 +0000 |
---|---|---|
committer | TAKATSU Tomonari <tota@FreeBSD.org> | 2011-09-19 13:58:11 +0000 |
commit | 822f5c625e6fb4cd036a01c58a429a418e47f322 (patch) | |
tree | 508e4206b532d626c18321c66246340a6c3656c2 /japanese | |
parent | f36fbeeed21e970d9c9d4b5fadf649dc9969a9b2 (diff) | |
download | ports-822f5c625e6fb4cd036a01c58a429a418e47f322.tar.gz ports-822f5c625e6fb4cd036a01c58a429a418e47f322.zip |
Notes
Diffstat (limited to 'japanese')
-rw-r--r-- | japanese/a2ps/Makefile | 11 | ||||
-rw-r--r-- | japanese/a2ps/files/patch-aa | 57 |
2 files changed, 60 insertions, 8 deletions
diff --git a/japanese/a2ps/Makefile b/japanese/a2ps/Makefile index 26a6d58b81b7..85e0e98ceab3 100644 --- a/japanese/a2ps/Makefile +++ b/japanese/a2ps/Makefile @@ -7,21 +7,20 @@ PORTNAME= a2ps PORTVERSION= 1.45 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= japanese print MASTER_SITES= ftp://ftp.sra.co.jp/pub/lang/perl/sra-scripts/ \ - ${MASTER_SITE_LOCAL} -MASTER_SITE_SUBDIR= nork + ${MASTER_SITE_LOCAL:S|%SUBDIR%|tota/a2ps|} DISTNAME= ${PORTNAME}.pl-${PORTVERSION} -EXTRACT_SUFX= +EXTRACT_SUFX= # empty MAINTAINER= ports@FreeBSD.org COMMENT= Text file to postscript converter (with Japanese support) PLIST_FILES= bin/a2ps-j EXTRACT_CMD= ${CP} -EXTRACT_BEFORE_ARGS= -EXTRACT_AFTER_ARGS= ./a2ps-j +EXTRACT_BEFORE_ARGS= # empty +EXTRACT_AFTER_ARGS= a2ps-j NO_WRKSUBDIR= yes NO_BUILD= yes diff --git a/japanese/a2ps/files/patch-aa b/japanese/a2ps/files/patch-aa index b91bd3111d26..f153be5be209 100644 --- a/japanese/a2ps/files/patch-aa +++ b/japanese/a2ps/files/patch-aa @@ -1,5 +1,5 @@ ---- a2ps-j.orig 2010-05-10 01:15:32.227559000 +0900 -+++ a2ps-j 2010-05-10 01:18:27.223595925 +0900 +--- a2ps-j.orig 2011-09-19 17:05:32.000000000 +0900 ++++ a2ps-j 2011-09-19 17:09:07.000000000 +0900 @@ -1,4 +1,4 @@ -#!/usr/local/bin/perl +#!/usr/bin/perl @@ -16,3 +16,56 @@ &dumpvar('main', 'width', 'height', 'lmargin', 'smargin', 'font_size', 'sheet_height', 'sheet_width', 'char_width', 'skip_column', +@@ -208,8 +209,14 @@ + $file = shift; + if ($file && !-r $file) { warn "$file: $!\n"; next; } + if ($jisconvert) { +- require 'flush.pl'; +- &flush(STDOUT); ++ # flush.pl obsolete (originally in Perl 4) ++ # replaced with equivalent code of &flush(STDOUT) ++ local($old_stdout) = select(STDOUT); ++ $| = 1; ++ print ""; ++ $| = 0; ++ select($old_stdout); ++ # end of equivalent code + open(F, "-|") || &jis($file); + } else { + $file = '-' if $file eq ''; +@@ -476,10 +483,13 @@ + } + + sub print_header { +- require('ctime.pl'); + return if $header_is_printed++; + +- chop(local($date) = &ctime(time)); ++ # ctime.pl obsolete (originally in Perl 4) ++ # ctime.pl behaves differently when TZ is not set, ++ # but the behavior will not affect the PostScript file details ++ local($date) = scalar localtime; ++ + local($orientation) = $portrait ? "Portrait" : "Landscape"; + + print <<"---"; +@@ -525,7 +535,8 @@ + printf("/lines %d def\n", $linesperpage); + printf("/columns %d def\n", $columnsperline); + $sublabel = $default_sublabel unless defined $sublabel; +- print "/date (", &date($sublabel, time), ") def\n"; ++ # function name changed to a2ps_date to avoid confusion ++ print "/date (", &a2ps_date($sublabel, time), ") def\n"; + if ($ascii_mag) { + printf("/doasciimag true def /asciimagsize %f def\n", $ascii_mag); + } else { +@@ -548,7 +559,8 @@ + print "%%EndProlog\n\n"; + } + +-sub date { ++# function name changed to a2ps_date to avoid confusion ++sub a2ps_date { + local($_, $time) = @_; + local($sec, $min, $hour, $mday, $mon, $year, $wday) = localtime($time); + $year += 1900; |