Rename sys_linux.c to sys_unix.c, which is more accurate. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12783 d7cf8633-e32d-0410-b094-e92efae38249
Comply with ISO C11. Engine will now compile with -pedantic, w/o extra warnings But don't actually use -std=c11 because computed gotos is a gcc extension that makes the QCVM 30 percent faster in all situations. c11 obviously disables gcc extensions. But this is a nice thing to achieve as far as portability is concerned. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12756 d7cf8633-e32d-0410-b094-e92efae38249
Remove Con_Warnf and Errorf. Use macros to change color and identify the message git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12744 d7cf8633-e32d-0410-b094-e92efae38249
Organize system and host globals into structs. Implement host state tracking git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12691 d7cf8633-e32d-0410-b094-e92efae38249
Implement Con_Error(f) and Con_Warn(f), error and warning, for prettier colors Replace Con_Print(f) for most of the obvious cases. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12575 d7cf8633-e32d-0410-b094-e92efae38249
Make Sys_Error message more generic. Quake -> Engine git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12551 d7cf8633-e32d-0410-b094-e92efae38249
Rollback last change which was meant to be many smaller pieces. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12291 d7cf8633-e32d-0410-b094-e92efae38249
Added developer_memorylargerthanmb cvar which dprints notices about very large memory allocations (16MB and larger by default). Slightly improved the Mem_Alloc out of memory error to include the size of the failed allocation. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12290 d7cf8633-e32d-0410-b094-e92efae38249
Fixed a large number of WIN64 type conversion warnings. Changed FS_Write to do multiple write calls if the size exceeds 1GB, this is to accommodate WIN64 where write() takes a UINT rather than size_t. We have no use of such large writes at this time, so this is a mostly theoretical feature. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12081 d7cf8633-e32d-0410-b094-e92efae38249
sys_linux, sys_sdl: support options -noterminal and -stderr to define which fd gets output. Helps when using vid_soft/SDL/libcaca/ncurses ;) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10990 d7cf8633-e32d-0410-b094-e92efae38249
fix almost all g++ -pedantic warnings git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10402 d7cf8633-e32d-0410-b094-e92efae38249
Detect appended data to the DP executable. If it's a pk3, it is added FIRST (TODO: should this be LAST) into the search path. If it contains a darkplaces.opt text file, its contents are parsed and used as extra command line arguments. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10034 d7cf8633-e32d-0410-b094-e92efae38249
refactor timing, so that timing code is in sys_shared.c. Changes in behaviour: Win32 now prefers select() (PLEASE TEST), SDL timers can be overridden by sys_usequeryperformancecounter or sys_useclockgettime, new cvar sys_debugtime git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10013 d7cf8633-e32d-0410-b094-e92efae38249
don't use ssize_t removed ssize_t from qtypes.h git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9680 d7cf8633-e32d-0410-b094-e92efae38249
check if FNDELAY is defined instead of checking WIN32 git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9619 d7cf8633-e32d-0410-b094-e92efae38249
fix stupid console input bug git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9402 d7cf8633-e32d-0410-b094-e92efae38249
fix bug that caused newlines of console lines to be cut off (this made pasting fail) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9328 d7cf8633-e32d-0410-b094-e92efae38249
fix a compile error on dedicated server in MSVC2008 git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8748 d7cf8633-e32d-0410-b094-e92efae38249
fix whitespace handling: treat ONLY the following characters as whitespace: NUL, TAB, LF, CR, SPC Alternatively, there is commented out macro code in quakedef.h to accept any chars in 0..32 as whitespace. Previously: 0..32 and 128..255 (due to signed char) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8606 d7cf8633-e32d-0410-b094-e92efae38249
Remove disabling of stdin for the text console. Helps with interfacing scripts with the DarkPlaces client. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8601 d7cf8633-e32d-0410-b094-e92efae38249