Update to ish-2.01a5, including a fix for a Y2K problem in status display and

64-bit fixes for multi-volume format. From SASANO Takayoshi.

Make a few minor changes while there: Honour CC flag, and use a do-install:
target rather than upstream's makefile which always strips the binaries,
even when DEBUG is set.
This commit is contained in:
sthen 2011-12-30 23:14:34 +00:00
parent 2a78f6f07d
commit 5752b2e7bb
7 changed files with 67 additions and 24 deletions

View File

@ -1,24 +1,29 @@
# $OpenBSD: Makefile,v 1.18 2007/09/16 01:40:27 merdely Exp $
# $OpenBSD: Makefile,v 1.19 2011/12/30 23:14:34 sthen Exp $
COMMENT= binary-to-text file converter
DISTNAME= ish-1.11
DISTNAME= ish201a5
PKGNAME= ish-2.01a5
CATEGORIES= converters
PERMIT_PACKAGE_CDROM= no license
PERMIT_PACKAGE_FTP= no license
PERMIT_DISTFILES_CDROM= no license
PERMIT_DISTFILES_FTP= no license
WANTLIB= c
WANTLIB += c
MASTER_SITES= \
ftp://ports.jp.FreeBSD.org/pub/FreeBSD-jp/ports-jp/LOCAL_PORTS/ \
ftp://ftp4.jp.FreeBSD.org/pub/FreeBSD-jp/ports-jp/LOCAL_PORTS/ \
ftp://ftp.ics.es.osaka-u.ac.jp/pub/mirrors/FreeBSD-jp/ports-jp/LOCAL_PORTS/
http://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/ \
ftp://ftp.jp.freebsd.org/pub/FreeBSD/ports/distfiles/ \
http://www.unix.gr.jp/jnetcex/soft/
MAKE_FILE= makefile
MAKE_FLAGS= CFLAGS="${CFLAGS}"
ALL_TARGET= ish
MAKE_FLAGS= CFLAGS="${CFLAGS}" CC="${CC}"
ALL_TARGET= ish dispish
NO_REGRESS= Yes
do-install:
cd ${WRKSRC}; ${INSTALL_PROGRAM} ish dispish ${PREFIX}/bin
.include <bsd.port.mk>

View File

@ -1,5 +1,5 @@
MD5 (ish-1.11.tar.gz) = ByuJT9QBTp8G6mx49qTyUg==
RMD160 (ish-1.11.tar.gz) = s/1n+f9XmoZcJp8Lptt3BgAw/Jc=
SHA1 (ish-1.11.tar.gz) = mcGCxoUhAXlCjUTPGoDZZ2bPPT4=
SHA256 (ish-1.11.tar.gz) = rF7qE6m7f5rbW6UWGIGxWdJ/gJZ7vPDlIZPFwZFrFd8=
SIZE (ish-1.11.tar.gz) = 13029
MD5 (ish201a5.tar.gz) = rhtix3d9F7bWShwbBW2BFA==
RMD160 (ish201a5.tar.gz) = EY6Cg/sx0Mzf6m59xU+IcSd+8i4=
SHA1 (ish201a5.tar.gz) = I7/ZggOqgni8uQ4c58GQNrUkYsg=
SHA256 (ish201a5.tar.gz) = tigowYxFZL9qk6DCEQYDV8PStfC2d3pSw5nBD02TkG0=
SIZE (ish201a5.tar.gz) = 25803

View File

@ -0,0 +1,14 @@
$OpenBSD: patch-crc32_c,v 1.1 2011/12/30 23:14:34 sthen Exp $
Fix: Multi-volume format cannot handle on 64bit environment.
--- crc32.c.orig Wed Apr 20 06:23:00 1994
+++ crc32.c Fri Dec 30 23:09:44 2011
@@ -78,6 +78,7 @@ unsigned char *arg;
int len;
unsigned long crc;
{
+ crc &= 0xffffffffU;
while(--len >= 0) {
crc = crc >> 8 ^ crctbl[(crc & 0xff) ^ *arg++];
}

View File

@ -0,0 +1,17 @@
$OpenBSD: patch-decode_c,v 1.1 2011/12/30 23:14:34 sthen Exp $
Fix: When decoding, the status display has Y2K problem.
--- decode.c.orig Sun Jan 7 10:46:37 1996
+++ decode.c Fri Dec 30 23:09:44 2011
@@ -273,8 +273,8 @@ ish_head *head;
tm.tm_min = (p[1]&0x07)<<3;
tm.tm_min += p[0]>>5;
tm.tm_sec = (p[0]&0x1f)<<1;
- fprintf(stderr,"%02d/%02d/%02d %02d:%02d:%02d ",
- tm.tm_year,tm.tm_mon+1,tm.tm_mday,tm.tm_hour,tm.tm_min,tm.tm_sec);
+ fprintf(stderr,"%04d/%02d/%02d %02d:%02d:%02d ",
+ tm.tm_year+1900,tm.tm_mon+1,tm.tm_mday,tm.tm_hour,tm.tm_min,tm.tm_sec);
#ifdef __TURBOC__
memcpy( &timep[0], head->time, 4);
timep[1] = timep[0];

View File

@ -1,9 +0,0 @@
$OpenBSD: patch-makefile,v 1.1 2007/10/26 20:39:26 ajacoutot Exp $
--- makefile.orig Sun Aug 5 13:04:08 1990
+++ makefile Fri Oct 26 22:35:41 2007
@@ -1,4 +1,4 @@
-DEST = .
+DEST = $(PREFIX)/bin
#CFLAGS = -O -DSysV
CFLAGS = -O
LDFLAGS = -s

View File

@ -0,0 +1,15 @@
$OpenBSD: patch-mvol_c,v 1.1 2011/12/30 23:14:34 sthen Exp $
Fix: Multi-volume format cannot handle on 64bit environment.
--- mvol.c.orig Sun Jan 7 10:47:17 1996
+++ mvol.c Fri Dec 30 23:09:44 2011
@@ -248,7 +248,7 @@ unsigned char *p;
}
close(id);
close(od);
- crc32 = ~crc32;
+ crc32 = ~crc32 & 0xffffffffU;
crc16 = ~crc16;
if (crc32 == ncrc32 && crc16 == ncrc16) {
/* checksum OK */

View File

@ -1,2 +1,3 @@
@comment $OpenBSD: PLIST,v 1.2 2002/04/07 01:54:48 naddy Exp $
bin/ish
@comment $OpenBSD: PLIST,v 1.3 2011/12/30 23:14:34 sthen Exp $
@bin bin/dispish
@bin bin/ish