summaryrefslogtreecommitdiff
path: root/games/abuse
diff options
context:
space:
mode:
authoragc <agc@pkgsrc.org>2002-07-16 14:26:20 +0000
committeragc <agc@pkgsrc.org>2002-07-16 14:26:20 +0000
commitb250653f67b8a73afafe0136a40f99c60187fcfa (patch)
tree6efc26c474302883c5e78707767a59f46de45a89 /games/abuse
parent6d1ea974ffe5c8435f27d35e55d5d3c66f214108 (diff)
downloadpkgsrc-b250653f67b8a73afafe0136a40f99c60187fcfa.tar.gz
At least let this package compile...
Diffstat (limited to 'games/abuse')
-rw-r--r--games/abuse/distinfo8
-rw-r--r--games/abuse/patches/patch-ag41
-rw-r--r--games/abuse/patches/patch-ah26
-rw-r--r--games/abuse/patches/patch-ai35
-rw-r--r--games/abuse/patches/patch-aj22
-rw-r--r--games/abuse/patches/patch-ak24
-rw-r--r--games/abuse/patches/patch-al13
7 files changed, 168 insertions, 1 deletions
diff --git a/games/abuse/distinfo b/games/abuse/distinfo
index 637a77ea947..7287b74cd84 100644
--- a/games/abuse/distinfo
+++ b/games/abuse/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.3 2001/07/02 15:30:59 abs Exp $
+$NetBSD: distinfo,v 1.4 2002/07/16 14:26:20 agc Exp $
SHA1 (abuse_pd.tgz) = 52a703abea31d6f00937d4cc0160af7a454e6630
Size (abuse_pd.tgz) = 2525552 bytes
@@ -10,3 +10,9 @@ SHA1 (patch-ac) = b30031db9a89d7bf7c025674e549b08d637a89ff
SHA1 (patch-ad) = 9003fe5ddd04be69c1d40b96ba995f453429ccb8
SHA1 (patch-ae) = 3720352c2b73ed62e943d3c271a8e6c1f7f896d1
SHA1 (patch-af) = 0558623285241b78372a4088e61844aa7ece7649
+SHA1 (patch-ag) = 7c3b32799059805e054399c7e5c7edb8da66be45
+SHA1 (patch-ah) = 67bbbeff32c5ece603cabee270c6242b8ccef676
+SHA1 (patch-ai) = 89dc9e69fd151623c4743338356b94ee3f09dee0
+SHA1 (patch-aj) = e23fb30a64303de78ba708ce1d35adbdd6bd01ee
+SHA1 (patch-ak) = 93b3a07045bd00e3f4e0515526513fd057a0b048
+SHA1 (patch-al) = 657bb4544d5cabd8df3c2af1943bc72a855566f3
diff --git a/games/abuse/patches/patch-ag b/games/abuse/patches/patch-ag
new file mode 100644
index 00000000000..9ce075c0298
--- /dev/null
+++ b/games/abuse/patches/patch-ag
@@ -0,0 +1,41 @@
+$NetBSD: patch-ag,v 1.1 2002/07/16 14:26:20 agc Exp $
+
+--- imlib/readwav.c 2002/07/16 13:34:29 1.1
++++ imlib/readwav.c 2002/07/16 13:34:58
+@@ -71,6 +71,10 @@
+ wav_tag tag;
+ pcm_wave pcm;
+
++ char *riff = "RIFF";
++ char *wave = "WAVE";
++ char *fmt = "fmt ";
++ char *d = "data";
+
+ bFILE *fp=open_file(filename,"wb");
+ if (fp->open_failure())
+@@ -81,13 +85,13 @@
+ }
+
+ /*************** Write the chunk ***************************/
+- fp->write("RIFF",4);
++ fp->write(riff,4);
+ fp->write_long(data_size+36);
+- fp->write("WAVE",4);
++ fp->write(wave,4);
+
+
+ /************** Write the tag *******************************/
+- fp->write("fmt ",4);
++ fp->write(fmt,4);
+ fp->write_long(16);
+
+
+@@ -100,7 +104,7 @@
+ fp->write_short(8); // 8 bits per sample
+
+ /************* Write data tag ******************************/
+- fp->write("data",4);
++ fp->write(d,4);
+ fp->write_long(data_size);
+
+ /************ Now write sample data ************************/
diff --git a/games/abuse/patches/patch-ah b/games/abuse/patches/patch-ah
new file mode 100644
index 00000000000..bee401a9d94
--- /dev/null
+++ b/games/abuse/patches/patch-ah
@@ -0,0 +1,26 @@
+$NetBSD: patch-ah,v 1.1 2002/07/16 14:26:20 agc Exp $
+
+--- imlib/port/unix/jnet.c 2002/07/16 13:49:13 1.1
++++ imlib/port/unix/jnet.c 2002/07/16 13:53:23
+@@ -30,6 +30,12 @@
+ #include "macs.hpp"
+ #include "jmalloc.hpp"
+
++#if defined(__NetBSD__)
++#define SOCKLEN_TYPE __socklen_t
++#else
++#define SOCKLEN_TYPE int
++#endif
++
+ int net_init(int protocol)
+ {
+ if (protocol==TCPIP_PROTOCOL) // UNIX always has TCPIP!
+@@ -146,7 +152,7 @@
+
+ if (FD_ISSET(fd,&set))
+ {
+- int len=sizeof(sockaddr_in);
++ SOCKLEN_TYPE len=sizeof(sockaddr_in);
+ int new_fd=accept(fd, (struct sockaddr *) &host, &len);
+ if (new_fd<0)
+ {
diff --git a/games/abuse/patches/patch-ai b/games/abuse/patches/patch-ai
new file mode 100644
index 00000000000..14cce8b0406
--- /dev/null
+++ b/games/abuse/patches/patch-ai
@@ -0,0 +1,35 @@
+$NetBSD: patch-ai,v 1.1 2002/07/16 14:26:20 agc Exp $
+
+--- abuse/src/net/mac/tcpip.hpp 2002/07/16 13:57:41 1.1
++++ abuse/src/net/mac/tcpip.hpp 2002/07/16 13:59:05
+@@ -146,6 +146,12 @@
+ void broadcastable();
+ } ;
+
++#if defined(__NetBSD__)
++#define SOCKLEN_TYPE __socklen_t
++#else
++#define SOCKLEN_TYPE int
++#endif
++
+ class tcp_socket : public unix_fd
+ {
+ int listening;
+@@ -176,7 +182,7 @@
+ if (listening)
+ {
+ struct sockaddr_in from;
+- int addr_len=sizeof(from);
++ SOCKLEN_TYPE addr_len=sizeof(from);
+ int new_fd=::accept(fd,(sockaddr *)&from,&addr_len);
+ if (new_fd>=0)
+ {
+@@ -200,7 +206,7 @@
+ if (addr)
+ {
+ *addr=new ip_address;
+- int addr_size=sizeof(sockaddr_in);
++ SOCKLEN_TYPE addr_size=sizeof(sockaddr_in);
+ tr=recvfrom(fd,buf,size,0, (sockaddr *) &((ip_address *)(*addr))->addr,&addr_size);
+ } else
+ tr=recv(fd,buf,size,0);
diff --git a/games/abuse/patches/patch-aj b/games/abuse/patches/patch-aj
new file mode 100644
index 00000000000..0ac3512b449
--- /dev/null
+++ b/games/abuse/patches/patch-aj
@@ -0,0 +1,22 @@
+$NetBSD: patch-aj,v 1.1 2002/07/16 14:26:21 agc Exp $
+
+--- abuse/src/demo.c 2002/07/16 14:01:47 1.1
++++ abuse/src/demo.c 2002/07/16 14:02:40
+@@ -51,6 +51,8 @@
+
+ int demo_manager::start_recording(char *filename)
+ {
++ char *msg1 = "DEMO,VERSION:2";
++
+ if (!current_level) return 0;
+
+ record_file=open_file(filename,"wb");
+@@ -60,7 +62,7 @@
+ strcpy(name,current_level->name());
+
+ the_game->load_level(name);
+- record_file->write("DEMO,VERSION:2",14);
++ record_file->write(msg1,14);
+ record_file->write_byte(strlen(name)+1);
+ record_file->write(name,strlen(name)+1);
+
diff --git a/games/abuse/patches/patch-ak b/games/abuse/patches/patch-ak
new file mode 100644
index 00000000000..e7116f0b545
--- /dev/null
+++ b/games/abuse/patches/patch-ak
@@ -0,0 +1,24 @@
+$NetBSD: patch-ak,v 1.1 2002/07/16 14:26:21 agc Exp $
+
+--- abuse/src/dev.c 2002/07/16 14:10:23 1.1
++++ abuse/src/dev.c 2002/07/16 14:12:11
+@@ -2057,7 +2057,8 @@
+ {
+ if (!mess_win)
+ {
+- mess_win=file_dialog(eh,symbol_str("level_name"),current_level ? current_level->name() : "",
++ char *blank = "";
++ mess_win=file_dialog(eh,symbol_str("level_name"),current_level ? current_level->name() : blank,
+ ID_LEVEL_LOAD_OK,symbol_str("ok_button"),ID_CANCEL,symbol_str("cancel_button"),
+ symbol_str("FILENAME"),ID_MESS_STR1);
+ eh->grab_focus(mess_win);
+@@ -2093,7 +2094,8 @@
+ {
+ if (!mess_win)
+ {
+- mess_win=file_dialog(eh,symbol_str("saveas_name"),current_level ? current_level->name() : "untitled.spe",
++ char *untitled = "untitled.spe";
++ mess_win=file_dialog(eh,symbol_str("saveas_name"),current_level ? current_level->name() : untitled,
+ ID_LEVEL_SAVEAS_OK,symbol_str("ok_button"),
+ ID_CANCEL,symbol_str("cancel_button"),
+ symbol_str("FILENAME"),ID_MESS_STR1);
diff --git a/games/abuse/patches/patch-al b/games/abuse/patches/patch-al
new file mode 100644
index 00000000000..56e951d64c0
--- /dev/null
+++ b/games/abuse/patches/patch-al
@@ -0,0 +1,13 @@
+$NetBSD: patch-al,v 1.1 2002/07/16 14:26:21 agc Exp $
+
+--- abuse/src/view.c 2002/07/16 14:15:54 1.1
++++ abuse/src/view.c 2002/07/16 14:16:23
+@@ -179,7 +179,7 @@
+
+ #else
+ char *get_login()
+-{ if (cur_user_name[0]) return cur_user_name; else return (getlogin() ? getlogin() : "unknown"); }
++{ char *unknown = "unknown"; if (cur_user_name[0]) return cur_user_name; else return (getlogin() ? getlogin() : unknown); }
+
+ #endif
+