tweaks for win64 by Seong Gu Lee <sgleehd@gmail.com>

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@39432 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 2016-03-01 10:41:33 +00:00
parent f241e0785d
commit 8352d4a919
5 changed files with 43 additions and 21 deletions

View file

@ -1,3 +1,11 @@
2016-03-01 Seong Gu Lee <sgleehd@gmail.com>
* Headers/GNUstepBase/GSConfig.h.in:
* Headers/GNUstepBase/GSTypeEncoding.h:
* Source/GSFileHandle.h:
* Source/win32/GSFileHandle.m:
Tweaks for WIN64 build
2016-02-29 Richard Frith-Macdonald <rfm@gnu.org>
* configure.ac:

View file

@ -29,6 +29,21 @@
#ifndef included_GSConfig_h
#define included_GSConfig_h
#if defined(__WIN32__) || defined(_WIN32) || defined(__MS_WIN32__)
# if !defined(__WIN32__)
# define __WIN32__
# endif
#endif
#if defined(__MINGW32__) || defined(__MINGW64__)
# if !defined(__MINGW__)
# define __MINGW__
# endif
# if !defined(__WIN32__)
# define __WIN32__
# endif
#endif
// Make sure we expose the constants that we use in ObjC++ mode
#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS 1
@ -220,10 +235,11 @@ typedef gsuaddr gsaddr;
/*
* Native character type for use in systemcalls etc.
*/
#if defined(__MINGW__)
#define GSNativeChar uint16_t
# define GSNativeChar uint16_t
#else
#define GSNativeChar char
# define GSNativeChar char
#endif
/*
@ -251,21 +267,6 @@ typedef struct {
#define GS_USE_LIBDISPATCH @HAVE_LIBDISPATCH@
#define GS_HAVE_OBJC_ROOT_CLASS_ATTR @GS_HAVE_OBJC_ROOT_CLASS_ATTR@
#if defined(__WIN32__) || defined(_WIN32) || defined(__MS_WIN32__)
# if !defined(__WIN32__)
# define __WIN32__
# endif
#endif
#if defined(__MINGW32__)
# if !defined(__MINGW__)
# define __MINGW__
# endif
# if !defined(__WIN32__)
# define __WIN32__
# endif
#endif
#ifndef __has_include
# define __has_include(x) 0
#endif
@ -299,13 +300,17 @@ typedef struct {
#undef WINVER
#define WINVER Windows2000
#endif
/* mingw wants winsock2.h before windows.h */
#include <winsock2.h>
#include <windows.h>
#undef BOOL
#endif
// Include the blocks runtime header if it's available (It shouldn't matter
// that this doesn't work on compilers that don't support __has_include(),
// because they also don't support blocks).
/* Include the blocks runtime header if it's available (It shouldn't matter
* that this doesn't work on compilers that don't support __has_include(),
* because they also don't support blocks).
*/
#if __has_include(<objc/block_runtime.h>)
# include <objc/block_runtime.h>
#endif

View file

@ -29,6 +29,12 @@
#include <GNUstepBase/GSVersionMacros.h>
#if defined(__MINGW__)
/* On MINGW we need to get the boolean type from the runtime at this point.
*/
#define _NO_BOOL_TYPEDEF
#endif
#if defined (NeXT_RUNTIME)
# include <objc/objc-runtime.h>
#else

View file

@ -105,7 +105,9 @@ struct sockaddr_in;
type: (RunLoopEventType)type
extra: (void*)extra
forMode: (NSString*)mode;
- (void) setAddr: (struct sockaddr *)sin;
- (BOOL) useCompression;
- (void) watchReadDescriptorForModes: (NSArray*)modes;
- (void) watchWriteDescriptor;

View file

@ -22,8 +22,9 @@
Boston, MA 02111 USA.
*/
#include <windows.h>
/* mingw wants winsock2.h before windows.h */
#include <winsock2.h>
#include <windows.h>
#include "common.h"