remove some trailing whitespace

This commit is contained in:
nhmall
2020-11-25 07:23:23 -05:00
parent 7e87abb66f
commit 9ea45d7a1f
12 changed files with 166 additions and 167 deletions

View File

@@ -7,7 +7,7 @@
==============================================================
Last revision: $NHDT-Date: 1594155895 2020/07/07 21:04:55 $
Credit for the porting of NetHack to the Win32 Console Subsystem goes to
Credit for the porting of NetHack to the Win32 Console Subsystem goes to
the NT Porting Team started by Michael Allison.
Credit for the Win32 Graphical version of NetHack (aka "NetHack for
@@ -18,7 +18,7 @@ Alex Kompel, Dion Nicolaas, Yitzhak Sapir, Derek S. Ray, Michael Allison,
Pasi Kallinen, Bart House, and Janet Walz contributed to the maintainance
of the tty and graphical windows versions of NetHack 3.7.0.
You can build a TTY version of NetHack and a Windows Graphical
You can build a TTY version of NetHack and a Windows Graphical
version. You can use one of the following build environments:
o A copy of Microsoft Visual Studio 2017 Community Edition or
@@ -26,9 +26,9 @@ version. You can use one of the following build environments:
OR
o (Untested for 3.7) A copy of MinGW. MinGW is a collection of header
files and import libraries with which native Windows32 programs
can be built; the MinGW distribution contains the GNU Compiler
o (Untested for 3.7) A copy of MinGW. MinGW is a collection of header
files and import libraries with which native Windows32 programs
can be built; the MinGW distribution contains the GNU Compiler
Collection. You can download MinGW at
http://www.mingw.org/
Earlier versions of MinGW will not allow you to build the Windows
@@ -38,7 +38,7 @@ version. You can use one of the following build environments:
| Directories for a Win32 NetHack build |
\---------------------------------------------/
(NetHack-top)
|
+-----+-----+------+------+-----+----------+---------~---------+
@@ -91,18 +91,18 @@ using. Change to the directory win\win32\vs and run "build.bat".
* Optional curses window-port support *
Since 3.6.2, the community patch for a window-port that uses curses has been
incorporated into the NetHack source code tree. That window-port, which
incorporated into the NetHack source code tree. That window-port, which
evolved from work originally done by Karl Garrison, has been used in several
NetHack variants and on nethack.alt.org and on www.hardfought.org/nethack/.
If you want to include the curses window-port support in your Visual Studio
build, you will have to first obtain the PDCurses sources from
https://github.com/wmcbrine/PDCurses
and have them available prior to building NetHack. There are two ways to
enable curses window-port support during the VS build: Either set the
environment variable PDCURSES to a folder containing a PDCurses
and have them available prior to building NetHack. There are two ways to
enable curses window-port support during the VS build: Either set the
environment variable PDCURSES to a folder containing a PDCurses
repository/source-tree
OR
OR
Place the PDCurses folder alongside the NetHack source repository prior
to proceeding with steps 1 through 5 above.
@@ -114,8 +114,8 @@ to proceeding with steps 1 through 5 above.
--------------------------------------------------------------------------
-- Beginning of prerequisite step --
The first step in building either version of NetHack via Makefile is to
execute sys\winnt\nhsetup.bat to move some files to their required locations.
The first step in building either version of NetHack via Makefile is to
execute sys\winnt\nhsetup.bat to move some files to their required locations.
From the command prompt:
cd sys\winnt
@@ -138,25 +138,25 @@ command line using the Makefile approach:
NetHackW.
The executable for Console NetHack will be named NetHack.exe. The
executable for Graphical NetHack will be named NetHackW.exe. The
executable for Graphical NetHack will be named NetHackW.exe. The
Makefile configuration will build both; NetHackW.exe and NetHack.exe
will be able to use the same datafiles, save files and bones files.
Since the last official release of NetHack, compilers and computer
Since the last official release of NetHack, compilers and computer
architectures have evolved and you can now choose whether to build
a 32-bit x86 version, or a 64-bit x64 version. The default Makefile
is set up for a 32-bit x86 version, but that's only because it will
is set up for a 32-bit x86 version, but that's only because it will
run on the most number of existing Windows environments.
NetHack's save files and bones files in the 3.7.0 release have not yet
evolved enough to allow them to interchange between the 32-bit version
evolved enough to allow them to interchange between the 32-bit version
and the 64-bit version (or between different platforms). Hopefully
that will change in an upcoming release.
I. Dispelling the Myths:
Compiling NetHack for Windows is not as easy as it sounds, nor as hard
as it looks, however it will behoove you to read this entire section
as it looks, however it will behoove you to read this entire section
through before beginning the task.
We have provided a Makefile for each of the following compilers:
@@ -165,10 +165,10 @@ I. Dispelling the Myths:
The Community Editions are fine and available at no cost
o MinGW 2.0 (with GCC 3.2)
The Microsoft Visual Studio makefile was created for use
with MS NMAKE which is provided with the Microsoft compiler.
The Microsoft Visual Studio makefile was created for use
with MS NMAKE which is provided with the Microsoft compiler.
The supplied Makefile may work with earlier versions of the Microsoft
compiler, but that has not been tested.
compiler, but that has not been tested.
The GCC Makefile was created for use with GNU Make version 3.79.1,
which comes with the MinGW package.
@@ -182,41 +182,41 @@ II. To compile your copy of NetHack on a Windows machine:
Setting Up
1. It almost goes without saying that you should make sure that your
1. It almost goes without saying that you should make sure that your
tools are set up and running correctly. That includes ensuring that
all the necessary environment variables for the compiler environment
are set correctly.
are set correctly.
Change your current directory to the src subfolder of the nethack
Change your current directory to the src subfolder of the nethack
source tree.
cd src
GCC
GCC
For the GCC Makefile, add <mingw>\bin to your path, where <mingw>
For the GCC Makefile, add <mingw>\bin to your path, where <mingw>
is your MinGW root directory.).
Change your current directory to src subfolder of the nethack
Change your current directory to src subfolder of the nethack
source tree.
cd src
2. Since 3.6.2, the community patch for an optional curses window-port
has been incorporated into the NetHack source code tree. That
has been incorporated into the NetHack source code tree. That
window-port, which evolved from work originally done by Karl Garrison,
has been used in several NetHack variants and on nethack.alt.org and
on www.hardfought.org/nethack/. The optional curses window-port is
has been used in several NetHack variants and on nethack.alt.org and
on www.hardfought.org/nethack/. The optional curses window-port is
available for Windows, Mac OS X, and Unix (and also DOS).
If you want to include the optional curses window-port support in your
command line Makefile build, you will have to first obtain the
command line Makefile build, you will have to first obtain the
PDCurses sources from https://github.com/wmcbrine/PDCurses
and have that source code tree available prior to building NetHack.
Edit your Makefile and in Question 4 of the four decisions you can
Edit your Makefile and in Question 4 of the four decisions you can
make in there, uncomment these two lines:
ADD_CURSES=Y
PDCURSES_TOP=..\..\pdcurses
Adjust the PDCURSES_TOP macro so that it points to the correct
Adjust the PDCURSES_TOP macro so that it points to the correct
location for the top of the PDCurses source tree if it differs from
the path shown.
@@ -225,8 +225,8 @@ Setting Up
subdirectories dat, doc, include, src, sys\share, sys\winnt,
win\tty, util.
If you are including the optional Curses window port into your
build,then you will need the top of the PDCurses sources in a
If you are including the optional Curses window port into your
build,then you will need the top of the PDCurses sources in a
folder parallel to the top of the NetHack folder (or you will need
to change the value of the PDCURSES_TOP macro in the Makefile to
specify the appropriate location.
@@ -254,7 +254,7 @@ Compiling
5. Now that everything is set up...
For the Visual Studio compiler, as mentioned above, you should now be
at the command prompt to carry out the build and your current
at the command prompt to carry out the build and your current
directory should be the src subdirectory in the NetHack source tree.
In the src subdirectory, issue this command:
@@ -270,7 +270,7 @@ Compiling
particular machine of course, but you should be able to go for lunch
and return to find everything finished. The less memory, and slower
your machine, the longer the lunch you may take. :-)
In any case, it is likely that the command prompt window where you
are doing the compiling will be occupied for a while. If all goes
well, you will get an NetHack executable.
@@ -281,7 +281,7 @@ Notes:
your current directory to src and issue the appropriate command for
your compiler:
For Microsoft compiler:
For Microsoft compiler:
nmake
For GCC:
@@ -296,19 +296,19 @@ Notes:
have to delete dgn_flex.c, dgn_yacc.c, lev_flex.c, and lev_yacc.c
from the util directory to ensure that they are remade.
2. Depending on the build and compiler and tools used above, the
2. Depending on the build and compiler and tools used above, the
executable produced by the TTY build is either:
- a 32-bit (x86), flat-address space, non-overlayed .exe file,
- a 32-bit (x86), flat-address space, non-overlayed .exe file,
which should run on any recent Win32 environment.
or
- a 64-bit (x64) .exe file,
- a 64-bit (x64) .exe file,
which should run on any 64-bit Windows O/S.
Note that saved games are NOT compatible between the 32-bit and the
64-bit versions at this time.
NetHack.exe is the tty version. NetHackW.exe is the graphical version.
Play NetHack.
Play NetHack.
PROBLEMS

View File

@@ -34,7 +34,7 @@
#
# Build Options Decisions
#
# There are currently 4 decisions that you can choose to make.
# There are currently 4 decisions that you can choose to make.
# None of the 4 decisions are absolutely required because defaults are in place:
# 1. Where do you want your build to end up?
# 2. Do you want debug information in the executable?
@@ -92,11 +92,11 @@ TARGET_CPU=x86
#
# 4. Uncomment these and set them appropriately if you want to
# include curses port support alongside TTY support in your
# NetHack.exe binary.
# NetHack.exe binary.
#
# You'll have to set PDCURSES_H to the correct location of the
# You'll have to set PDCURSES_H to the correct location of the
# PDCurses header (.h) files and PDCURSES_C to the location
# of your PDCurses C files which must already be resident on
# of your PDCurses C files which must already be resident on
# your machine.
#
# ADD_CURSES=Y
@@ -134,7 +134,7 @@ endif
#---------------------------------------------------------------
# Location of LUA
#
# Original source needs to be obtained from:
# Original source needs to be obtained from:
# http://www.lua.org/ftp/lua-5.4.1.tar.gz
#
# This build assumes that the LUA sources are located
@@ -185,8 +185,8 @@ NHV=$(subst ",,$(NHV1))
# MSWSYS - mswin specific files
# TTY - window port files (tty)
# MSWIN - window port files (win32)
# WCURSES - window port files (curses)
# WSHR - Tile support files
# WCURSES - window port files (curses)
# WSHR - Tile support files
# QT - QT window support files
INCL =../include
@@ -303,13 +303,13 @@ PPMWRITERS = $(O)ppmwrite.o $(O)alloc.o $(O)panic.o
#
VOBJ01 = $(O)allmain.o $(O)alloc.o $(O)apply.o $(O)artifact.o
VOBJ02 = $(O)attrib.o $(O)ball.o $(O)bones.o $(O)botl.o
VOBJ03 = $(O)cmd.o $(O)dbridge.o $(O)decl.o $(O)detect.o
VOBJ04 = $(O)dig.o $(O)display.o $(O)do.o $(O)do_name.o
VOBJ05 = $(O)do_wear.o $(O)dog.o $(O)dogmove.o $(O)dokick.o
VOBJ06 = $(O)dothrow.o $(O)drawing.o $(O)dungeon.o $(O)eat.o
VOBJ07 = $(O)end.o $(O)engrave.o $(O)exper.o $(O)explode.o
VOBJ08 = $(O)extralev.o $(O)files.o $(O)fountain.o $(O)hack.o
VOBJ02 = $(O)attrib.o $(O)ball.o $(O)bones.o $(O)botl.o
VOBJ03 = $(O)cmd.o $(O)dbridge.o $(O)decl.o $(O)detect.o
VOBJ04 = $(O)dig.o $(O)display.o $(O)do.o $(O)do_name.o
VOBJ05 = $(O)do_wear.o $(O)dog.o $(O)dogmove.o $(O)dokick.o
VOBJ06 = $(O)dothrow.o $(O)drawing.o $(O)dungeon.o $(O)eat.o
VOBJ07 = $(O)end.o $(O)engrave.o $(O)exper.o $(O)explode.o
VOBJ08 = $(O)extralev.o $(O)files.o $(O)fountain.o $(O)hack.o
VOBJ09 = $(O)hacklib.o $(O)insight.o $(O)invent.o $(O)isaac64.o
VOBJ10 = $(O)light.o $(O)lock.o $(O)mail.o $(O)makemon.o
VOBJ11 = $(O)mapglyph.o $(O)mdlib.o $(O)mcastu.o $(O)mhitm.o
@@ -350,7 +350,7 @@ CURSESOBJ=
endif
SOBJ = $(O)windmain.o $(O)winnt.o $(O)win10.o \
$(O)safeproc.o $(O)nhlan.o $(SOUND)
$(O)safeproc.o $(O)nhlan.o $(SOUND)
OBJS = $(VOBJ01) $(VOBJ02) $(VOBJ03) $(VOBJ04) $(VOBJ05) \
$(VOBJ06) $(VOBJ07) $(VOBJ08) $(VOBJ09) $(VOBJ10) \
@@ -476,7 +476,7 @@ PDCLIB = $(O)pdcurses.a
PDCINCL = -I$(PDCURSES_TOP) -I$(PDCSRC) -I$(PDCWINCON)
else
PDCLIB =
PDCLIB =
endif
#==========================================
@@ -742,7 +742,7 @@ SHELL=CMD.EXE
# Since DOS doesn't allow / as path separator, and GCC doesn't allow \ as
# path separator, we must change all pathnames when performing DOS commands.
# This is done by blindly applying $(subst /,\, ...) on every command.
# Where any command contain / for another reason (switch char, a little
# Where any command contain / for another reason (switch char, a little
# more care is taken.
#
@@ -794,7 +794,7 @@ recover: $(U)recover.exe
$(subst /,\,if exist $(U)recover.exe copy $(U)recover.exe $(GAMEDIR))
$(subst /,\,if exist $(DOC)/recover.txt copy $(DOC)/recover.txt $(GAMEDIR)/recover.txt)
$(O)sp_lev.tag: $(O)utility.tag
$(O)sp_lev.tag: $(O)utility.tag
$(subst /,\,echo sp_levs done > $(O)sp_lev.tag)
$(O)utility.tag: $(INCL)/date.h $(INCL)/onames.h $(INCL)/pm.h \
@@ -819,7 +819,7 @@ $(O)winres.o: $(TILEBMP16) $(MSWIN)/NetHackW.rc $(MSWIN)/mnsel.bmp \
$(MSWIN)/splash.bmp
$(rc) -o$@ --include-dir $(MSWIN) -i $(MSWIN)/NetHackW.rc
$(O)conres.o: $(MSWSYS)/console.rc $(MSWSYS)/NetHack.ico
$(O)conres.o: $(MSWSYS)/console.rc $(MSWSYS)/NetHack.ico
$(rc) -o$@ --include-dir $(MSWSYS) -i $(MSWSYS)/console.rc
#==========================================
@@ -858,7 +858,7 @@ $(GAMEDIR)/NetHackW.exe : gamedir.tag $(PDCLIB) $(O)tile.o $(O)ttystub.o \
endif
$(O)nhdefkey.o:
$(cc) $(CFLAGS) -DBUILD_DLL -o$@ $(MSWSYS)/nhdefkey.c
$(cc) $(CFLAGS) -DBUILD_DLL -o$@ $(MSWSYS)/nhdefkey.c
$(GAMEDIR)/nhdefkey.dll : $(O)nhdefkey.o gamedir.tag
@echo Linking $@
@@ -866,7 +866,7 @@ $(GAMEDIR)/nhdefkey.dll : $(O)nhdefkey.o gamedir.tag
-Wl,--add-stdcall-alias -o $@ $<
$(O)nh340key.o:
$(cc) $(CFLAGS) -DBUILD_DLL -o$@ $(MSWSYS)/nh340key.c
$(cc) $(CFLAGS) -DBUILD_DLL -o$@ $(MSWSYS)/nh340key.c
$(GAMEDIR)/nh340key.dll : $(O)nh340key.o gamedir.tag
@echo Linking $@
@@ -874,7 +874,7 @@ $(GAMEDIR)/nh340key.dll : $(O)nh340key.o gamedir.tag
-Wl,--add-stdcall-alias -o $@ $<
$(O)nhraykey.o:
$(cc) $(CFLAGS) -DBUILD_DLL -o$@ $(MSWSYS)/nhraykey.c
$(cc) $(CFLAGS) -DBUILD_DLL -o$@ $(MSWSYS)/nhraykey.c
$(GAMEDIR)/nhraykey.dll : $(O)nhraykey.o gamedir.tag
@echo Linking $@
@@ -1163,7 +1163,7 @@ $(O)til2bm32.o: $(WSHR)/til2bm32.c $(HACK_H) $(TILE_H) $(MSWSYS)/win32api.h
$(O)pdcurses.a : $(PDCLIBOBJS) $(PDCOBJS)
ar rcs $@ $(PDCLIBOBJS) $(PDCOBJS)
#=============================================================
# LUA
#=============================================================
@@ -1352,7 +1352,7 @@ $(O)tile.o: $(SRC)/tile.c $(HACK_H)
$(O)panic.o: $(U)panic.c $(CONFIG_H)
$(cc) $(CFLAGS) -o$@ $(U)panic.c
#
#
# sys/share dependencies
#
@@ -1361,7 +1361,7 @@ $(O)panic.o: $(U)panic.c $(CONFIG_H)
#
# Other dependencies needed by some ports
#
#
ifeq "$(ADD_CURSES)" "Y"
# curses window port dependencies
@@ -1418,7 +1418,7 @@ endif
# with -o$@
# * targets prefixed with $(O)
# * $(CC) changed to $(cc)
# but otherwise untouched.
# but otherwise untouched.
# That means that there is some irrelevant stuff
# in here, but maintenance should be easier.
#

View File

@@ -4,7 +4,7 @@
#==============================================================================
# Build Tools Environment
#
# NetHack 3.7 Work-in-progress Makefile for
# NetHack 3.7 Work-in-progress Makefile for
# MS Visual Studio Visual C++ compiler
#
# Visual Studio Compilers Tested:
@@ -22,11 +22,11 @@
#
# BEFORE YOU START, in addition to your C compiler and linker,
#
# o You will need a complete Lua source tree parallel to your
# o You will need a complete Lua source tree parallel to your
# NetHack source tree. Lua is not an optional requirement,
# it is required in order to process the level and dungeon
# description files during the game. You can obtain the
# Lua source from here:
# description files during the game. You can obtain the
# Lua source from here:
# https://www.lua.org/download.html
#
# o If you want to include the curses Window port in the non-GUI
@@ -37,7 +37,7 @@
# or via git from here:
# git clone https://github.com/wmcbrine/PDCurses.git ../pdcurses
#
# o If you want your build of NetHack to include support for
# o If you want your build of NetHack to include support for
# compressing your save files, or to be able to exchange and use
# compressed save files that originated on another platform such
# as Linux or a handheld phone or tablet, then you will need
@@ -60,16 +60,16 @@
#
# Build Options Decisions
#
# There are currently 5 decisions that you can choose to make.
# none of the 5 decisions are absolutely required because defaults
# There are currently 5 decisions that you can choose to make.
# none of the 5 decisions are absolutely required because defaults
# are in place:
#
# 1. Where do you want your build results to end up?
# 2. Do you want to include the optional curses port?
# 3. Do you want to include compressed savefile support to
# 3. Do you want to include compressed savefile support to
# transfer compressed savefiles between platforms?
# 4. Do you want debug information in the executable?
# 5. Do you want to explicitly override auto-detection of
# 5. Do you want to explicitly override auto-detection of
# a 32-bit or 64-bit target?
#
# Mandatory Lua source Location (not optional)
@@ -88,13 +88,13 @@
GAMEDIR = ..\binary # Default game build directory
#
#------------------------------------------------------------------------------
# OPTIONAL - Curses window port support
# OPTIONAL - Curses window port support
#
# 2. Uncomment these and set them appropriately if you want to
# include curses port support alongside TTY support in your
# NetHack.exe binary.
# NetHack.exe binary.
#
# You'll have to set PDCURSES_H to the correct location of the
# You'll have to set PDCURSES_H to the correct location of the
# PDCurses header (.h) files and PDCURSES_C to the location
# of your PDCurses C files.
#
@@ -112,13 +112,13 @@ GAMEDIR = ..\binary # Default game build directory
#
#------------------------------------------------------------------------------
# 4. Do you want debug information available to the executable?
#
#
DEBUGINFO = Y
#
#------------------------------------------------------------------------------
# 5. This Makefile will attempt to auto-detect your selected target architecture
# based on Visual Studio command prompt configuration settins etc.
# However, if you want to manually override generation of a
# However, if you want to manually override generation of a
# 32-bit or 64-bit build target, you can uncomment the apppropriate
# TARGET_CPU line below.
#
@@ -139,7 +139,7 @@ LUAVER=$(LUA_VERSION)
#
# Location of LUA
#
# Original source needs to be obtained from:
# Original source needs to be obtained from:
# http://www.lua.org/ftp/lua-5.4.1.tar.gz
#
# This build assumes that the LUA sources are located
@@ -187,8 +187,8 @@ SSYS = ..\sys\share # Shared system files
MSWSYS = ..\sys\winnt # mswin specific files
TTY = ..\win\tty # window port files (tty)
MSWIN = ..\win\win32 # window port files (win32)
WCURSES = ..\win\curses # window port files (curses)
WSHR = ..\win\share # Tile support files
WCURSES = ..\win\curses # window port files (curses)
WSHR = ..\win\share # Tile support files
QT = ..\win\Qt # QT support files
X11 = ..\win\X11 # X11 support files
@@ -202,8 +202,7 @@ OBJ = o
#==========================================
# Exe File Info.
#==========================================
#
#
# Optional high-quality BSD random number generation routines
# (see pcconf.h). Set to nothing if not used.
@@ -292,13 +291,13 @@ PPMWRITERS = $(O)ppmwrite.o $(O)alloc$(HOST).o $(O)panic$(HOST).o
#
VOBJ01 = $(O)allmain.o $(O)alloc.o $(O)apply.o $(O)artifact.o
VOBJ02 = $(O)attrib.o $(O)ball.o $(O)bones.o $(O)botl.o
VOBJ03 = $(O)cmd.o $(O)dbridge.o $(O)decl.o $(O)detect.o
VOBJ04 = $(O)dig.o $(O)display.o $(O)do.o $(O)do_name.o
VOBJ05 = $(O)do_wear.o $(O)dog.o $(O)dogmove.o $(O)dokick.o
VOBJ06 = $(O)dothrow.o $(O)drawing.o $(O)dungeon.o $(O)eat.o
VOBJ07 = $(O)end.o $(O)engrave.o $(O)exper.o $(O)explode.o
VOBJ08 = $(O)extralev.o $(O)files.o $(O)fountain.o $(O)hack.o
VOBJ02 = $(O)attrib.o $(O)ball.o $(O)bones.o $(O)botl.o
VOBJ03 = $(O)cmd.o $(O)dbridge.o $(O)decl.o $(O)detect.o
VOBJ04 = $(O)dig.o $(O)display.o $(O)do.o $(O)do_name.o
VOBJ05 = $(O)do_wear.o $(O)dog.o $(O)dogmove.o $(O)dokick.o
VOBJ06 = $(O)dothrow.o $(O)drawing.o $(O)dungeon.o $(O)eat.o
VOBJ07 = $(O)end.o $(O)engrave.o $(O)exper.o $(O)explode.o
VOBJ08 = $(O)extralev.o $(O)files.o $(O)fountain.o $(O)hack.o
VOBJ09 = $(O)hacklib.o $(O)insight.o $(O)invent.o $(O)isaac64.o
VOBJ10 = $(O)light.o $(O)lock.o $(O)mail.o $(O)makemon.o
VOBJ11 = $(O)mapglyph.o $(O)mcastu.o $(O)mhitm.o $(O)mhitu.o
@@ -341,7 +340,7 @@ CURSESOBJ= $(O)cursdial.o $(O)cursinit.o $(O)cursinvt.o $(O)cursmain.o \
!ENDIF
SOBJ = $(O)windmain.o $(O)winnt.o $(O)win10.o \
$(O)safeproc.o $(O)nhlan.o $(SOUND)
$(O)safeproc.o $(O)nhlan.o $(SOUND)
OBJS = $(MDLIB) \
$(VOBJ01) $(VOBJ02) $(VOBJ03) $(VOBJ04) $(VOBJ05) \
@@ -472,7 +471,7 @@ PDCLIB = $(O)pdcurses.lib
PDCINCL = /I$(PDCURSES_TOP) /I$(PDCSRC) /I$(PDCWINCON)
!ELSE
PDCLIB =
PDCLIB =
!ENDIF
#==========================================
@@ -532,15 +531,15 @@ CTAGSOPT =--language-force=c --sort=no -D"Bitfield(x,n)=unsigned x : n" --excmd=
#
TINC = $(INCL:\=/)
TSRC = $(SRC:\=/)
cc=cl
cpp=cpp
link=link
rc=Rc
# Before we get started, this section is used to determine the version of
# Visual Studio we are using. We set VSVER to 0000 to flag any version that
# Before we get started, this section is used to determine the version of
# Visual Studio we are using. We set VSVER to 0000 to flag any version that
# is too old or untested.
#
#NMAKE version 1428293340 from latest VS 2019 (November 19, 2020 version 16.8.2)
@@ -855,26 +854,26 @@ install: $(INCL)\nhlua.h $(O)envchk.tag $(O)obj.tag $(O)utility.tag $(GAMEDIR)\N
# Main game targets.
#==========================================
# The section for linking the NetHack image looks a little strange at
# first, especially if you are used to UNIX makes, or NDMAKE. It is
# Microsoft nmake specific, and it gets around the problem of the
# link command line being too long for the linker. An "in-line" linker
# The section for linking the NetHack image looks a little strange at
# first, especially if you are used to UNIX makes, or NDMAKE. It is
# Microsoft nmake specific, and it gets around the problem of the
# link command line being too long for the linker. An "in-line" linker
# response file is generated temporarily.
#
# It takes advantage of the following features of nmake:
#
# Inline files :
# Inline files :
# Specifying the "<<" means to start an inline file.
# Another "<<" at the start of a line closes the
# Another "<<" at the start of a line closes the
# inline file.
#
# Substitution within Macros:
# $(mymacro:string1=string2) replaces every
# occurrence of string1 with string2 in the
# macro mymacro. Special ascii key codes may be
# used in the substitution text by preceding it
# occurrence of string1 with string2 in the
# macro mymacro. Special ascii key codes may be
# used in the substitution text by preceding it
# with ^ as we have done below. Every occurence
# of a <tab> in $(ALLOBJ) is replaced by
# of a <tab> in $(ALLOBJ) is replaced by
# <+><return><tab>.
GAMEOBJ=$(ALLOBJ:^ =^
@@ -891,7 +890,7 @@ GAMEOBJ=$(GAMEOBJ:^ =^
# libs: $(LIBS) $(conlibs) $(guilibs) $(COMCTRL)
# objs: $(GAMEOBJ) $(TTYOBJ) $(O)nttty.o $(O)tile.o $(GUIOBJ)
# otherwise:
# libs: $(LIBS) $(conlibs)
# libs: $(LIBS) $(conlibs)
# objs: $(GAMEOBJ) $(TTYOBJ) $(O)tile.o $(O)guistub.o
@@ -1033,7 +1032,7 @@ $(O)utility.tag: $(INCL)\nhlua.h $(INCL)\date.h $(INCL)\onames.h $(INCL)\pm.h \
@echo utilities made >$@
@echo utilities made.
$(INCL)\nhlua.h:
$(INCL)\nhlua.h:
@echo /* nhlua.h - generated by Makefile */ > $@
@echo #include "../lib/lua-$(LUAVER)/src/lua.h" >> $@
@echo LUA_API int (lua_error) (lua_State *L) NORETURN; >> $@
@@ -1056,7 +1055,7 @@ $(O)console.res: $(MSWSYS)\console.rc $(MSWSYS)\NetHack.ico
#
# Secondary Targets.
#
#==========================================
# Makedefs Stuff
#==========================================
@@ -1112,12 +1111,12 @@ $(U)uudecode.exe: $(O)uudecode.o
$(O)uudecode.o: $(SSYS)\uudecode.c
@$(cc) $(cflagsBuild) $(CROSSCOMPILE) /D_CRT_SECURE_NO_DEPRECATE -Fo$@ $(SSYS)\uudecode.c
$(MSWSYS)\NetHack.ico : $(U)uudecode.exe $(MSWSYS)\nhico.uu
$(MSWSYS)\NetHack.ico : $(U)uudecode.exe $(MSWSYS)\nhico.uu
chdir $(MSWSYS)
..\..\util\uudecode.exe nhico.uu
chdir ..\..\src
$(MSWIN)\NetHack.ico : $(U)uudecode.exe $(MSWSYS)\nhico.uu
$(MSWIN)\NetHack.ico : $(U)uudecode.exe $(MSWSYS)\nhico.uu
chdir $(MSWIN)
..\..\util\uudecode.exe ../../sys/winnt/nhico.uu
chdir ..\..\src
@@ -1493,7 +1492,7 @@ $(O)curswins.o: $(WCURSES)\curswins.c $(WCURSES)\curswins.h $(INCL)\wincurs.h
$(O)sfstruct.o: $(HACK_H) $(SRC)\sfstruct.c
# @$(cc) $(cflagsBuild) -Fo$@ $(SRC)\sfstruct.c
#===============================================================================
# CROSSCOMPILE
#===============================================================================
@@ -1688,10 +1687,10 @@ clean:
# OTHER DEPENDENCIES
#===================================================================
#
# The rest are stolen from sys/unix/Makefile.src,
# The rest are stolen from sys/unix/Makefile.src,
# with the following changes:
# * ../include changed to $(INCL)
# * slashes changed to back-slashes
# * slashes changed to back-slashes
# * -c (which is included in CFLAGS) substituted with -Fo$@
# * $(CFLAGS) replaced with $(cflagsBuild)
# * $(CC) replaced with @$(cc)