View | Details | Raw Unified | Return to bug 140233
Collapse All | Expand All

(-)doom/Makefile (-1 / +19 lines)
Lines 7-13 Link Here
7
7
8
PORTNAME=	doom
8
PORTNAME=	doom
9
PORTVERSION=	1.10
9
PORTVERSION=	1.10
10
PORTREVISION=	4
10
PORTREVISION=	5
11
CATEGORIES=	games
11
CATEGORIES=	games
12
MASTER_SITES=	${MASTER_SITE_IDSOFTWARE:S|$|source/|}
12
MASTER_SITES=	${MASTER_SITE_IDSOFTWARE:S|$|source/|}
13
DISTNAME=	doomsrc
13
DISTNAME=	doomsrc
Lines 30-35 Link Here
30
	@cd ${WRKDIR} && ${TAR} xzf linuxdoom-1.10.src.tgz && ${TAR} xzf sndserv.tgz
30
	@cd ${WRKDIR} && ${TAR} xzf linuxdoom-1.10.src.tgz && ${TAR} xzf sndserv.tgz
31
31
32
post-patch:
32
post-patch:
33
	${REINPLACE_CMD} 's|<linux/soundcard.h>|<sys/soundcard.h>|g'\
34
			${WRKSRC}/sndserv/linux.c \
35
			${WRKSRC}/linuxdoom-1.10/i_sound.c
36
	${REINPLACE_CMD} 's|<errnos.h>|<errno.h>|g' \
37
			${WRKSRC}/linuxdoom-1.10/i_video.c
38
	${REINPLACE_CMD} 's|#include  <alloca.h>|//#include  <alloca.h>|g'\
39
			${WRKSRC}/linuxdoom-1.10/r_data.c
40
	${REINPLACE_CMD} 's|#include <alloca.h>|//#include <alloca.h>|g'\
41
			${WRKSRC}/linuxdoom-1.10/w_wad.c
42
	${REINPLACE_CMD} 's|<malloc.c>|<stdlib.h>|g'\
43
			${WRKSRC}/linuxdoom-1.10/w_wad.c \
44
			${WRKSRC}/sndserv/soundsrv.c \
45
			${WRKSRC}/sndserv/wadread.c
46
	${REINPLACE_CMD} 's|<values.h>|<limits.h>|g'\
47
			${WRKSRC}/linuxdoom-1.10/m_bbox.h \
48
			${WRKSRC}/linuxdoom-1.10/doomtype.h
49
	${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}|g'\
50
			${WRKSRC}/linuxdoom-1.10/Makefile
33
	@${FIND} ${WRKSRC} -type f | ${XARGS} ${REINPLACE_CMD} \
51
	@${FIND} ${WRKSRC} -type f | ${XARGS} ${REINPLACE_CMD} \
34
		-E -e 's|#include +<malloc.h>|#include <stdlib.h>|g'
52
		-E -e 's|#include +<malloc.h>|#include <stdlib.h>|g'
35
53
(-)doom/files/patch-Makefile (+26 lines)
Added Link Here
1
--- linuxdoom-1.10/Makefile.orig	Mon Dec 22 20:55:36 1997
2
+++ linuxdoom-1.10/Makefile	Fri Oct 28 12:44:09 2005
3
@@ -4,11 +4,12 @@
4
 #
5
 # $Log:$
6
 #
7
-CC=  gcc  # gcc or g++
8
+CC?=  gcc  # gcc or g++
9
 
10
-CFLAGS=-g -Wall -DNORMALUNIX -DLINUX # -DUSEASM 
11
-LDFLAGS=-L/usr/X11R6/lib
12
-LIBS=-lXext -lX11 -lnsl -lm
13
+CFLAGS?= -O
14
+CFLAGS+=-g -I%%LOCALBASE%%/include -Wall -DNORMALUNIX -DSNDSERV -DSNDSRV # -DUSEASM 
15
+LDFLAGS=-L%%LOCALBASE%%/lib
16
+LIBS=-lXext -lX11 -lm
17
 
