]> granicus.if.org Git - nethack/commitdiff
Makefile.utl dependency bug for dlb.o
authorPatR <rankin@nethack.org>
Fri, 5 Feb 2016 22:41:16 +0000 (14:41 -0800)
committerPatR <rankin@nethack.org>
Fri, 5 Feb 2016 22:41:16 +0000 (14:41 -0800)
For make install or update, dlb.o was being recompiled unnecessarily
when building util/dlb because the dependency in Makefile.utl listed
hack.h instead of config.h for it.  Then attempting to run nethack
under debugger control could cause debugger complaints about dlb.o
being newer than nethack.

Updated for unix and vms.

sys/unix/Makefile.utl
sys/vms/Makefile.utl

index bdc5f09e8b3e3e825365dd14e3905730cd1df17b..5f092ecfacad36f64d956b3fc8bc973cb76e04be 100644 (file)
@@ -1,5 +1,5 @@
 #      Makefile for NetHack's utility programs.
-# NetHack 3.6  Makefile.utl    $NHDT-Date: 1454376585 2016/02/02 01:29:45 $  $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.28 $
+# NetHack 3.6  Makefile.utl    $NHDT-Date: 1454712070 2016/02/05 22:41:10 $  $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.29 $
 
 # Root of source tree:
 NHSROOT=..
@@ -351,12 +351,12 @@ tilemap: tilemap.o
 tiletext.o: ../win/share/tiletext.c $(CONFIG_H) ../include/tile.h
        $(CC) $(CFLAGS) -c ../win/share/tiletext.c
 tiletxt.c: ./Makefile
-       echo '/* alternate compilation for tilemap.c to create tiletxt.o' > tiletxt.c
-       echo '   that does not rely on "cc -c -o tiletxt.o tilemap.c"'   >> tiletxt.c
-       echo '   since many pre-POSIX compilers did not support that */' >> tiletxt.c
+       @echo '/* alternate compilation for tilemap.c to create tiletxt.o' > tiletxt.c
+       @echo '   that does not rely on "cc -c -o tiletxt.o tilemap.c"'  >> tiletxt.c
+       @echo '   since many pre-POSIX compilers did not support that */' >> tiletxt.c
        echo '#define TILETEXT'                  >> tiletxt.c
        echo '#include "../win/share/tilemap.c"' >> tiletxt.c
-       echo '/*tiletxt.c*/'                     >> tiletxt.c
+       @echo '/*tiletxt.c*/'                    >> tiletxt.c
 tiletxt.o: tiletxt.c ../win/share/tilemap.c $(HACK_H)
        $(CC) $(CFLAGS) -c tiletxt.c
 tilemap.o: ../win/share/tilemap.c $(HACK_H)
@@ -413,7 +413,7 @@ $(OBJDIR)/monst.o: ../src/monst.c $(CONFIG_H)
        $(CC) $(CFLAGS) -c ../src/monst.c -o $@
 $(OBJDIR)/objects.o: ../src/objects.c $(CONFIG_H)
        $(CC) $(CFLAGS) -c ../src/objects.c -o $@
-$(OBJDIR)/dlb.o: ../src/dlb.c $(HACK_H) ../include/dlb.h
+$(OBJDIR)/dlb.o: ../src/dlb.c $(CONFIG_H) ../include/dlb.h
        $(CC) $(CFLAGS) -c ../src/dlb.c -o $@
 
 # make sure hack.h dependencies get transitive information
index 2f742399d1af28da66087177fa62bca6b0f0afb1..c515205e31342fb4afa286a816b1f861fa2a9815 100644 (file)
@@ -1,5 +1,5 @@
 #      NetHack Makefile (VMS) - for utility programs.
-#      NetHack 3.6     Makefile.utl    $NHDT-Date: 1432512790 2015/05/25 00:13:10 $    $NHDT-Branch: master $:$NHDT-Revision: 1.13 $
+#      NetHack 3.6     Makefile.utl    $NHDT-Date: 1454712071 2016/02/05 22:41:11 $    $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.14 $
 
 #  Copy this file to [.util]Makefile. and then edit it as needed.
 #  The default configuration is for building with DEC C (aka Compaq C).
@@ -331,7 +331,7 @@ $(SRC)drawing.obj : $(SRC)drawing.c $(HACK_H)
        $(MAKE)$(MAKEFLAGS) drawing.obj
       @ $(CD) $(UTL)
 
-$(SRC)dlb.obj : $(SRC)dlb.c $(HACK_H) $(INC)dlb.h
+$(SRC)dlb.obj : $(SRC)dlb.c $(CONFIG_H) $(INC)dlb.h
        $(CD) $(SRC)
        $(MAKE)$(MAKEFLAGS) dlb.obj
       @ $(CD) $(UTL)