Rather straightforward, mostly neuter some old BSD ifdefs from long ago.
I chose not to bother with any srand because those are not needed for us.

These 3 all build and run.

Seems that falconeye's saves is broken, but I surmise it's another
issue entirely I'll have to investigate.

Index: slash/Makefile
===================================================================
RCS file: /vide/cvs/ports/games/slash/Makefile,v
diff -u -p -r1.54 Makefile
--- slash/Makefile      25 Sep 2023 17:07:29 -0000      1.54
+++ slash/Makefile      3 Jun 2026 12:47:55 -0000
@@ -2,7 +2,7 @@ COMMENT =       dungeon explorin', hackin' gam
 
 DISTNAME =     slash-e8
 PKGNAME =      slash-3.2.2.e8
-REVISION =     8
+REVISION =     9
 CATEGORIES =   games
 
 SITES =                ${SITE_SOURCEFORGE:=nethack/}
Index: slash/patches/patch-src_hacklib_c
===================================================================
RCS file: slash/patches/patch-src_hacklib_c
diff -N slash/patches/patch-src_hacklib_c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ slash/patches/patch-src_hacklib_c   3 Jun 2026 12:47:35 -0000
@@ -0,0 +1,52 @@
+Index: src/hacklib.c
+--- src/hacklib.c.orig
++++ src/hacklib.c
+@@ -410,6 +410,7 @@ static struct tm *NDECL(getlt);
+ void
+ setrandom()
+ {
++#if 0
+       /* the types are different enough here that sweeping the different
+        * routine names into one via #defines is even more confusing
+        */
+@@ -433,6 +434,7 @@ setrandom()
+ #  endif
+ # endif
+ #endif
++#endif
+ }
+ 
+ static struct tm *
+@@ -440,12 +442,12 @@ getlt()
+ {
+       time_t date;
+ 
+-#ifdef BSD
++#if 0
+       (void) time((long *)(&date));
+ #else
+       (void) time(&date);
+ #endif
+-#if (defined(ULTRIX) && !(defined(ULTRIX_PROTO) || defined(NHSTDC))) || 
defined(BSD)
++#if 0
+       return(localtime((long *)(&date)));
+ #else
+       return(localtime(&date));
+@@ -469,7 +471,7 @@ time_t date;
+       if (date == 0)
+               lt = getlt();
+       else
+-#if (defined(ULTRIX) && !(defined(ULTRIX_PROTO) || defined(NHSTDC))) || 
defined(BSD)
++#if 0
+               lt = localtime((long *)(&date));
+ #else
+               lt = localtime(&date);
+@@ -490,7 +492,7 @@ time_t date;
+       if (date == 0)
+               lt = getlt();
+       else
+-#if (defined(ULTRIX) && !(defined(ULTRIX_PROTO) || defined(NHSTDC))) || 
defined(BSD)
++#if 0
+               lt = localtime((long *)(&date));
+ #else
+               lt = localtime(&date);
Index: slash/patches/patch-src_u_init_c
===================================================================
RCS file: slash/patches/patch-src_u_init_c
diff -N slash/patches/patch-src_u_init_c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ slash/patches/patch-src_u_init_c    3 Jun 2026 12:47:35 -0000
@@ -0,0 +1,12 @@
+Index: src/u_init.c
+--- src/u_init.c.orig
++++ src/u_init.c
+@@ -711,7 +711,7 @@ u_init()
+       u.ulycn = NON_PM;
+       set_uasmon();
+ 
+-#ifdef BSD
++#if 0
+       (void) time((long *)&u.ubirthday);
+ #else
+       (void) time(&u.ubirthday);
Index: slash/patches/patch-sys_unix_unixunix_c
===================================================================
RCS file: /vide/cvs/ports/games/slash/patches/patch-sys_unix_unixunix_c,v
diff -u -p -r1.2 patch-sys_unix_unixunix_c
--- slash/patches/patch-sys_unix_unixunix_c     11 Mar 2022 19:04:55 -0000      
1.2
+++ slash/patches/patch-sys_unix_unixunix_c     3 Jun 2026 12:47:35 -0000
@@ -1,5 +1,6 @@
---- sys/unix/unixunix.c.orig   Tue Jun 18 00:34:55 1996
-+++ sys/unix/unixunix.c        Fri Apr 14 15:10:49 2000
+Index: sys/unix/unixunix.c
+--- sys/unix/unixunix.c.orig
++++ sys/unix/unixunix.c
 @@ -38,7 +38,9 @@ gethdate(name)
   * does not exist on all systems, and moreover, that it sometimes includes
   * <sys/types.h> again, so that the compiler sees these typedefs twice.
@@ -10,3 +11,12 @@
  
        register const char *np, *path;
        char filename[MAXPATHLEN+1];
+@@ -107,7 +109,7 @@ int fd;
+ #ifndef INSURANCE
+       if(buf.st_size != sizeof(int)) return(0);       /* not an xlock file */
+ #endif
+-#ifdef BSD
++#if 0
+       (void) time((long *)(&date));
+ #else
+       (void) time(&date);
Index: slash-em/Makefile
===================================================================
RCS file: /vide/cvs/ports/games/slash-em/Makefile,v
diff -u -p -r1.34 Makefile
--- slash-em/Makefile   7 Nov 2023 14:19:31 -0000       1.34
+++ slash-em/Makefile   3 Jun 2026 13:06:43 -0000
@@ -1,7 +1,7 @@
 COMMENT =      dungeon explorin', hackin', game.  Hard
 DISTNAME =     se007e7f1
 PKGNAME =      slash-em-3.4.3.7e7f1
-REVISION =     9
+REVISION =     10
 V =            3.4.3.7e7f1
 CATEGORIES =   games
 
Index: slash-em/patches/patch-util_lev_comp_y
===================================================================
RCS file: slash-em/patches/patch-util_lev_comp_y
diff -N slash-em/patches/patch-util_lev_comp_y
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ slash-em/patches/patch-util_lev_comp_y      3 Jun 2026 13:16:41 -0000
@@ -0,0 +1,12 @@
+Index: util/lev_comp.y
+--- util/lev_comp.y.orig
++++ util/lev_comp.y
+@@ -597,7 +597,7 @@ room_door  : DOOR_ID ':' secret ',' door_state ',' door
+                       /* ERR means random here */
+                       if ($7 == ERR && $9 != ERR) {
+                    yyerror("If the door wall is random, so must be its pos!");
+-                          tmprdoor[ndoor] = (struct room_door *)0;
++                          tmprdoor[ndoor] = (room_door *)0;
+                       } else {
+                           tmprdoor[ndoor] = New(room_door);
+                           tmprdoor[ndoor]->secret = $3;
Index: falconseye/Makefile
===================================================================
RCS file: /vide/cvs/ports/games/falconseye/Makefile,v
diff -u -p -r1.35 Makefile
--- falconseye/Makefile 7 Nov 2023 14:19:29 -0000       1.35
+++ falconseye/Makefile 3 Jun 2026 14:37:08 -0000
@@ -3,7 +3,7 @@ COMMENT =       NetHack derivative
 VERSION =      1.9.3
 DISTNAME =     nethack_source_331_jtp_${VERSION:S/.//g}
 PKGNAME =      falconseye-${VERSION}
-REVISION =     10
+REVISION =     11
 CATEGORIES =   games x11
 EXTRACT_SUFX = .zip
 
Index: falconseye/patches/patch-src_hacklib_c
===================================================================
RCS file: falconseye/patches/patch-src_hacklib_c
diff -N falconseye/patches/patch-src_hacklib_c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ falconseye/patches/patch-src_hacklib_c      3 Jun 2026 13:49:44 -0000
@@ -0,0 +1,43 @@
+Index: src/hacklib.c
+--- src/hacklib.c.orig
++++ src/hacklib.c
+@@ -437,6 +437,7 @@ static struct tm *NDECL(getlt);
+ void
+ setrandom()
+ {
++#if 0
+       /* the types are different enough here that sweeping the different
+        * routine names into one via #defines is even more confusing
+        */
+@@ -460,6 +461,7 @@ setrandom()
+ #  endif
+ # endif
+ #endif
++#endif
+ }
+ 
+ static struct tm *
+@@ -467,12 +469,12 @@ getlt()
+ {
+       time_t date;
+ 
+-#ifdef BSD
++#if 0
+       (void) time((long *)(&date));
+ #else
+       (void) time(&date);
+ #endif
+-#if (defined(ULTRIX) && !(defined(ULTRIX_PROTO) || defined(NHSTDC))) || 
defined(BSD)
++#if 0
+       return(localtime((long *)(&date)));
+ #else
+       return(localtime(&date));
+@@ -519,7 +521,7 @@ time_t date;
+       if (date == 0)
+               lt = getlt();
+       else
+-#if (defined(ULTRIX) && !(defined(ULTRIX_PROTO) || defined(NHSTDC))) || 
defined(BSD)
++#if 0
+               lt = localtime((long *)(&date));
+ #else
+               lt = localtime(&date);
Index: falconseye/patches/patch-src_u_init_c
===================================================================
RCS file: falconseye/patches/patch-src_u_init_c
diff -N falconseye/patches/patch-src_u_init_c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ falconseye/patches/patch-src_u_init_c       3 Jun 2026 13:49:44 -0000
@@ -0,0 +1,12 @@
+Index: src/u_init.c
+--- src/u_init.c.orig
++++ src/u_init.c
+@@ -576,7 +576,7 @@ u_init()
+                       aligns[flags.initalign].value;
+       u.ulycn = NON_PM;
+ 
+-#ifdef BSD
++#if 0
+       (void) time((long *)&u.ubirthday);
+ #else
+       (void) time(&u.ubirthday);
Index: falconseye/patches/patch-sys_unix_unixunix_c
===================================================================
RCS file: /vide/cvs/ports/games/falconseye/patches/patch-sys_unix_unixunix_c,v
diff -u -p -r1.2 patch-sys_unix_unixunix_c
--- falconseye/patches/patch-sys_unix_unixunix_c        11 Mar 2022 19:04:20 
-0000      1.2
+++ falconseye/patches/patch-sys_unix_unixunix_c        3 Jun 2026 13:49:44 
-0000
@@ -1,5 +1,6 @@
---- sys/unix/unixunix.c.orig   Sun Jun 24 18:57:24 2001
-+++ sys/unix/unixunix.c        Wed Jul  4 11:23:29 2001
+Index: sys/unix/unixunix.c
+--- sys/unix/unixunix.c.orig
++++ sys/unix/unixunix.c
 @@ -42,7 +42,9 @@ gethdate(name)
   * does not exist on all systems, and moreover, that it sometimes includes
   * <sys/types.h> again, so that the compiler sees these typedefs twice.
@@ -10,3 +11,12 @@
  
        register const char *np, *path;
        char filename[MAXPATHLEN+1];
+@@ -119,7 +121,7 @@ int fd;
+ #ifndef INSURANCE
+       if(buf.st_size != sizeof(int)) return(0);       /* not an xlock file */
+ #endif
+-#ifdef BSD
++#if 0
+       (void) time((long *)(&date));
+ #else
+       (void) time(&date);

Reply via email to