Commit Graph

299 Commits

Author SHA1 Message Date
PatR
d69f0787be add '(uchar)' casts to ctype calls
This is from the pull request for the assertion failure fix.  It
did not mention how to reproduce the assertion failure, just added
casts to a bunch of isspace/isprint/tolower calls that didn't already
have such.

I removed an obsolete change for win/tty/topl.c and changed the
win/win32/mswproc.c code to avoid using an expression with side-effects
(*colorstring++) in calls to tolower() in case someone overrides that
with a macro which evaluates its argument more than once as some pre-
ANSI ones used to do.  Not tested, might have typos....

sys/wince/*.c still needs similar casts.
2016-07-19 05:40:09 -07:00
nhmall
78857961d2 some of Ray Chason's MSDOS and other fixes 2016-03-05 14:44:50 -05:00
nhmall
297d4d11e7 ensure raw_printf has visible output
Changes to be committed:
	modified:   sys/winnt/nttty.c
2016-02-01 21:57:35 -05:00
nhmall
5774804524 typo bit nttty.c 2016-01-31 18:16:13 -05:00
nhmall
37b79d68cd some updates to nttty.c
Changes to be committed:
	modified:   sys/winnt/nttty.c

better attribute support
more functional inverse support
2016-01-31 18:08:03 -05:00
Alex Kompel
c4bf762ec1 win32_gui: mimic tty interface when "Nethack mode" is selected (remove window features) 2016-01-03 19:52:05 -08:00
nhmall
14ce76a159 windows visual studio 2013 build updates 2016-01-01 22:01:25 -05:00
nhmall
4566b2903f windows: PDB files in Debug and Release 2015-12-31 20:16:48 -05:00
nhmall
fa092f5fe9 housekeeping for 3.6.1
Changes to be committed:
	modified:   Files
	modified:   README
	modified:   dat/history
	modified:   doc/Guidebook.mn
	modified:   doc/Guidebook.tex
	modified:   include/global.h
	modified:   include/obj.h
	modified:   include/patchlevel.h
	modified:   src/invent.c
	modified:   src/objnam.c
	modified:   src/shknam.c
	modified:   src/sounds.c
	modified:   src/spell.c
	modified:   sys/winnt/Install.nt
	modified:   sys/winnt/nethack.def
	modified:   win/macosx/NetHackGuidebook.applescript
	modified:   win/macosx/NetHackTerm.applescript
	modified:   win/win32/mswproc.c
2015-12-16 17:52:34 -05:00
nhmall
215060219d fix windows bugs H4030 and H4045 (123 and 138)
Changes to be committed:
	modified:   sys/share/pcmain.c
	modified:   sys/winnt/nttty.c
	modified:   sys/winnt/stubs.c

Bug 123 Report 4030:
Minor thing I've noticed - if I quit the game, at the "Hit <Enter> to end."
prompt, if I close the window rather than pressing Enter, I get the following:

Bug 138  - #H4045:
 "nethack -s" leads to "-s is not supported for the Graphical Interface".
 That's wrong.
 (The Graphical Interface comes with "nethackw".)
2015-12-11 23:08:01 -05:00
nhmall
d46a80b1c5 nmake Makefile updates 2015-11-19 23:12:20 -05:00
nhmall
93cd299b69 nmake output status messages
Changes to be committed:
	modified:   sys/winnt/Makefile.msc

I've noticed odd output from some of the echo statements
used in the Microsoft nmake Makefile before, but never
bothered to investigate why.

Pat observed that it was due to conversion of \t
in the path that resulted from expansion of the target
macro $@

This change uses the macro character substitution
feature to convert the back slashes to forward slashes
in the message, making the quirky conversion go away.
2015-11-19 22:35:49 -05:00
nhmall
7d23420314 another typo 2015-11-19 19:36:14 -05:00
nhmall
b6ce68865a typo fix and some elaboration
Changes to be committed:
	modified:   sys/winnt/Install.nt
2015-11-19 19:28:39 -05:00
nhmall
43628124a4 Windows build updates 2015-11-19 18:57:17 -05:00
nhmall
889f600aa8 Windows x64 Makefile build work 2015-11-19 07:58:58 -05:00
nhmall
014856397b undo unintended default build architecture change
Changes to be committed:
	modified:   sys/winnt/Makefile.msc

Previous patch altered more than intended.
2015-11-18 23:12:39 -05:00
nhmall
d41e4d5ab4 Ensure VS2013 64-bit compiler drops to warning level -W3
This doesn't fix the cppregex.cpp issue. This just eliminates
about 10,000 warnings.
2015-11-18 22:41:30 -05:00
nhmall
38080e921f Windows 10 2015-11-11 09:20:19 -05:00
nhmall
ab5496cdbc Makefile typo 2015-07-18 09:02:54 -04:00
nhmall
26baa53f2b project count (visual studio instructions) 2015-06-20 09:21:13 -04:00
nhmall
6be4506fb6 more windows instruction cleanup 2015-06-20 09:00:20 -04:00
nhmall
4a9953ae0d more pilemark and win32 changes
Changes to be committed:
	modified:   Files
	deleted:    sys/winnt/Makefile.bcc
	modified:   sys/winnt/Makefile.gcc
	modified:   win/win32/winMS.h

Since borland Makefile isn't operational, remove it for
this release as recommended.

Changes to install.nt pending.
2015-06-20 08:50:32 -04:00
nhmall
07f6dec128 try to add pilemark support
Changes to be committed:
	modified:   Files
	modified:   sys/winnt/Makefile.msc
	modified:   win/win32/mhmap.c
	new file:   win/win32/pilemark.uu
	modified:   win/win32/resource.h
	modified:   win/win32/winMS.h
	modified:   win/win32/winhack.rc
2015-06-14 18:33:32 -04:00
nhmall
5e913f90f8 Makefile typos in sys/winnt/Makfile.msc 2015-06-12 15:42:41 -04:00
Alex Kompel
4083abe286 offer perm_invent as "personal preference" option 2015-06-02 19:20:41 -07:00
nhmall
04c9fa151f defaults.nh update 2015-06-02 17:41:13 -04:00
nhmall
53363e05b9 add missing tile and correct clobbered header file 2015-05-24 21:10:22 -04:00
Sean Hunt
1c081b1647 Remove stale version control lines. 2015-05-25 09:21:31 +09:00
Sean Hunt
8b57d96fd2 Reformat .h files.
I did my best to exempt some of the bigger aligned blocks from the reformatting
using the /* clang-format off */ and /* clang-format on */ tags. Probably some
that shouldn't have been formatted were anyway; if you encounter them, please
fix.

The clang-format tags were left in on the basis that it's much easier to prune
those out later than to put them back in, and it means that, modulo my custom
version of clang-format, I should be able to run clang-format on the source tree
again without changing anything, now that Pat has fixed the VA_DECL issues.
2015-05-25 09:21:15 +09:00
PatR
fabf9cd901 VA_DECL/VA_END usage
Make the variadic functions look more like ordinary code rather than
have the function opening brace be hidden inside the VA_DECL() macro.
That brace is still there, but VA_DECL() now needs to be followed by
a visible brace (which introduces a nested block rather than the
start of the funciton).  VA_END() now provides a hidden closing brace
to end the nested block, and the existing closing brace still matches
the one in VA_DECL().

Sample usage:
void foo VA_DECL(int, arg)  --macro expansion has a hidden opening brace
{  --new, explicit opening brace (actually introduces a nested block)
  VA_START(bar);
  ...code for foo...
  VA_END();  --expansion now provides a closing brace for the nested block
}  --existing closing brace, still pairs with the hidden one in VA_DECL()

This should help if/when another round of reformatting ever takes place,
and also with editors or other tools that do brace/bracket/parenthesis
matching.

I had forgotten that there were variadic functions in sys/* and ended
up modifying a lot more files than intended.  The majority of changes
to those just inserted a new '{' line so that revised VA_END()'s '}'
won't introduce a syntax error.  A couple of them needed VA_END() moved
so that local variables wouldn't go out of scope too soon.  Only the
Unix ones have been tested.
2015-05-15 17:45:21 -07:00
Sean Hunt
97d6fade74 Reformat all C files.
I'll push a formatting guide at some point. There may still be
outstanding changes, but please feel free to resolve those as you arrive
a them.

To the best of my knowledge, there is no changes to the actual code
content, but the formatter does have the occasional bug. If you run into
an issue, please fix it!
2015-05-09 13:43:16 -04:00
nhmall
2eed004d5a more header update
Changes to be committed:
	modified:   sys/winnt/nttty.c
	modified:   sys/winnt/winnt.c
2015-05-07 04:55:05 -04:00
nhmall
20069798d4 Merge branch 'master' into win32-x64-working 2015-05-07 04:52:30 -04:00
Sean Hunt
8c0c587fd7 Restore lost executable bits. 2015-05-06 23:23:48 -04:00
karnov
2a907f894e Version number increment 2015-05-06 22:04:27 -04:00
nhmall
8a620c3dec makefile updates 2015-05-06 20:22:03 -04:00
nhmall
fc102a860b updates forced from master
Changes to be committed:
	modified:   sys/winnt/Makefile.bcc
	modified:   sys/winnt/Makefile.gcc
	modified:   sys/winnt/Makefile.msc
2015-05-06 20:07:18 -04:00
Dion Nicolaas
3f859dd826 Some work on the BCC make file.
This is still not complete; the linker is complaining for both builds (NetHack and NetHackW.)
Also, the change to make it build both versions wasn't done yet.
2015-05-02 14:02:10 +02:00
Dion Nicolaas
701fa5afea Make nhsetup switch to the right directory always, and improve detection of double-click 2015-04-26 19:17:04 +02:00
nhmall
89c862b15a fix typo in typo fix 2015-04-22 21:44:04 -04:00
Alex Kompel
cd72c7ec68 win32: fix broken dependency for ttystub.o 2015-04-22 18:12:14 -07:00
nhmall
3238303dc8 replace a couple of Makefile bits that shouldn't have been removed
Changes to be committed:
	modified:   sys/winnt/Makefile.gcc
	modified:   sys/winnt/Makefile.msc
2015-04-22 00:30:03 -04:00
nhmall
aaca36a6d5 build both tty NetHack.exe and gui NetHackW.exe
Changes to be committed:
	modified:   include/config.h
	modified:   include/extern.h
	modified:   include/flag.h
	modified:   include/global.h
	modified:   include/ntconf.h
	modified:   include/wintty.h
	modified:   src/cmd.c
	modified:   src/files.c
	modified:   src/options.c
	modified:   sys/share/pcmain.c
	modified:   sys/share/pcsys.c
	modified:   sys/share/pcunix.c
	modified:   sys/winnt/Makefile.gcc
	modified:   sys/winnt/Makefile.msc
	modified:   sys/winnt/nttty.c
	new file:   sys/winnt/stubs.c
	modified:   sys/winnt/winnt.c
	modified:   util/makedefs.c
	modified:   win/tty/wintty.c

Adjust the code and the command line Makefile so that
you no longer have to choose whether to build the tty
version NetHack.exe, or the gui version NetHackW.exe.

Both will now be built in a single 'nmake install' pass.
2015-04-22 00:07:46 -04:00
nhmall
0147b40ec7 Makefile bit
NMAKE : fatal error U1073: don't know how to make 'tile.c'
2015-04-19 13:51:47 -04:00
Dion Nicolaas
6457e8bf13 Change Makefile.gcc to bring it more in line with Makefile.msc 2015-04-18 13:31:30 +02:00
Dion Nicolaas
0c4573d82a fix tile2bmp build under mingw. Provide alternatives for Microsoft-specific macros. Be consistent about slashes in gcc Makefile. Don't include shlwapi.h for any compiler. 2015-04-16 22:36:06 +02:00
nhmall
1354215b97 Makefile bit 2015-04-14 20:45:18 -04:00
nhmall
0c769146ba gcc Makefile updates for recent file additions 2015-04-14 20:24:52 -04:00
nhmall
1e388fc1b9 update Makefile.gcc
Changes to be committed:
	modified:   sys/winnt/Makefile.gcc
2015-04-14 20:18:19 -04:00