A patch to enable compiling on latest mingw env.
Contributed by TOYAMA Shin-ichi
This commit is contained in:
parent
fce3d93399
commit
b0c1546b1b
2 changed files with 4 additions and 34 deletions
|
|
@ -24,40 +24,10 @@
|
|||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
(See COPYING.txt)
|
||||
|
||||
June 14, 2002 - February 24, 2010
|
||||
June 14, 2002 - December 30, 2017
|
||||
$Id$
|
||||
*/
|
||||
|
||||
#ifdef WIN32
|
||||
/* Horrible, dangerous macros. */
|
||||
/*
|
||||
The SDL stderr redirection trick doesn't seem to work for perror().
|
||||
This does pretty much the same thing.
|
||||
*/
|
||||
#define perror(str) ({ \
|
||||
if ( (str) && *(str) ) \
|
||||
fprintf(stderr,"%s : ",(str)); \
|
||||
fprintf(stderr, \
|
||||
"%s [%d]\n", \
|
||||
(errno<_sys_nerr)?_sys_errlist[errno]:"unknown",errno ); \
|
||||
})
|
||||
|
||||
/*
|
||||
MinGW implementation of isspace() crashes on some Win98 boxes
|
||||
if c is 'out-of-range'.
|
||||
*/
|
||||
#define isspace(c) (((c) == 0x20) || ((c) >= 0x09 && (c) <= 0x0D))
|
||||
|
||||
/*
|
||||
WIN32 and MINGW don't have strcasestr().
|
||||
*/
|
||||
#define NOMINMAX
|
||||
#include "shlwapi.h"
|
||||
#define strcasestr StrStrI
|
||||
#endif /* WIN32 */
|
||||
|
||||
|
||||
|
||||
#ifndef __HAIKU__
|
||||
#ifdef __GNUC__
|
||||
// This version has strict type checking for safety.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue