pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/games/doomlegacy/patches games/doomlegacy: Remove old ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/27504ae13d39
branches:  trunk
changeset: 441211:27504ae13d39
user:      micha <micha%pkgsrc.org@localhost>
date:      Thu Oct 29 09:03:24 2020 +0000

description:
games/doomlegacy: Remove old patches

They were merged upstream.
Thanks wiz@ for pointing out that I forgot to delete them from CVS.

diffstat:

 games/doomlegacy/patches/patch-src_i__tcp.c    |  56 --------------------------
 games/doomlegacy/patches/patch-src_mserv.c     |  54 -------------------------
 games/doomlegacy/patches/patch-src_t__prepro.h |  16 -------
 3 files changed, 0 insertions(+), 126 deletions(-)

diffs (138 lines):

diff -r 52fde8120ef8 -r 27504ae13d39 games/doomlegacy/patches/patch-src_i__tcp.c
--- a/games/doomlegacy/patches/patch-src_i__tcp.c       Thu Oct 29 08:24:44 2020 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,56 +0,0 @@
-$NetBSD: patch-src_i__tcp.c,v 1.3 2020/06/18 10:14:54 micha Exp $
-
-Use native inet_aton() on Solaris.
-Use portable fcntl() instead of ioctl() for non-blocking mode by default.
-
---- src/i_tcp.c.orig   2020-05-10 22:05:16.000000000 +0000
-+++ src/i_tcp.c
-@@ -123,7 +123,7 @@
- 
- #ifdef __OS2__
-   // sys/types.h is also included unconditionally by doomincl.h
--# include <sys/types.h>
-+# include <sys/types.h>  // [MB] 2020-06-18: Maybe required for old Unix too
- # include <sys/time.h>
- #endif // __OS2__
- 
-@@ -146,6 +146,7 @@
- // non-windows includes
- #include <sys/socket.h>
- #include <netinet/in.h>
-+#include <fcntl.h>       // [MB] 2020-06-18: For fcntl()
- #include <unistd.h>
- #include <netdb.h>
- #include <sys/ioctl.h>
-@@ -355,7 +356,9 @@ byte  generic_hashaddr( mysockaddr_t *a 
- // htons: host to net byte order
- // ntohs: net to host byte order
- 
--#if defined( WIN32) || defined( __OS2__) || defined( SOLARIS)
-+// [MB] 2020-06-18: Use native inet_aton() on Solaris
-+// Solaris has inet_aton() in libresolv since version 2.6 from 1997
-+#if defined( WIN32) || defined( __OS2__) // || defined( SOLARIS)
- // [WDJ] Also defined in mserv.c, but too small, will be inlined anyway.
- static inline
- int inet_aton(const char *hostname,
-@@ -1006,7 +1009,20 @@ retry_bind:
-     CONS_Printf("Network port: %d\n", my_sock_port);
- 
-     // make it non blocking
-+#ifndef LINUX
-     ioctl (s, FIONBIO, &trueval);
-+#else
-+    // [MB] 2020-06-18: Use portable POSIX way to enable non-blocking mode
-+    // https://pubs.opengroup.org/onlinepubs/9699919799/functions/fcntl.html
-+    {
-+        int res = fcntl(s, F_SETFL, O_NONBLOCK);
-+        if(-1 == res)
-+        {
-+            I_SoftError("UDP_Socket: Switching to non-blocking mode failed: %s\n", strerror(errno));
-+            goto close_socket;
-+        }
-+    }
-+#endif
- 
-     // make it broadcastable
- #ifdef LINUX
diff -r 52fde8120ef8 -r 27504ae13d39 games/doomlegacy/patches/patch-src_mserv.c
--- a/games/doomlegacy/patches/patch-src_mserv.c        Thu Oct 29 08:24:44 2020 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,54 +0,0 @@
-$NetBSD: patch-src_mserv.c,v 1.2 2020/06/17 16:16:57 micha Exp $
-
-Use native inet_aton() on Solaris.
-Use portable fcntl() instead of ioctl() for non-blocking mode by default.
-
---- src/mserv.c.orig   2020-06-16 09:17:35.000000000 +0000
-+++ src/mserv.c
-@@ -122,12 +122,13 @@
- #else
- # include <unistd.h>
- # ifdef __OS2__
--#  include <sys/types.h>
-+#  include <sys/types.h>  // [MB] 2020-06-16: Maybe required for old Unix too
- # endif
- # include <sys/socket.h>  // socket(),...
- # include <sys/time.h>    // timeval,... (TIMEOUT)
- # include <netinet/in.h>  // sockaddr_in
- # include <arpa/inet.h>   // inet_addr(),...
-+# include <fcntl.h>       // [MB] 2020-06-16: For fcntl()
- # include <netdb.h>       // gethostbyname(),...
- # include <sys/ioctl.h>
- # include <errno.h>
-@@ -210,7 +211,9 @@ struct Copy_CVarMS_t
- #define close closesocket
- #endif
- 
--#if defined( WIN32) || defined( __OS2__) || defined( SOLARIS)
-+// [MB] 2020-06-16: Use native inet_aton() on Solaris
-+// Solaris has inet_aton() in libresolv since version 2.6 from 1997
-+#if defined( WIN32) || defined( __OS2__) // || defined( SOLARIS)
- // it seems windows doesn't define that... maybe some other OS? OS/2
- static inline
- int inet_aton(const char *hostname,
-@@ -643,9 +646,19 @@ static int MS_Connect(char *ip_addr, cha
-         // winsock.h:  int ioctlsocket(SOCKET,long,u_long *);
-         u_long test = 1; // [smite] I have no idea what this type is supposed to be
-         ioctlsocket(ms_socket_fd, FIONBIO, &test);
--#else
-+#elif defined(__OS2__)
-         res = 1;  // non-blocking true
-         ioctl(ms_socket_fd, FIONBIO, &res);
-+#else
-+        // [MB] 2020-06-16: Use portable POSIX way to enable non-blocking mode
-+        // https://pubs.opengroup.org/onlinepubs/9699919799/functions/fcntl.html
-+        res = fcntl(ms_socket_fd, F_SETFL, O_NONBLOCK);
-+        if(-1 == res)
-+        {
-+            con_state = MSCS_FAILED;
-+            MS_Close_socket();
-+            return MS_CONNECT_ERROR;
-+        }
- #endif
-         res = connect(ms_socket_fd, (struct sockaddr *) &ms_addr, sizeof(ms_addr));
-         if (res < 0)
diff -r 52fde8120ef8 -r 27504ae13d39 games/doomlegacy/patches/patch-src_t__prepro.h
--- a/games/doomlegacy/patches/patch-src_t__prepro.h    Thu Oct 29 08:24:44 2020 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,16 +0,0 @@
-$NetBSD: patch-src_t__prepro.h,v 1.1 2020/06/10 15:35:02 micha Exp $
-
-The type label_t is not available on all OS, e.g. on SmartOS.
-labelforname() is an unused function and the only place where label_t is used.
-
---- src/t_prepro.h.orig        2018-07-16 09:17:06.000000000 +0000
-+++ src/t_prepro.h
-@@ -97,6 +97,8 @@ typedef enum    // section types
- 
- /****** goto labels ***********/
- 
-+#if 0
- label_t * labelforname(char *labelname);
-+#endif
- 
- #endif



Home | Main Index | Thread Index | Old Index