Commit graph

13 commits

Author SHA1 Message Date
John "Elwin" Edwards
338214459d Fix a portability issue with md_hasclreol().
Some games' implementation of md_hasclreol() poked around in ncurses
internals, which does not work for some ncurses build configuration.
Most games did not actually call md_hasclreol(), so it was removed.
There is a standard terminfo function which can retrieve the value of
the clr_eol capability, so this was used for rogue5.
2017-12-27 10:26:06 -05:00
John "Elwin" Edwards
62047972cc Use more portable random seed generation.
The new function md_random_seed() has replaced time() + getpid() and
similar methods.  Putting everything in mdport.c slightly reduces the
warnings and workarounds.
2017-01-28 15:49:41 -05:00
John "Elwin" Edwards
a6c73eb65a Fix various overlooked causes of warnings.
GCC5 now produces under 300 lines of warnings, but the remaining ones
will require more complex solutions.
2016-03-06 21:02:59 -05:00
John "Elwin" Edwards
0a354903e0 Daemons and fuses now return void.
Functions for starting and stopping daemons and fuses now expect the
type 'void (*func)()'.  Only a few functions in XRogue needed to be
modified to fit.  Determining the type of the argument is left for a
later date.

Building with GCC5 should now produce less than 200 lines of warnings
per game.
2016-03-05 20:49:37 -05:00
John "Elwin" Edwards
268b30f851 srogue: provide type definitions if needed.
If not defined in headers, uid_t and gid_t will be defined as
unsigned ints, and pid_t as int.
2015-08-03 21:29:16 -04:00
John "Elwin" Edwards
3b34109c93 srogue: clean up configuration in mdport.c.
curses.h is already included in rogue.h and doesn't need to be included
twice more in mdport.c.

Also set flags for some features when they are present.
2015-08-03 17:16:42 -04:00
John "Elwin" Edwards
00142507db srogue: add and use md_fdopen().
The implementation was copied from rogue4.  Using fdopen() is necessary
because the scorefile needs both encread() and encwrite().  For some
reason I have failed to discover, one of them uses FILE *'s and the
other uses file descriptors.
2015-08-03 09:27:43 -04:00
John "Elwin" Edwards
3c781f89fe srogue: remove md_droppriv() and md_resetpriv().
These partial privilege-dropping functions are no longer needed.
2015-08-01 16:31:03 -04:00
John "Elwin" Edwards
120beada5a srogue: more compatibility improvements.
Randomness now uses mdport, and xcrypt.c has been replaced with the
rogue5 version.

Super-Rogue now builds on MinGW.
2014-05-03 10:31:30 -07:00
John "Elwin" Edwards
b9cc9cf3a7 srogue: add and use more md_* portable functions.
Privileges and memory usage checks are now more portable.
2014-05-02 15:06:23 -07:00
John "Elwin" Edwards
de1e0f2759 srogue: add a complete mdport.c.
srogue/mdport.c is copied from rogue5/mdport.c, with slight changes.
2014-04-27 08:29:14 -07:00
John "Elwin" Edwards
35a6ab583c srogue: begin porting to autoconf.
Super-Rogue can now be built with './configure && make', though
'make install' does not work yet, and there may be problems with
portability.
2013-09-01 20:50:52 -07:00
John "Elwin" Edwards
ce4b930551 Import Super-Rogue 9.0 from the Roguelike Restoration Project (r1490) 2010-11-25 12:21:41 +00:00