more C standard progress
There was a transcription error in the comments in cstd.h for the standard list of header files, where only the description remained for <stdlib.h>, not the name of the file itself. Remove several extraneous inclusions of the standard C99 headers. Tested on the following afterwards: Linux (using hints/linux.370) including tty, curses, qt6, and X11 macOS (using hints/macOS.370) including tty, curses, qt5, and X11 Windows MSYS2 using sys/windows/GNUmakefile Windows Visual Studio using sys/windows/Makefile.nmake msdos cross-compile on Ubuntu using djgpp cross-compiler
This commit is contained in:
@@ -8,7 +8,6 @@
|
||||
#include "hack.h"
|
||||
#include "dlb.h"
|
||||
|
||||
#include <ctype.h>
|
||||
#include <sys/stat.h>
|
||||
#include <signal.h>
|
||||
#include <pwd.h>
|
||||
|
||||
@@ -458,18 +458,11 @@ endif
|
||||
INCLDIR=$(PDCINCL) -I../include -I../sys/msdos $(LUAINCL)
|
||||
|
||||
# Debugging
|
||||
#cflags = -pg -c $(INCLDIR) $(DLBFLG) $(CURSESDEF) -DSUPPRESS_GRAPHICS
|
||||
#cflags = -pg -c -D_NAIVE_DOS_REGS $(INCLDIR) $(DLBFLG) $(CURSESDEF) -DSUPPRESS_GRAPHICS
|
||||
#LFLAGS = -pg
|
||||
|
||||
cflags = -c -O $(INCLDIR) $(DLBFLG) $(CURSESDEF) -DSUPPRESS_GRAPHICS
|
||||
LFLAGS =
|
||||
|
||||
# Debugging
|
||||
#cflags = -g -c $(INCLDIR) $(DLBFLG) $(CURSESDEF) -DTILES_IN_GLYPHMAP
|
||||
#LFLAGS = -g
|
||||
|
||||
# Normal
|
||||
cflags = -c -O $(INCLDIR) $(DLBFLG) $(CURSESDEF) -DTILES_IN_GLYPHMAP
|
||||
cflags = -c -O -D_NAIVE_DOS_REGS $(INCLDIR) $(DLBFLG) $(CURSESDEF) -DTILES_IN_GLYPHMAP
|
||||
LFLAGS =
|
||||
|
||||
#==========================================
|
||||
|
||||
@@ -15,7 +15,6 @@
|
||||
#include "pcvideo.h"
|
||||
|
||||
#include <dos.h>
|
||||
#include <ctype.h>
|
||||
|
||||
/*
|
||||
* MS-DOS functions
|
||||
|
||||
@@ -18,10 +18,6 @@
|
||||
#include "pctiles.h"
|
||||
|
||||
/* #include <dos.h> */
|
||||
#ifndef MONITOR_HEAP
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
#include <time.h>
|
||||
|
||||
#ifdef __GO32__
|
||||
#include <unistd.h>
|
||||
|
||||
@@ -105,7 +105,6 @@ void g_pututf8(uint8 *utf8str)
|
||||
|
||||
#ifdef NO_TERMS
|
||||
|
||||
#include <ctype.h>
|
||||
#include "wintty.h"
|
||||
|
||||
#ifdef __GO32__
|
||||
|
||||
@@ -18,7 +18,6 @@
|
||||
#include "wintty.h"
|
||||
|
||||
#include <dos.h>
|
||||
#include <ctype.h>
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >= 700
|
||||
|
||||
@@ -14,7 +14,6 @@
|
||||
#include "font.h"
|
||||
|
||||
#include <dos.h>
|
||||
#include <ctype.h>
|
||||
#include "wintty.h"
|
||||
|
||||
#ifdef __GO32__
|
||||
|
||||
@@ -12,8 +12,6 @@
|
||||
#include <signal.h>
|
||||
#endif
|
||||
|
||||
#include <ctype.h>
|
||||
|
||||
#if !defined(AMIGA) && !defined(__DJGPP__)
|
||||
#include <sys\stat.h>
|
||||
#else
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
#include "hack.h"
|
||||
#include "wintty.h"
|
||||
|
||||
#include <ctype.h>
|
||||
#include <fcntl.h>
|
||||
#if !defined(MSDOS) && !defined(WIN_CE) && !defined(CROSS_TO_AMIGA)
|
||||
#include <process.h>
|
||||
|
||||
@@ -79,8 +79,14 @@ ifeq "$(WANT_DEBUG)" "1"
|
||||
pwd; echo "$(GDBEXE) not found and WANT_DEBUG=1 specified"; \
|
||||
fi; )
|
||||
else
|
||||
-rm $(TARGETPFX)pkg/GDB.EXE
|
||||
-rm $(TARGETPFX)pkg/NHGDB.BAT
|
||||
-( if [ -f $(TARGETPFX)pkg/GDB.EXE ]; \
|
||||
then \
|
||||
rm $(TARGETPFX)pkg/GDB.EXE; \
|
||||
fi; )
|
||||
-( if [ -f $(TARGETPFX)pkg/NHGDB.BAT ]; \
|
||||
then \
|
||||
rm $(TARGETPFX)pkg/NHGDB.BAT; \
|
||||
fi; )
|
||||
endif
|
||||
-touch $(TARGETPFX)pkg/RECORD
|
||||
cd $(TARGETPFX)pkg ; zip -9 ../NH370DOS.ZIP * ; cd ../../..
|
||||
|
||||
@@ -177,10 +177,12 @@ MSDOS_GPP_CFLAGS = -Wall -Wextra -Wno-missing-field-initializers -Wreturn-type \
|
||||
MSDOS_TARGET_CFLAGS = -c -O $(DBGFLAGS) -I../include -I../sys/msdos -I../win/share \
|
||||
$(LUAINCL) -DDLB $(PDCURSESDEF) -DTILES_IN_GLYPHMAP \
|
||||
-DCROSSCOMPILE -DCROSSCOMPILE_TARGET -DCROSS_TO_MSDOS \
|
||||
-D_NAIVE_DOS_REGS \
|
||||
$(MSDOS_GCC_CFLAGS)
|
||||
MSDOS_TARGET_CXXFLAGS = -c -O $(DBGFLAGS) -I../include -I../sys/msdos -I../win/share \
|
||||
$(LUAINCL) -DDLB $(PDCURSESDEF) \
|
||||
-DUSE_TILES -DCROSSCOMPILE -DCROSSCOMPILE_TARGET -DCROSS_TO_MSDOS \
|
||||
-D_NAIVE_DOS_REGS \
|
||||
$(MSDOS_GPP_CFLAGS)
|
||||
PDCINCL += -I$(PDCPORT)
|
||||
PDC_TARGET_CFLAGS = $(MSDOS_TARGET_CFLAGS) -Wno-unused-parameter \
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include "hack.h"
|
||||
#include "dlb.h"
|
||||
|
||||
#include <ctype.h>
|
||||
#include <sys/stat.h>
|
||||
#include <signal.h>
|
||||
#include <pwd.h>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
* routines or substitute for ones where we want behavior modification.
|
||||
*/
|
||||
#include "config.h"
|
||||
#include <ctype.h>
|
||||
|
||||
#ifdef VMSVSI
|
||||
#include <descrip.h>
|
||||
|
||||
@@ -20,7 +20,6 @@ struct mail_info *parse_next_broadcast(void);
|
||||
#ifdef MAIL
|
||||
#include "wintype.h"
|
||||
#include "winprocs.h"
|
||||
#include <ctype.h>
|
||||
#include <descrip.h>
|
||||
#include <errno.h>
|
||||
#ifndef __GNUC__
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
#include <stat.h>
|
||||
#undef umask
|
||||
#endif
|
||||
#include <ctype.h>
|
||||
|
||||
extern int debuggable; /* defined in vmsmisc.c */
|
||||
|
||||
|
||||
@@ -97,6 +97,8 @@ GCC_EXTRA_WARNINGS = N
|
||||
#
|
||||
#==============================================================================
|
||||
|
||||
$(info Using $(lastword $(MAKEFILE_LIST)))
|
||||
|
||||
SKIP_NETHACKW = N
|
||||
USE_LUADLL = Y
|
||||
WANT_LUAC = N
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
#error win32api.h should be included first
|
||||
#endif
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#pragma warning(disable : 4142) /* Warning, Benign redefinition of type */
|
||||
#pragma pack(8)
|
||||
@@ -37,7 +39,6 @@
|
||||
|
||||
#ifdef DEBUG
|
||||
#define _CRTDBG_MAP_ALLOC
|
||||
#include <stdlib.h>
|
||||
#include <crtdbg.h>
|
||||
#endif
|
||||
|
||||
|
||||
@@ -10,8 +10,6 @@
|
||||
#ifdef DLB
|
||||
#include "dlb.h"
|
||||
#endif
|
||||
#include <ctype.h>
|
||||
#include <stdlib.h>
|
||||
#include <sys\stat.h>
|
||||
#include <errno.h>
|
||||
#include <ShlObj.h>
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
#ifndef __BORLANDC__
|
||||
#include <direct.h>
|
||||
#endif
|
||||
#include <ctype.h>
|
||||
#ifdef TTY_GRAPHICS
|
||||
#include "wintty.h"
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user