18
 # subdirectory for objects
19
 O=linux
20
@@ -92,4 +93,4 @@
21
 
22
 #############################################################
23
 #
24
-#############################################################
25
\ No newline at end of file
26
+#############################################################
(-)doom/files/patch-aa (-11 lines)
Removed Link Here
1
--- sndserv/linux.c~	Sun Jan 26 08:45:01 1997
2
+++ sndserv/linux.c	Mon Dec 14 21:15:21 1998
3
@@ -40,7 +40,7 @@
4
 #include <fcntl.h>
5
 #include <unistd.h>
6
 
7
-#include <linux/soundcard.h>
8
+#include <sys/soundcard.h>
9
 
10
 #include "soundsrv.h"
11
 
(-)doom/files/patch-ab (-26 lines)
Removed Link Here
1
--- linuxdoom-1.10/Makefile.orig	Mon Dec 22 20:55:36 1997
2
+++ linuxdoom-1.10/Makefile	Fri Oct 28 12:44:09 2005
3
@@ -4,11 +4,12 @@
4
 #
5
 # $Log:$
6
 #
7
-CC=  gcc  # gcc or g++
8
+CC?=  gcc  # gcc or g++
9
 
10
-CFLAGS=-g -Wall -DNORMALUNIX -DLINUX # -DUSEASM 
11
-LDFLAGS=-L/usr/X11R6/lib
12
-LIBS=-lXext -lX11 -lnsl -lm
13
+CFLAGS?= -O
14
+CFLAGS+=-g -I${LOCALBASE}/include -Wall -DNORMALUNIX -DSNDSERV -DSNDSRV # -DUSEASM 
15
+LDFLAGS=-L${LOCALBASE}/lib
16
+LIBS=-lXext -lX11 -lm
17
 
18
 # subdirectory for objects
19
 O=linux
20
@@ -92,4 +93,4 @@
21
 
22
 #############################################################
23
 #
24
-#############################################################
25
\ No newline at end of file
26
+#############################################################
(-)doom/files/patch-ac (-25 lines)
Removed Link Here
1
--- linuxdoom-1.10/i_sound.c.orig	Mon Dec 22 20:57:15 1997
2
+++ linuxdoom-1.10/i_sound.c	Wed Feb 10 04:18:53 1999
3
@@ -42,7 +42,7 @@
4
 #include <sys/ioctl.h>
5
 
6
 // Linux voxware output.
7
-#include <linux/soundcard.h>
8
+#include <sys/soundcard.h>
9
 
10
 // Timer stuff. Experimental.
11
 #include <time.h>
12
@@ -740,11 +740,13 @@
13
 #ifdef SNDSERV
14
   char buffer[256];
15
   
16
+#if jmz
17
   if (getenv("DOOMWADDIR"))
18
     sprintf(buffer, "%s/%s",
19
 	    getenv("DOOMWADDIR"),
20
 	    sndserver_filename);
21
   else
22
+#endif
23
     sprintf(buffer, "%s", sndserver_filename);
24
   
25
   // start sound process
(-)doom/files/patch-ad (-11 lines)
Removed Link Here
1
--- linuxdoom-1.10/i_video.c~	Mon Dec 22 21:39:01 1997
2
+++ linuxdoom-1.10/i_video.c	Mon Dec 14 03:24:45 1998
3
@@ -46,7 +46,7 @@
4
 #include <sys/socket.h>
5
 
6
 #include <netinet/in.h>
7
-#include <errnos.h>
8
+#include <errno.h>
9
 #include <signal.h>
10
 
11
 #include "doomstat.h"
(-)doom/files/patch-ae (-35 lines)
Removed Link Here
1
--- linuxdoom-1.10/i_net.c~	Mon Dec 22 21:37:46 1997
2
+++ linuxdoom-1.10/i_net.c	Mon Jul 22 10:06:25 2002
3
@@ -23,6 +23,7 @@
4
 static const char
5
 rcsid[] = "$Id: patch-ae,v 1.1.1.1 1998/12/14 21:18:25 jmz Exp $";
