pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/graphics/fujiplay Fix CPP hacks with strings containin...
details: https://anonhg.NetBSD.org/pkgsrc/rev/d1849be97ac5
branches: trunk
changeset: 475839:d1849be97ac5
user: hubertf <hubertf%pkgsrc.org@localhost>
date: Thu May 27 22:20:00 2004 +0000
description:
Fix CPP hacks with strings containing linebreaks.
Very ugly hack (post-patch) to work around a RCS ID in area needing patch.
diffstat:
graphics/fujiplay/Makefile | 10 ++++-
graphics/fujiplay/distinfo | 4 +-
graphics/fujiplay/patches/patch-aa | 79 +++++++++++++++++++++++++++++++++++--
3 files changed, 84 insertions(+), 9 deletions(-)
diffs (125 lines):
diff -r f6e8d7becb58 -r d1849be97ac5 graphics/fujiplay/Makefile
--- a/graphics/fujiplay/Makefile Thu May 27 21:59:56 2004 +0000
+++ b/graphics/fujiplay/Makefile Thu May 27 22:20:00 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.6 2004/01/20 12:18:15 agc Exp $
+# $NetBSD: Makefile,v 1.7 2004/05/27 22:20:00 hubertf Exp $
#
DISTNAME= fujiplay
@@ -14,6 +14,14 @@
DIST_SUBDIR= fujiplay-1.33
WRKSRC= ${WRKDIR}
+post-patch:
+ cd ${WRKSRC} ; ${MV} fujiplay.c fujiplay.c.orig2 ; \
+ ${SED} \
+ -e '791,794s/^/"/g' \
+ -e '791,793s/$$/\\n"/' \
+ -e '790,790s/".*$$//' \
+ <fujiplay.c.orig2 >fujiplay.c
+
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/fujiplay ${PREFIX}/bin
${INSTALL_PROGRAM} ${WRKSRC}/yycc2ppm ${PREFIX}/bin
diff -r f6e8d7becb58 -r d1849be97ac5 graphics/fujiplay/distinfo
--- a/graphics/fujiplay/distinfo Thu May 27 21:59:56 2004 +0000
+++ b/graphics/fujiplay/distinfo Thu May 27 22:20:00 2004 +0000
@@ -1,5 +1,5 @@
-$NetBSD: distinfo,v 1.2 2001/04/21 09:54:11 wiz Exp $
+$NetBSD: distinfo,v 1.3 2004/05/27 22:20:00 hubertf Exp $
SHA1 (fujiplay-1.33/fujiplay.tgz) = 6a2a42a87bb78d5eeeb040afb72636aa0aed692c
Size (fujiplay-1.33/fujiplay.tgz) = 12588 bytes
-SHA1 (patch-aa) = 2764f3752c620d66368c1adaba3a1ccbcb084c6f
+SHA1 (patch-aa) = 7b5c2ed2393cae5a470bd063486460919ec0ada9
diff -r f6e8d7becb58 -r d1849be97ac5 graphics/fujiplay/patches/patch-aa
--- a/graphics/fujiplay/patches/patch-aa Thu May 27 21:59:56 2004 +0000
+++ b/graphics/fujiplay/patches/patch-aa Thu May 27 22:20:00 2004 +0000
@@ -1,13 +1,80 @@
-$NetBSD: patch-aa,v 1.1.1.1 1999/11/23 04:22:13 hubertf Exp $
+$NetBSD: patch-aa,v 1.2 2004/05/27 22:20:00 hubertf Exp $
---- fujiplay.c.orig Tue Nov 23 04:55:05 1999
-+++ fujiplay.c Tue Nov 23 04:58:42 1999
-@@ -35,7 +35,7 @@
- #define B115200 EXTB
+--- fujiplay.c.orig 1999-02-23 10:30:31.000000000 +0100
++++ fujiplay.c
+@@ -36,5 +36,5 @@
#endif
-#define DEFAULT_DEVICE "/dev/fujifilm"
+#define DEFAULT_DEVICE "/dev/tty00"
#define TMP_PIC_FILE ".dsc_temp"
- struct pict_info {
+@@ -633,6 +633,6 @@ void download_picture(int n)
+ t2 = times(&stms);
+ if (t1==t2) t2++; /* paranoia */
+- printf("%3d seconds, ", (int)(t2-t1) / CLK_TCK);
+- printf("%4d bytes/s\n", size * CLK_TCK / (int)(t2-t1));
++ printf("%3d seconds, ", (int)((t2-t1) / CLK_TCK));
++ printf("%4d bytes/s\n", (int)(size * CLK_TCK / (int)(t2-t1)));
+ fclose(fd);
+ if (stat(TMP_PIC_FILE, &st) < 0 || st.st_size != size) {
+@@ -760,32 +760,31 @@ again:
+ }
+
+-const char *Usage = "\
+-Usage: fujiplay [OPTIONS] PICTURES... (download)
+- charge NUMBER (recharge the flash)
+- shoot (take picture)
+- preview (preview to standard output)
+- upload FILES...
+- delete FILES...
+- setid STRING (set camera ID)
+- setflash MODE (0=Off, 1=On, 2=Strobe, 3=Auto)
+- setdate gmt|local|YYYYMMDDHHMMSS
+-Options:
+- -B NUMBER Set baudrate (115200, 57600, 38400, 19200, 9600 or 0)
+- -D DEVICE Select another device file (default is /dev/fujifilm)
+- -L List command set
+- -7 DS-7 compatibility mode (experimental)
+- -d Delete pictures after successful download
+- -f Force (overwrite existing files)
+- -p Assume picture numbers instead of frame numbers
+- -h Display this help message
+- -v Version information
+-Pictures:
+- all All pictures
+- last Last picture
+- 4 Only picture 4
+- 2-10 Pictures between 2 and 10
+-Files:
+- DSCxxxxx.JPG Files to delete or to upload into the camera
+-";
++const char *Usage =
++"Usage: fujiplay [OPTIONS] PICTURES... (download)\n"
++" charge NUMBER (recharge the flash)\n"
++" shoot (take picture)\n"
++" preview (preview to standard output)\n"
++" upload FILES...\n"
++" delete FILES...\n"
++" setid STRING (set camera ID)\n"
++" setflash MODE (0=Off, 1=On, 2=Strobe, 3=Auto)\n"
++" setdate gmt|local|YYYYMMDDHHMMSS\n"
++"Options:\n"
++" -B NUMBER Set baudrate (115200, 57600, 38400, 19200, 9600 or 0)\n"
++" -D DEVICE Select another device file (default is /dev/fujifilm)\n"
++" -L List command set\n"
++" -7 DS-7 compatibility mode (experimental)\n"
++" -d Delete pictures after successful download\n"
++" -f Force (overwrite existing files)\n"
++" -p Assume picture numbers instead of frame numbers\n"
++" -h Display this help message\n"
++" -v Version information\n"
++"Pictures:\n"
++" all All pictures\n"
++" last Last picture\n"
++" 4 Only picture 4\n"
++" 2-10 Pictures between 2 and 10\n"
++"Files:\n"
++" DSCxxxxx.JPG Files to delete or to upload into the camera\n";
+
+ const char *Copyright = "\
Home |
Main Index |
Thread Index |
Old Index