mach-o addition

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@19854 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2003-03-28 19:18:51 +00:00
parent a1e71b1032
commit 2d2ed20f7b
9 changed files with 80 additions and 22 deletions

View File

@@ -534,7 +534,7 @@ public:
#define IMPLEMENT_WXWIN_MAIN \ #define IMPLEMENT_WXWIN_MAIN \
extern int wxEntry( int argc, char **argv ); \ extern int wxEntry( int argc, char **argv ); \
int main(int argc, char **argv) { return wxEntry(argc, argv); } int main(int argc, char **argv) { return wxEntry(argc, argv); }
#elif defined(__WXMAC__) && defined(__UNIX__) #elif defined(__WXMAC__)
// wxMac seems to have a specific wxEntry prototype // wxMac seems to have a specific wxEntry prototype
#define IMPLEMENT_WXWIN_MAIN \ #define IMPLEMENT_WXWIN_MAIN \
extern int wxEntry( int argc, char **argv, bool enterLoop = TRUE ); \ extern int wxEntry( int argc, char **argv, bool enterLoop = TRUE ); \

View File

@@ -31,7 +31,7 @@
#else #else
// define off_t // define off_t
#if !defined(__WXMAC__) || defined(__UNIX__) #if !defined(__WXMAC__) || defined(__UNIX__) || defined(__MACH__)
#include <sys/types.h> #include <sys/types.h>
#else #else
typedef long off_t; typedef long off_t;
@@ -43,7 +43,7 @@
typedef long off_t; typedef long off_t;
#elif defined(__SC__) #elif defined(__SC__)
typedef long off_t; typedef long off_t;
#elif defined(__MWERKS__) && !defined(__INTEL__) #elif defined(__MWERKS__) && !defined(__INTEL__) && !defined(__MACH__)
typedef long off_t; typedef long off_t;
#endif #endif

View File

