diff options
author | SADA Kenji <sada@FreeBSD.org> | 2000-11-03 17:13:12 +0000 |
---|---|---|
committer | SADA Kenji <sada@FreeBSD.org> | 2000-11-03 17:13:12 +0000 |
commit | aa73979692e0f21e8dc4e6f2678f159145bddc77 (patch) | |
tree | 000060935947cf1ea20699d201021c235a622488 /graphics/leafpak | |
parent | 73167ecdd35aeab12c97cd49e2723e95f563d8dc (diff) | |
download | ports-aa73979692e0f21e8dc4e6f2678f159145bddc77.tar.gz ports-aa73979692e0f21e8dc4e6f2678f159145bddc77.zip |
New port - graph/leafpak.
From pkg-descr,
This is LEAF/AQUAPLUS PAK format graphic archive file extracter.
See also /usr/local/share/doc/ja/leafpak/README
PR: ports/22564
Submitted by: TAKAHASHI Kaoru <kaoru@kaisei.org>
Notes
Notes:
svn path=/head/; revision=34765
Diffstat (limited to 'graphics/leafpak')
-rw-r--r-- | graphics/leafpak/Makefile | 25 | ||||
-rw-r--r-- | graphics/leafpak/distinfo | 1 | ||||
-rw-r--r-- | graphics/leafpak/files/patch-aa | 51 | ||||
-rw-r--r-- | graphics/leafpak/files/patch-ab | 39 | ||||
-rw-r--r-- | graphics/leafpak/pkg-comment | 1 | ||||
-rw-r--r-- | graphics/leafpak/pkg-descr | 4 | ||||
-rw-r--r-- | graphics/leafpak/pkg-plist | 4 |
7 files changed, 125 insertions, 0 deletions
diff --git a/graphics/leafpak/Makefile b/graphics/leafpak/Makefile new file mode 100644 index 000000000000..ff53f07f9dc4 --- /dev/null +++ b/graphics/leafpak/Makefile @@ -0,0 +1,25 @@ +# New ports collection makefile for: leafpak +# Date created: 25 Sep 2000 +# Whom: TAKAHASHI Kaoru +# +# $FreeBSD$ +# + +PORTNAME= leafpak +PORTVERSION= 1.1 +CATEGORIES= graphics +MASTER_SITES= http://hoshina.denpa.org/ + +MAINTAINER= kaoru@kaisei.org + +WRKSRC= ${WRKDIR}/${PORTNAME} + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/leafpak ${PREFIX}/bin + ${INSTALL_PROGRAM} ${WRKSRC}/leafpak2 ${PREFIX}/bin +.if !defined(NOPORTDOCS) + ${MKDIR} ${PREFIX}/share/doc/ja/leafpak + ${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/ja/leafpak +.endif + +.include <bsd.port.mk> diff --git a/graphics/leafpak/distinfo b/graphics/leafpak/distinfo new file mode 100644 index 000000000000..b278c84d9154 --- /dev/null +++ b/graphics/leafpak/distinfo @@ -0,0 +1 @@ +MD5 (leafpak-1.1.tar.gz) = c5eb844d2428031274067c825a17619e diff --git a/graphics/leafpak/files/patch-aa b/graphics/leafpak/files/patch-aa new file mode 100644 index 000000000000..1aae5df11319 --- /dev/null +++ b/graphics/leafpak/files/patch-aa @@ -0,0 +1,51 @@ +diff -u leafpak.c.orig leafpak.c +--- leafpak.c.orig Sat Feb 5 23:48:02 2000 ++++ leafpak.c Tue Oct 31 05:34:30 2000 +@@ -94,20 +94,24 @@ + + for (i = 0; i < lp->file_num; i++) { + fp = fopen(lp->name[i], "w"); +- printf("extracting %s...", lp->name[i]); +- fflush(stdout); ++ if (fp == NULL) { ++ printf("Can't write %s. skip\n", lp->name[i]); ++ } else { ++ printf("extracting %s...", lp->name[i]); ++ fflush(stdout); + +- pos = lp->pos[i]; +- fseek(lp->fp, (long)pos, SEEK_SET); +- k = 0; +- while (pos != lp->nextpos[i]) { +- val = (fgetc(lp->fp) - lp->key[k]) & 0xff; +- k = (++k) % KEY_LEN; +- fputc(val, fp); +- pos++; ++ pos = lp->pos[i]; ++ fseek(lp->fp, (long)pos, SEEK_SET); ++ k = 0; ++ while (pos != lp->nextpos[i]) { ++ val = (fgetc(lp->fp) - lp->key[k]) & 0xff; ++ k = (++k) % KEY_LEN; ++ fputc(val, fp); ++ pos++; ++ } ++ fclose(fp); ++ printf("done.\n"); + } +- fclose(fp); +- printf("done.\n"); + } + printf("\nAll files are extracted.\n"); + } +@@ -139,6 +143,10 @@ + fflush(stdout); + + fp = fopen(file, "w"); ++ if ( fp == NULL ) { ++ printf("Can't write %s.\n", file); ++ return -1; ++ } + pos = lp->pos[i]; + fseek(lp->fp, (long)pos, SEEK_SET); + while (pos != lp->nextpos[i]) { diff --git a/graphics/leafpak/files/patch-ab b/graphics/leafpak/files/patch-ab new file mode 100644 index 000000000000..2b1920f71b81 --- /dev/null +++ b/graphics/leafpak/files/patch-ab @@ -0,0 +1,39 @@ +diff -u leafpak2.c.orig leafpak2.c +--- leafpak2.c.orig Sat Feb 5 23:47:49 2000 ++++ leafpak2.c Tue Oct 31 05:41:13 2000 +@@ -236,14 +236,18 @@ + fflush(stdout); + + fp = fopen(lp->name[i], "w"); +- fseek(lp->fp, (long)lp->position[i], SEEK_SET); ++ if (fp == NULL) { ++ printf("Can't write %s\n",lp->name[i]); ++ } else { ++ fseek(lp->fp, (long)lp->position[i], SEEK_SET); + +- for (j = 0; j < lp->length[i]; j++) { +- fputc(fgetc(lp->fp), fp); +- } ++ for (j = 0; j < lp->length[i]; j++) { ++ fputc(fgetc(lp->fp), fp); ++ } + +- fclose(fp); +- printf("done.\n"); ++ fclose(fp); ++ printf("done.\n"); ++ } + } + + #ifdef DEBUG +@@ -275,6 +279,10 @@ + fflush(stdout); + + fp = fopen(filename, "w"); ++ if (fp == NULL) { ++ printf("Can't write %s.\n", filename); ++ return 1; ++ } + fseek(lp->fp, (long)lp->position[i], SEEK_SET); + + for (j = 0; j < lp->length[i]; j++) { diff --git a/graphics/leafpak/pkg-comment b/graphics/leafpak/pkg-comment new file mode 100644 index 000000000000..446a0a4cdc3e --- /dev/null +++ b/graphics/leafpak/pkg-comment @@ -0,0 +1 @@ +Graphic file cutter for LEAF/AQUAPLUS PAK format archives diff --git a/graphics/leafpak/pkg-descr b/graphics/leafpak/pkg-descr new file mode 100644 index 000000000000..1437be4b39ec --- /dev/null +++ b/graphics/leafpak/pkg-descr @@ -0,0 +1,4 @@ +This is LEAF/AQUAPLUS PAK format graphic archive file extracter. +See also /usr/local/share/doc/ja/leafpak/README + +WWW: http://hoshina.denpa.org/leafpak.html diff --git a/graphics/leafpak/pkg-plist b/graphics/leafpak/pkg-plist new file mode 100644 index 000000000000..c7c994cbd6a0 --- /dev/null +++ b/graphics/leafpak/pkg-plist @@ -0,0 +1,4 @@ +bin/leafpak +bin/leafpak2 +share/doc/ja/leafpak/README +@dirrm share/doc/ja/leafpak |