Various compile fixes for WinCE.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18098 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -95,6 +95,19 @@ private: \
|
|||||||
chartype *m_str; \
|
chartype *m_str; \
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef strdup
|
||||||
|
inline char *strdup(const char *cs)
|
||||||
|
{
|
||||||
|
size_t len = 0;
|
||||||
|
while (cs[len] != 0)
|
||||||
|
len++;
|
||||||
|
const size_t siz = (len + 1)*sizeof(char);
|
||||||
|
char *csCopy = (char *)malloc(siz);
|
||||||
|
memcpy(csCopy, cs, siz);
|
||||||
|
return csCopy;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
DEFINE_BUFFER(wxCharBuffer, char, strdup);
|
DEFINE_BUFFER(wxCharBuffer, char, strdup);
|
||||||
|
|
||||||
#if wxUSE_WCHAR_T
|
#if wxUSE_WCHAR_T
|
||||||
|
@@ -12,7 +12,9 @@
|
|||||||
#ifndef _WX_DEBUG_H_
|
#ifndef _WX_DEBUG_H_
|
||||||
#define _WX_DEBUG_H_
|
#define _WX_DEBUG_H_
|
||||||
|
|
||||||
|
#ifndef __WXWINCE__
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
|
#endif
|
||||||
#include <limits.h> // for CHAR_BIT used below
|
#include <limits.h> // for CHAR_BIT used below
|
||||||
|
|
||||||
#include "wx/wxchar.h" // for __TFILE__ and wxChar
|
#include "wx/wxchar.h" // for __TFILE__ and wxChar
|
||||||
|
@@ -95,7 +95,7 @@
|
|||||||
// compiler defects workarounds
|
// compiler defects workarounds
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
|
||||||
#if defined(__VISUALC__) && !defined(WIN32)
|
#if defined(__VISUALC__) && !defined(WIN32) && !defined(__WXWINCE__)
|
||||||
// VC1.5 does not have LPTSTR type
|
// VC1.5 does not have LPTSTR type
|
||||||
#define LPTSTR LPSTR
|
#define LPTSTR LPSTR
|
||||||
#define LPCTSTR LPCSTR
|
#define LPCTSTR LPCSTR
|
||||||
|
@@ -18,12 +18,18 @@
|
|||||||
|
|
||||||
#include "wx/list.h"
|
#include "wx/list.h"
|
||||||
|
|
||||||
|
#ifndef __WXWINCE__
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// constants
|
// constants
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#ifdef __WXWINCE__
|
||||||
|
typedef long off_t;
|
||||||
|
#else
|
||||||
|
|
||||||
// define off_t
|
// define off_t
|
||||||
#if !defined(__WXMAC__) || defined(__UNIX__)
|
#if !defined(__WXMAC__) || defined(__UNIX__)
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
@@ -41,6 +47,8 @@
|
|||||||
typedef long off_t;
|
typedef long off_t;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(__VISAGECPP__) && __IBMCPP__ >= 400
|
#if defined(__VISAGECPP__) && __IBMCPP__ >= 400
|
||||||
//
|
//
|
||||||
// VisualAge C++ V4.0 cannot have any external linkage const decs
|
// VisualAge C++ V4.0 cannot have any external linkage const decs
|
||||||
|
@@ -40,7 +40,9 @@ typedef unsigned long wxLogLevel;
|
|||||||
|
|
||||||
#if wxUSE_LOG
|
#if wxUSE_LOG
|
||||||
|
|
||||||
|
#ifndef __WXWINCE__
|
||||||
#include <time.h> // for time_t
|
#include <time.h> // for time_t
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "wx/dynarray.h"
|
#include "wx/dynarray.h"
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user