]> granicus.if.org Git - nethack/commitdiff
\#include "fnamesiz.h"
authorPatR <rankin@nethack.org>
Fri, 8 Jan 2021 22:59:36 +0000 (14:59 -0800)
committerPatR <rankin@nethack.org>
Fri, 8 Jan 2021 22:59:36 +0000 (14:59 -0800)
The inclusion shouldn't really come before *conf.h because the
things it sets up could depend on those.  This is better, but
having Amiga 90% dead and 10% comatose seems to be more trouble
that it's worth.

include/global.h
sys/unix/Makefile.src

index 9f9efe376d2641d7642f3b5ac24fe4ce621c9ee3..375618533d27b06d57ad368e924099818cccc03d 100644 (file)
@@ -1,4 +1,4 @@
-/* NetHack 3.7 global.h        $NHDT-Date: 1610141601 2021/01/08 21:33:21 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.117 $ */
+/* NetHack 3.7 global.h        $NHDT-Date: 1610146765 2021/01/08 22:59:25 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.118 $ */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /*-Copyright (c) Michael Allison, 2006. */
 /* NetHack may be freely redistributed.  See license for details. */
@@ -110,8 +110,6 @@ typedef uchar nhsym;
 
 #include "coord.h"
 
-#include "fnamesiz.h" /* file sizes shared between nethack and recover */
-
 #if defined(CROSSCOMPILE)
 struct cross_target_s {
     const char *build_date;
@@ -167,6 +165,17 @@ extern struct cross_target_s cross_target;
 #include "ntconf.h"
 #endif
 
+/*
+ * Note:  placing this before amiconf.h is to avoid complications for
+ * 'make depend' after amiconf.h got moved to the outdated/ sub-tree.
+ * Inclusion really belongs somewhere after the define for SHORT_FILENAMES
+ * below, and for that we either need to resurrect amiconf.h or supply
+ * an empty stub for it in include/amiconf.h.
+ */
+#include "fnamesiz.h" /* file sizes shared between nethack and recover */
+
+/* amiconf.h needs to be the last nested #include of config.h because
+   'make depend' will turn it into a comment, hiding anything after it */
 #ifdef AMIGA
 #include "amiconf.h"
 #endif
index 8e5aa927de7d935f18c711ca2244191c119483de..50e13de1c5db6f2813f2ce4ce6c264ca0195a02d 100644 (file)
@@ -1,5 +1,5 @@
 #      NetHack Makefile.
-# NetHack 3.7  Makefile.src    $NHDT-Date: 1610142633 2021/01/08 21:50:33 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.119 $
+# NetHack 3.7  Makefile.src    $NHDT-Date: 1610146766 2021/01/08 22:59:26 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.120 $
 # Copyright (c) 2018 by Pasi Kallinen
 # NetHack may be freely redistributed.  See license for details.
 
@@ -831,9 +831,9 @@ depend: ../sys/unix/depend.awk \
 # config.h timestamp
 $(CONFIG_H): ../include/config.h ../include/config1.h ../include/patchlevel.h \
                ../include/tradstdc.h ../include/global.h ../include/coord.h \
-               ../include/fnamesiz.h ../include/vmsconf.h ../include/system.h \
-               ../include/nhlua.h ../include/unixconf.h ../include/pcconf.h \
-               ../include/micro.h ../include/ntconf.h #../include/amiconf.h
+               ../include/vmsconf.h ../include/system.h ../include/nhlua.h \
+               ../include/unixconf.h ../include/pcconf.h ../include/micro.h \
+               ../include/ntconf.h ../include/fnamesiz.h #../include/amiconf.h
        touch $(CONFIG_H)
 # hack.h timestamp
 $(HACK_H): ../include/hack.h $(CONFIG_H) ../include/lint.h ../include/align.h \