@@ -10,7 +10,7 @@
#pragma old_argmatch on #pragma old_argmatch on
#endif #endif
#if (__MWERKS__ < 0x0900) || macintosh #if (__MWERKS__ < 0x0900) || macintosh || __MACH__
#define __MAC__ #define __MAC__
#define __WXMAC__ #define __WXMAC__
#elif (__MWERKS__ >= 0x0900) && __INTEL__ #elif (__MWERKS__ >= 0x0900) && __INTEL__
@@ -42,14 +42,21 @@
#elif defined( __WXMAC__) #elif defined( __WXMAC__)
#define USE_PRECOMPILED_MAC_HEADERS 0 /*Set to 0 if you don't want to use precompiled MacHeaders*/ #define USE_PRECOMPILED_MAC_HEADERS 0 /*Set to 0 if you don't want to use precompiled MacHeaders*/
#define ACCESSOR_CALLS_ARE_FUNCTIONS 1 #define ACCESSOR_CALLS_ARE_FUNCTIONS 1
#ifdef __WXDEBUG__ #if defined( __WXDEBUG__ ) && !defined(__MACH__)
// otherwise the debugger looses all symbol information // otherwise the debugger looses all symbol information
#define OPAQUE_TOOLBOX_STRUCTS 0 #define OPAQUE_TOOLBOX_STRUCTS 0
// #else #else
// enabling opaque toolbox structs under Classic will break access to contrlDefProc (control.cpp) #define OPAQUE_TOOLBOX_STRUCTS 1
// #define OPAQUE_TOOLBOX_STRUCTS 1
#endif #endif
#ifdef __MACH__
#include <ansi_prefix.mach.h>
#include <msl_c_version.h>
#include <stdint.h>
#undef WCHAR_MAX
#include <machine/ansi.h>
#else
#include <ansi_prefix.mac.h> #include <ansi_prefix.mac.h>
#endif
/* /*
#include <MacTypes.h> #include <MacTypes.h>
#if UNIVERSAL_INTERFACES_VERSION < 0x0340 #if UNIVERSAL_INTERFACES_VERSION < 0x0340

View File

@@ -18,21 +18,29 @@
#if __option(profile) #if __option(profile)
#ifdef __cplusplus #ifdef __cplusplus
#if __POWERPC__ #ifdef __MACH__
#include <wx_Mach++_prof.mch>
#elif __POWERPC__
#include <wx_Carbon++_prof.mch> #include <wx_Carbon++_prof.mch>
#endif #endif
#else #else
#if __POWERPC__ #ifdef __MACH__
#include <wx_Mach_prof.mch>
#elif __POWERPC__
#include <wx_Carbon_prof.mch> #include <wx_Carbon_prof.mch>
#endif #endif
#endif #endif
#else #else
#ifdef __cplusplus #ifdef __cplusplus
#if __POWERPC__ #ifdef __MACH__
#include <wx_Mach++.mch>
#elif __POWERPC__
#include <wx_Carbon++.mch> #include <wx_Carbon++.mch>
#endif #endif
#else #else
#if __POWERPC__ #ifdef __MACH__
#include <wx_Mach.mch>
#elif __POWERPC__
#include <wx_Carbon.mch> #include <wx_Carbon.mch>
#endif #endif
#endif #endif

View File

@@ -20,11 +20,15 @@
#error "profiling is not supported in debug versions" #error "profiling is not supported in debug versions"
#else #else
#ifdef __cplusplus #ifdef __cplusplus
#if __POWERPC__ #ifdef __MACH__
#include <wx_Mach++_d.mch>
#elif __POWERPC__
#include <wx_Carbon++_d.mch> #include <wx_Carbon++_d.mch>
#endif #endif
#else #else
#if __POWERPC__ #ifdef __MACH__
#include <wx_Mach_d.mch>
#elif __POWERPC__
#include <wx_Carbon_d.mch> #include <wx_Carbon_d.mch>
#endif #endif
#endif #endif

View File

@@ -1,11 +1,15 @@
#if __option (profile) #if __option (profile)
#if __POWERPC__ #ifdef __MACH__
#pragma precompile_target "wx_Mach_prof.mch"
#elif __POWERPC__
#pragma precompile_target "wx_Carbon_prof.mch" #pragma precompile_target "wx_Carbon_prof.mch"
#else #else
#error "illegal processor for carbon" #error "illegal processor for carbon"
#endif #endif
#else #else
#if __POWERPC__ #ifdef __MACH__
#pragma precompile_target "wx_Mach.mch"
#elif __POWERPC__
#pragma precompile_target "wx_Carbon.mch" #pragma precompile_target "wx_Carbon.mch"
#else #else
#error "illegal processor for carbon" #error "illegal processor for carbon"
@@ -17,5 +21,12 @@
#define wxUSE_GUI 1 #define wxUSE_GUI 1
#define TARGET_CARBON 1 #define TARGET_CARBON 1
#define OLDP2C 1 #define OLDP2C 1
#ifdef __MACH__
#define __DARWIN__
#define __CF_USE_FRAMEWORK_INCLUDES__
#define __NOEXTENSIONS__
#define __UNIX__
#define __UNIX_LIKE__
#endif
#include "wx/wx_cw_cm.h" #include "wx/wx_cw_cm.h"

View File

@@ -1,11 +1,15 @@
#if __option (profile) #if __option (profile)
#if __POWERPC__ #ifdef __MACH__
#pragma precompile_target "wx_Mach++_prof.mch"
#elif __POWERPC__
#pragma precompile_target "wx_Carbon++_prof.mch" #pragma precompile_target "wx_Carbon++_prof.mch"
#else #else
#error "illegal processor for carbon" #error "illegal processor for carbon"
#endif #endif
#else #else
#if __POWERPC__ #ifdef __MACH__
#pragma precompile_target "wx_Mach++.mch"
#elif __POWERPC__
#pragma precompile_target "wx_Carbon++.mch" #pragma precompile_target "wx_Carbon++.mch"
#else #else
#error "illegal processor for carbon" #error "illegal processor for carbon"
@@ -17,6 +21,13 @@
#define wxUSE_GUI 1 #define wxUSE_GUI 1
#define TARGET_CARBON 1 #define TARGET_CARBON 1
#define OLDP2C 1 #define OLDP2C 1
#ifdef __MACH__
#define __DARWIN__
#define __CF_USE_FRAMEWORK_INCLUDES__
#define __NOEXTENSIONS__
#define __UNIX__
#define __UNIX_LIKE__
#endif
#include "wx/wx_cw_cm.h" #include "wx/wx_cw_cm.h"
#include "wx/wxprec.h" #include "wx/wxprec.h"

View File

@@ -1,7 +1,9 @@
#if __option (profile) #if __option (profile)
#error "profiling is not supported for debug targets" #error "profiling is not supported for debug targets"
#else #else
#if __POWERPC__ #ifdef __MACH__
#pragma precompile_target "wx_Mach_d.mch"
#elif __POWERPC__
#pragma precompile_target "wx_Carbon_d.mch" #pragma precompile_target "wx_Carbon_d.mch"
#else #else
#error "illegal processor for carbon" #error "illegal processor for carbon"
@@ -13,6 +15,13 @@
#define wxUSE_GUI 1 #define wxUSE_GUI 1
#define TARGET_CARBON 1 #define TARGET_CARBON 1
#define OLDP2C 1 #define OLDP2C 1
#ifdef __MACH__
#define __DARWIN__
#define __CF_USE_FRAMEWORK_INCLUDES__
#define __NOEXTENSIONS__
#define __UNIX__
#define __UNIX_LIKE__
#endif
#include "wx/wx_cw_cm.h" #include "wx/wx_cw_cm.h"
#ifdef __WXMSW__ #ifdef __WXMSW__

View File

@@ -1,7 +1,9 @@
#if __option (profile) #if __option (profile)
#error "profiling is not supported for debug targets" #error "profiling is not supported for debug targets"
#else #else
#if __POWERPC__ #ifdef __MACH__
#pragma precompile_target "wx_Mach++_d.mch"
#elif __POWERPC__
#pragma precompile_target "wx_Carbon++_d.mch" #pragma precompile_target "wx_Carbon++_d.mch"
#else #else
#error "illegal processor for carbon" #error "illegal processor for carbon"
@@ -15,7 +17,13 @@
#define wxUSE_GUI 1 #define wxUSE_GUI 1
#define TARGET_CARBON 1 #define TARGET_CARBON 1
#define OLDP2C 1 #define OLDP2C 1
#ifdef __MACH__
#define __DARWIN__
#define __CF_USE_FRAMEWORK_INCLUDES__
#define __NOEXTENSIONS__
#define __UNIX__
#define __UNIX_LIKE__
#endif
#include "wx/wx_cw_cm.h" #include "wx/wx_cw_cm.h"
#ifdef WX_PRECOMP #ifdef WX_PRECOMP
#include "wx/wxprec.h" #include "wx/wxprec.h"