6
 
7
+#include <sys/types.h>
8
 #include <stdlib.h>
9
 #include <string.h>
10
 #include <stdio.h>
11
@@ -51,6 +52,7 @@
12
 
13
 
14
 
15
+#if 0
16
 // For some odd reason...
17
 #define ntohl(x) \
18
         ((unsigned long int)((((unsigned long int)(x) & 0x000000ffU) << 24) | \
19
@@ -64,6 +66,7 @@
20
 	  
21
 #define htonl(x) ntohl(x)
22
 #define htons(x) ntohs(x)
23
+#endif
24
 
25
 void	NetSend (void);
26
 boolean NetListen (void);
27
@@ -73,7 +76,7 @@
28
 // NETWORKING
29
 //
30
 
31
-int	DOOMPORT =	(IPPORT_USERRESERVED +0x1d );
32
+int	DOOMPORT =	5029;
33
 
34
 int			sendsocket;
35
 int			insocket;
(-)doom/files/patch-af (-11 lines)
Removed Link Here
1
--- linuxdoom-1.10/r_data.c~	Mon Dec 22 21:57:47 1997
2
+++ linuxdoom-1.10/r_data.c	Mon Dec 14 03:27:49 1998
3
@@ -42,7 +42,7 @@
4
 #include "r_sky.h"
5
 
6
 #ifdef LINUX
7
-#include  <alloca.h>
8
+//#include  <alloca.h>
9
 #endif
10
 
11
 
(-)doom/files/patch-ag (-14 lines)
Removed Link Here
1
--- linuxdoom-1.10/w_wad.c~	Mon Dec 22 22:05:36 1997
2
+++ linuxdoom-1.10/w_wad.c	Mon Dec 14 03:29:18 1998
3
@@ -32,9 +32,9 @@
4
 #include <string.h>
5
 #include <unistd.h>
6
-#include <malloc.h>
7
+#include <stdlib.h>
8
 #include <fcntl.h>
9
 #include <sys/stat.h>
10
-#include <alloca.h>
11
+//#include <alloca.h>
12
 #define O_BINARY		0
13
 #endif
14
 
(-)doom/files/patch-ah (-22 lines)
Removed Link Here
1
--- linuxdoom-1.10/m_bbox.h~	Mon Dec 22 21:12:16 1997
2
+++ linuxdoom-1.10/m_bbox.h	Mon Dec 14 03:31:32 1998
3
@@ -23,7 +23,7 @@
4
 #ifndef __M_BBOX__
5
 #define __M_BBOX__
6
 
7
-#include <values.h>
8
+#include <limits.h>
9
 
10
 #include "m_fixed.h"
11
 
12
--- linuxdoom-1.10/doomtype.h~	Mon Dec 22 21:05:27 1997
13
+++ linuxdoom-1.10/doomtype.h	Mon Dec 14 03:31:14 1998
14
@@ -39,7 +39,7 @@
15
 
16
 // Predefined with some OS.
17
 #ifdef LINUX
18
-#include <values.h>
19
+#include <limits.h>
20
 #else
21
 #define MAXCHAR		((char)0x7f)
22
 #define MAXSHORT	((short)0x7fff)
(-)doom/files/patch-ai (-8 lines)
Removed Link Here
1
--- linuxdoom-1.10/m_bbox.c~	Mon Dec 22 21:40:50 1997
2
+++ linuxdoom-1.10/m_bbox.c	Mon Dec 14 03:44:53 1998
3
@@ -1,3 +1,5 @@
4
+#define MAXINT 0x7fffffff
5
+#define MININT 0x80000000
6
 // Emacs style mode select   -*- C++ -*- 
7
 //-----------------------------------------------------------------------------
8
 //
(-)doom/files/patch-aj (-14 lines)
Removed Link Here
1
--- sndserv/Makefile.orig	Sun Feb  6 16:36:56 2000
2
+++ sndserv/Makefile	Sun Feb  6 16:37:13 2000
3
@@ -6,8 +6,9 @@
4
 #
5
 #
6
 
7
-CC=gcc
8
-CFLAGS=-O -DNORMALUNIX -DLINUX
9
+CC?=gcc
10
+CFLAGS?=-O
11
+CFLAGS+=-DNORMALUNIX -DLINUX
12
 LDFLAGS=
13
 LIBS=-lm
14
 
(-)doom/files/patch-i_net.c (+35 lines)
Added Link Here
1
--- linuxdoom-1.10/i_net.c~	Mon Dec 22 21:37:46 1997
2
+++ linuxdoom-1.10/i_net.c	Mon Jul 22 10:06:25 2002
3
@@ -23,6 +23,7 @@
4
 static const char
5
 rcsid[] = "$Id: patch-ae,v 1.1.1.1 1998/12/14 21:18:25 jmz Exp $";
6
 
7
+#include <sys/types.h>
8
 #include <stdlib.h>
9
 #include <string.h>
10
 #include <stdio.h>
11
@@ -51,6 +52,7 @@
12
 
13
 
14
 
15
+#if 0
16
 // For some odd reason...
17
 #define ntohl(x) \
18
         ((unsigned long int)((((unsigned long int)(x) & 0x000000ffU) << 24) | \
19
@@ -64,6 +66,7 @@
20
 	  
21
 #define htonl(x) ntohl(x)
22
 #define htons(x) ntohs(x)
23
+#endif
24
 
25
 void	NetSend (void);
26
 boolean NetListen (void);
27
@@ -73,7 +76,7 @@
28
 // NETWORKING
29
 //
30
 
31
-int	DOOMPORT =	(IPPORT_USERRESERVED +0x1d );
32
+int	DOOMPORT =	5029;
33
 
34
 int			sendsocket;
35
 int			insocket;
(-)doom/files/patch-i_sound.c (+25 lines)
Added Link Here
1
--- linuxdoom-1.10/i_sound.c.orig	Mon Dec 22 20:57:15 1997
2
+++ linuxdoom-1.10/i_sound.c	Wed Feb 10 04:18:53 1999
3
@@ -42,7 +42,7 @@
4
 #include <sys/ioctl.h>
5
 
6
 // Linux voxware output.
7
-#include <linux/soundcard.h>
8
+#include <sys/soundcard.h>
9
 
10
 // Timer stuff. Experimental.
11
 #include <time.h>
12
@@ -740,11 +740,13 @@
13
 #ifdef SNDSERV
14
   char buffer[256];
15
   
16
+#if jmz
17
   if (getenv("DOOMWADDIR"))
18
     sprintf(buffer, "%s/%s",
19
 	    getenv("DOOMWADDIR"),
20
 	    sndserver_filename);
21
   else
22
+#endif
23
     sprintf(buffer, "%s", sndserver_filename);
24
   
25
   // start sound process
(-)doom/files/patch-m_bbox.c (+8 lines)
Added Link Here
1
--- linuxdoom-1.10/m_bbox.c~	Mon Dec 22 21:40:50 1997
2
+++ linuxdoom-1.10/m_bbox.c	Mon Dec 14 03:44:53 1998
3
@@ -1,3 +1,5 @@
4
+#define MAXINT 0x7fffffff
5
+#define MININT 0x80000000
6
 // Emacs style mode select   -*- C++ -*- 
7
 //-----------------------------------------------------------------------------
8
 //
(-)doom/files/patch-sndserv-Makefile (+14 lines)
Added Link Here
1
--- sndserv/Makefile.orig	Sun Feb  6 16:36:56 2000
2
+++ sndserv/Makefile	Sun Feb  6 16:37:13 2000
3
@@ -6,8 +6,9 @@
4
 #
5
 #
6
 
7
-CC=gcc
8
-CFLAGS=-O -DNORMALUNIX -DLINUX
9
+CC?=gcc
10
+CFLAGS?=-O
11
+CFLAGS+=-DNORMALUNIX -DLINUX
12
 LDFLAGS=
13
 LIBS=-lm
14

Return to bug 140233