diff options
author | marino <marino> | 2012-07-18 23:23:20 +0000 |
---|---|---|
committer | marino <marino> | 2012-07-18 23:23:20 +0000 |
commit | baed710a14323a6634d5be9e173cb22403bf7994 (patch) | |
tree | db14063894f55edee85f522fdaa3bed9cfbe69cf /emulators | |
parent | 70a9f74497d895202a3d3f01225cd4cf371d15b5 (diff) | |
download | pkgsrc-baed710a14323a6634d5be9e173cb22403bf7994.tar.gz |
emulators/fmsx: Fix for libz >= 1.2.6
The current package won't compile if using libz >= 1.2.6 due to a typedef
change of GzFile. Luckily this packages used macros for gz* functions
which significantly cut down the number of lines to be patched.
Diffstat (limited to 'emulators')
-rw-r--r-- | emulators/fmsx/Makefile | 3 | ||||
-rw-r--r-- | emulators/fmsx/distinfo | 5 | ||||
-rw-r--r-- | emulators/fmsx/patches/patch-EMULIB_FDIDisk.c | 27 | ||||
-rw-r--r-- | emulators/fmsx/patches/patch-EMULIB_Floppy.c | 32 | ||||
-rw-r--r-- | emulators/fmsx/patches/patch-fMSX_MSX.c | 29 |
5 files changed, 94 insertions, 2 deletions
diff --git a/emulators/fmsx/Makefile b/emulators/fmsx/Makefile index 9a62cbfed06..852482b040e 100644 --- a/emulators/fmsx/Makefile +++ b/emulators/fmsx/Makefile @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.26 2010/01/07 08:38:43 obache Exp $ +# $NetBSD: Makefile,v 1.27 2012/07/18 23:23:20 marino Exp $ DISTNAME= fMSX351 PKGNAME= fmsx-3.5.1 +PKGREVISION= 1 CATEGORIES= emulators x11 MASTER_SITES= http://fms.komkon.org/fMSX/ EXTRACT_SUFX= .zip diff --git a/emulators/fmsx/distinfo b/emulators/fmsx/distinfo index b49475130b7..3bc79a85af5 100644 --- a/emulators/fmsx/distinfo +++ b/emulators/fmsx/distinfo @@ -1,11 +1,14 @@ -$NetBSD: distinfo,v 1.6 2010/01/07 08:38:43 obache Exp $ +$NetBSD: distinfo,v 1.7 2012/07/18 23:23:20 marino Exp $ SHA1 (fMSX351.zip) = d28d2bf3bc2a1ae273899c80bbbe9bdf4dd98767 RMD160 (fMSX351.zip) = be16d466f5ff29265d0faebd186a701a96ba81f6 Size (fMSX351.zip) = 515112 bytes +SHA1 (patch-EMULIB_FDIDisk.c) = d74b7d5d1217297cfa54a1085f85ae4a3db9b635 +SHA1 (patch-EMULIB_Floppy.c) = 4b8874cac9c58839bbb107bf8cb8c59915873cac SHA1 (patch-aa) = 80191e7d1ff6b36cc1cf97174162e179d743b149 SHA1 (patch-ab) = 7bff0051685efd22e678c66ffa4075830143e6d6 SHA1 (patch-ae) = 7168f963dac8686200119b297af3bcf8f8203c4c SHA1 (patch-af) = df2dd22ae51558497e1691a13cfaf4556562f483 SHA1 (patch-ag) = 2a1f29485ffe0d51eeaf093de434e9a49a4b8f48 SHA1 (patch-ah) = eb44189e26a485b9bc50462127b7b74b8d161734 +SHA1 (patch-fMSX_MSX.c) = ac35bfcad37954234d60a61c28208d5c9b77089b diff --git a/emulators/fmsx/patches/patch-EMULIB_FDIDisk.c b/emulators/fmsx/patches/patch-EMULIB_FDIDisk.c new file mode 100644 index 00000000000..e2326f2c283 --- /dev/null +++ b/emulators/fmsx/patches/patch-EMULIB_FDIDisk.c @@ -0,0 +1,27 @@ +$NetBSD: patch-EMULIB_FDIDisk.c,v 1.1 2012/07/18 23:23:21 marino Exp $ + +Make compatible with libz >= 1.2.6 + +--- EMULib/FDIDisk.c.orig 2007-12-30 15:59:36.000000000 +0000 ++++ EMULib/FDIDisk.c +@@ -178,13 +178,13 @@ byte *NewFDI(FDIDisk *D,int Sides,int Tr + } + + #ifdef ZLIB +-#define fopen gzopen +-#define fclose gzclose +-#define fread(B,L,N,F) gzread(F,B,(L)*(N)) +-#define fwrite(B,L,N,F) gzwrite(F,B,(L)*(N)) +-#define fseek gzseek +-#define rewind gzrewind +-#define ftell gztell ++#define fopen(F,M) gzopen(F,M) ++#define fclose(F) gzclose((gzFile)F) ++#define fread(B,L,N,F) gzread((gzFile)F,B,(L)*(N)) ++#define fwrite(B,L,N,F) gzwrite((gzFile)F,B,(L)*(N)) ++#define fseek(F,L,W) gzseek((gzFile)F,L,W) ++#define rewind(F) gzrewind((gzFile)F) ++#define ftell(F) gztell((gzFile)F) + #endif + + /** LoadFDI() ************************************************/ diff --git a/emulators/fmsx/patches/patch-EMULIB_Floppy.c b/emulators/fmsx/patches/patch-EMULIB_Floppy.c new file mode 100644 index 00000000000..e62f4f0e0f7 --- /dev/null +++ b/emulators/fmsx/patches/patch-EMULIB_Floppy.c @@ -0,0 +1,32 @@ +$NetBSD: patch-EMULIB_Floppy.c,v 1.1 2012/07/18 23:23:21 marino Exp $ + +Make compatible with libz >= 1.2.6 + +--- EMULib/Floppy.c.orig 2007-12-30 15:59:58.000000000 +0000 ++++ EMULib/Floppy.c +@@ -436,9 +436,9 @@ byte *DSKLoad(const char *Name,byte *Dsk + } + + #ifdef ZLIB +-#define fopen gzopen +-#define fclose gzclose +-#define fread(B,L,N,F) gzread(F,B,(L)*(N)) ++#define fopen(F,M) gzopen(F,M) ++#define fclose(F) gzclose((gzFile)F) ++#define fread(B,L,N,F) gzread((gzFile)F,B,(L)*(N)) + #endif + + /* Assume <Name> to be a disk image file */ +@@ -504,9 +504,9 @@ const byte *DSKSave(const char *Name,con + } + + #ifdef ZLIB +-#define fopen gzopen +-#define fclose gzclose +-#define fwrite(B,L,N,F) gzwrite(F,(byte *)B,(L)*(N)) ++#define fopen(F,M) gzopen(F,M) ++#define fclose(F) gzclose((gzFile)F) ++#define fwrite(B,L,N,F) gzwrite((gzFile)F,(byte *)B,(L)*(N)) + #endif + + /* Assume <Name> to be a disk image file */ diff --git a/emulators/fmsx/patches/patch-fMSX_MSX.c b/emulators/fmsx/patches/patch-fMSX_MSX.c new file mode 100644 index 00000000000..0adab2fed6a --- /dev/null +++ b/emulators/fmsx/patches/patch-fMSX_MSX.c @@ -0,0 +1,29 @@ +$NetBSD: patch-fMSX_MSX.c,v 1.1 2012/07/18 23:23:21 marino Exp $ + +Make compatible with libz >= 1.2.6 + +--- fMSX/MSX.c.orig 2008-01-29 22:32:53.000000000 +0000 ++++ fMSX/MSX.c +@@ -2440,14 +2440,14 @@ int LoadFile(const char *FileName) + } + + #ifdef ZLIB +-#define fopen gzopen +-#define fclose gzclose +-#define fread(B,L,N,F) gzread(F,B,(L)*(N)) +-#define fwrite(B,L,N,F) gzwrite(F,B,(L)*(N)) +-#define fseek gzseek +-#define rewind gzrewind +-#define fgetc gzgetc +-#define ftell gztell ++#define fopen(F,M) gzopen(F,M) ++#define fclose(F) gzclose((gzFile)F) ++#define fread(B,L,N,F) gzread((gzFile)F,B,(L)*(N)) ++#define fwrite(B,L,N,F) gzwrite((gzFile)F,B,(L)*(N)) ++#define fseek(F,L,W) gzseek((gzFile)F,L,W) ++#define rewind(F) gzrewind((gzFile)F) ++#define fgetc(F) gzgetc((gzFile)F) ++#define ftell(F) gztell((gzFile)F) + #endif + + /** LoadFNT() ************************************************/ |