'make depend' fix

The gone but still referenced state of amiconf.h broke 'make depend'.
Fixing that turns it into a comment in the generated dependencies
but that ran into a problem with it being followed by fnamesiz.h
instead of being last in the list containing it.  So in addition to
the depend fix, move #include "fnamesiz.h" from config.h to global.h
in order to have it come before amiconf.h.
This commit is contained in:
PatR
2021-01-08 13:33:27 -08:00
parent c2989be3fc
commit 129ff12245
4 changed files with 10 additions and 8 deletions
+1 -2
View File
@@ -1,4 +1,4 @@
/* NetHack 3.7 config.h $NHDT-Date: 1608933417 2020/12/25 21:56:57 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.146 $ */ /* NetHack 3.7 config.h $NHDT-Date: 1610141601 2021/01/08 21:33:21 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.148 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Robert Patrick Rankin, 2016. */ /*-Copyright (c) Robert Patrick Rankin, 2016. */
/* NetHack may be freely redistributed. See license for details. */ /* NetHack may be freely redistributed. See license for details. */
@@ -608,6 +608,5 @@ typedef unsigned char uchar;
#endif #endif
#include "global.h" /* Define everything else according to choices above */ #include "global.h" /* Define everything else according to choices above */
#include "fnamesiz.h" /* Define file sizes shared between nethack and recover */
#endif /* CONFIG_H */ #endif /* CONFIG_H */
+3 -1
View File
@@ -1,4 +1,4 @@
/* NetHack 3.7 global.h $NHDT-Date: 1594032649 2020/07/06 10:50:49 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.104 $ */ /* NetHack 3.7 global.h $NHDT-Date: 1610141601 2021/01/08 21:33:21 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.117 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Michael Allison, 2006. */ /*-Copyright (c) Michael Allison, 2006. */
/* NetHack may be freely redistributed. See license for details. */ /* NetHack may be freely redistributed. See license for details. */
@@ -110,6 +110,8 @@ typedef uchar nhsym;
#include "coord.h" #include "coord.h"
#include "fnamesiz.h" /* file sizes shared between nethack and recover */
#if defined(CROSSCOMPILE) #if defined(CROSSCOMPILE)
struct cross_target_s { struct cross_target_s {
const char *build_date; const char *build_date;
+4 -4
View File
@@ -1,5 +1,5 @@
# NetHack Makefile. # NetHack Makefile.
# NetHack 3.7 Makefile.src $NHDT-Date: 1609702027 2021/01/03 19:27:07 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.117 $ # NetHack 3.7 Makefile.src $NHDT-Date: 1610141602 2021/01/08 21:33:22 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.118 $
# Copyright (c) 2018 by Pasi Kallinen # Copyright (c) 2018 by Pasi Kallinen
# NetHack may be freely redistributed. See license for details. # NetHack may be freely redistributed. See license for details.
@@ -831,9 +831,9 @@ depend: ../sys/unix/depend.awk \
# config.h timestamp # config.h timestamp
$(CONFIG_H): ../include/config.h ../include/config1.h ../include/patchlevel.h \ $(CONFIG_H): ../include/config.h ../include/config1.h ../include/patchlevel.h \
../include/tradstdc.h ../include/global.h ../include/coord.h \ ../include/tradstdc.h ../include/global.h ../include/coord.h \
../include/vmsconf.h ../include/system.h ../include/nhlua.h \ ../include/fnamesiz.h ../include/vmsconf.h ../include/system.h \
../include/unixconf.h ../include/pcconf.h ../include/micro.h \ ../include/nhlua.h ../include/unixconf.h ../include/pcconf.h \
../include/ntconf.h ../include/fnamesiz.h ../include/micro.h ../include/ntconf.h #../include/amiconf.h
touch $(CONFIG_H) touch $(CONFIG_H)
# hack.h timestamp # hack.h timestamp
$(HACK_H): ../include/hack.h $(CONFIG_H) ../include/lint.h ../include/align.h \ $(HACK_H): ../include/hack.h $(CONFIG_H) ../include/lint.h ../include/align.h \
+2 -1
View File
@@ -1,6 +1,6 @@
# depend.awk -- awk script used to construct makefile dependencies # depend.awk -- awk script used to construct makefile dependencies
# for nethack's source files (`make depend' support for Makefile.src). # for nethack's source files (`make depend' support for Makefile.src).
# $NHDT-Date: 1575916941 2019/12/09 18:42:21 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.10 $ # $NHDT-Date: 1610141602 2021/01/08 21:33:22 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.12 $
# #
# usage: # usage:
# cd src ; nawk -f depend.awk ../include/*.h list-of-.c/.cpp-files # cd src ; nawk -f depend.awk ../include/*.h list-of-.c/.cpp-files
@@ -31,6 +31,7 @@ BEGIN { FS = "\"" #for `#include "X"', $2 is X
alt_deps["../include/patchlev.h"] = "" alt_deps["../include/patchlev.h"] = ""
alt_deps["interp.c"] = " #interp.c" #comment it out alt_deps["interp.c"] = " #interp.c" #comment it out
alt_deps["../include/win32api.h"] = " #../include/win32api.h" alt_deps["../include/win32api.h"] = " #../include/win32api.h"
alt_deps["../include/amiconf.h"] = " #../include/amiconf.h"
alt_deps["../include/zlib.h"] = " #zlib.h" #comment it out alt_deps["../include/zlib.h"] = " #zlib.h" #comment it out
} }
FNR == 1 { output_dep() #finish previous file FNR == 1 { output_dep() #finish previous file