X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/371a5b4e62eb415107e045588f614fa49e866e78..30e671a59f943a03b2aea6b3b7880a221a422a19:/include/wx/filefn.h diff --git a/include/wx/filefn.h b/include/wx/filefn.h index 567a8d050d..9fb223cde2 100644 --- a/include/wx/filefn.h +++ b/include/wx/filefn.h @@ -31,7 +31,7 @@ #else // define off_t -#if !defined(__WXMAC__) || defined(__UNIX__) +#if !defined(__WXMAC__) || defined(__UNIX__) || defined(__MACH__) #include #else typedef long off_t; @@ -41,9 +41,9 @@ typedef _off_t off_t; #elif defined(__BORLANDC__) && defined(__WIN16__) typedef long off_t; -#elif defined(__SC__) +#elif defined(__SYMANTEC__) typedef long off_t; -#elif defined(__MWERKS__) && !defined(__INTEL__) +#elif defined(__MWERKS__) && !defined(__INTEL__) && !defined(__MACH__) typedef long off_t; #endif @@ -78,6 +78,9 @@ WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString; || ( defined(__MINGW32__) && !defined(__WINE__) && wxCHECK_W32API_VERSION( 0, 5 ) ) \ || ( defined(__MWERKS__) && defined(__WXMSW__) ) // functions +#ifdef __BORLANDC__ + #define _tell tell +#endif #define wxClose _close #define wxRead _read #define wxWrite _write @@ -90,6 +93,7 @@ WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString; #if wxUSE_UNICODE #if wxUSE_UNICODE_MSLU #define wxOpen wxMSLU__wopen + #define wxAccess wxMSLU__waccess #define wxMkDir wxMSLU__wmkdir #define wxRmDir wxMSLU__wrmdir @@ -102,7 +106,11 @@ WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString; #define wxStat _wstat #endif #else // !wxUSE_UNICODE +#ifdef __BORLANDC__ + #define wxOpen open +#else #define wxOpen _open +#endif #define wxAccess _access #define wxMkDir _mkdir #define wxRmDir _rmdir @@ -113,14 +121,16 @@ WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString; #define wxStructStat struct _stat // constants (unless already defined by the user code) - #ifndef O_RDONLY + #if !defined(O_RDONLY) && !defined(__BORLANDC__) #define O_RDONLY _O_RDONLY #define O_WRONLY _O_WRONLY #define O_RDWR _O_RDWR #define O_EXCL _O_EXCL #define O_CREAT _O_CREAT #define O_BINARY _O_BINARY + #endif + #ifndef __BORLANDC__ #define S_IFMT _S_IFMT #define S_IFDIR _S_IFDIR #define S_IFREG _S_IFREG @@ -143,6 +153,9 @@ WXDLLEXPORT_DATA(extern const wxChar*) wxEmptyString; #if wxUSE_UNICODE # define wxNEED_WX_UNISTD_H +#if defined(__MWERKS__) && defined(macintosh) + #include +#endif WXDLLEXPORT int wxStat( const wxChar *file_name, wxStructStat *buf ); WXDLLEXPORT int wxAccess( const wxChar *pathname, int mode ); WXDLLEXPORT int wxOpen( const wxChar *pathname, int flags, mode_t mode );