OS X: Add a preliminary Xcode project. DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@4646 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
hendricks266 2014-10-18 04:50:47 +00:00
parent f46d901fe2
commit 6ff363a049
12 changed files with 2760 additions and 29 deletions

View file

@ -291,7 +291,7 @@ ifeq ($(SUBPLATFORM),LINUX)
endif endif
ifeq ($(PLATFORM),DARWIN) ifeq ($(PLATFORM),DARWIN)
LIBDIRS += -L$(AUDIOLIB_ROOT)/third-party/Apple/lib # LIBDIRS += -L$(AUDIOLIB_ROOT)/third-party/Apple/lib
LIBS += -lFLAC -lvorbisfile -lvorbis -logg -lm \ LIBS += -lFLAC -lvorbisfile -lvorbis -logg -lm \
-Wl,-framework,Cocoa -Wl,-framework,Carbon -Wl,-framework,OpenGL \ -Wl,-framework,Cocoa -Wl,-framework,Carbon -Wl,-framework,OpenGL \

View file

@ -663,8 +663,8 @@ ifeq ($(PLATFORM),DARWIN)
ASFORMAT=macho$(SYSBITS) ASFORMAT=macho$(SYSBITS)
ASFLAGS+= -DUNDERSCORES ASFLAGS+= -DUNDERSCORES
LIBDIRS+= -Lplatform/Apple/lib # LIBDIRS+= -Lplatform/Apple/lib
COMPILERFLAGS+= -Iplatform/Apple/include # COMPILERFLAGS+= -Iplatform/Apple/include
ifneq ($(shell port --version &>/dev/null; echo $$?),127) ifneq ($(shell port --version &>/dev/null; echo $$?),127)
LIBDIRS+= -L/opt/local/lib LIBDIRS+= -L/opt/local/lib

View file

@ -5,7 +5,11 @@
Feel free to customize this file to suit your needs Feel free to customize this file to suit your needs
*/ */
#import <Foundation/Foundation.h>
#import <AppKit/AppKit.h>
#include "sdl_inc.h" #include "sdl_inc.h"
#include "SDLMain.h"
#include <sys/param.h> /* for MAXPATHLEN */ #include <sys/param.h> /* for MAXPATHLEN */
#include <unistd.h> #include <unistd.h>
@ -71,7 +75,7 @@ static NSString *getApplicationName(void)
@implementation NSApplication (SDLApplication) @implementation NSApplication (SDLApplication)
/* Invoked from the Quit menu item */ /* Invoked from the Quit menu item */
- (void)terminate:(id)sender - (void)terminateCall:(id)sender
{ {
/* Post a SDL_QUIT event */ /* Post a SDL_QUIT event */
SDL_Event event; SDL_Event event;
@ -80,8 +84,11 @@ static NSString *getApplicationName(void)
} }
@end @end
@interface SDLMain (NSObject)
@end
/* The main class of the application, the application's delegate */ /* The main class of the application, the application's delegate */
@implementation SDLMain @implementation SDLMain (NSObject)
/* Set the working directory to the .app's parent directory */ /* Set the working directory to the .app's parent directory */
- (void) setupWorkingDirectory:(BOOL)shouldChdir - (void) setupWorkingDirectory:(BOOL)shouldChdir
@ -153,7 +160,7 @@ static void setApplicationMenu(void)
[appleMenu addItem:[NSMenuItem separatorItem]]; [appleMenu addItem:[NSMenuItem separatorItem]];
title = [@"Quit " stringByAppendingString:appName]; title = [@"Quit " stringByAppendingString:appName];
[appleMenu addItemWithTitle:title action:@selector(terminate:) keyEquivalent:@"q"]; [appleMenu addItemWithTitle:title action:@selector(terminateCall:) keyEquivalent:@"q"];
/* Put menu into the menubar */ /* Put menu into the menubar */
@ -380,4 +387,3 @@ int main (int argc, char **argv)
#endif #endif
return 0; return 0;
} }

File diff suppressed because it is too large Load diff

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
@ -12,29 +12,31 @@
<string>2.0, Copyright EDuke32 Team</string> <string>2.0, Copyright EDuke32 Team</string>
<key>CFBundleIconFile</key> <key>CFBundleIconFile</key>
<string>eduke32.icns</string> <string>eduke32.icns</string>
<key>CFBundleIdentifier</key> <key>CFBundleIdentifier</key>
<string>com.eduke32</string> <string>com.voidpoint.eduke32</string>
<key>CFBundleInfoDictionaryVersion</key> <key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string> <string>6.0</string>
<key>CFBundleName</key> <key>CFBundleName</key>
<string>EDuke32</string> <string>EDuke32</string>
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleSignature</key>
<string>ED32</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>2.0</string> <string>2.0</string>
<key>CFBundleSignature</key>
<string>ED32</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>2.0</string> <string>2.0</string>
<key>CSResourcesFileMapped</key> <key>CGDisableCoalescedUpdates</key>
<true/> <true/>
<key>CSResourcesFileMapped</key>
<true/>
<key>LSApplicationCategoryType</key>
<string>public.app-category.action-games</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright Voidpoint, LLC</string>
<key>NSMainNibFile</key> <key>NSMainNibFile</key>
<string>game.osxmain</string> <string>game.osxmain</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright EDuke32 Team</string>
<key>NSPrincipalClass</key> <key>NSPrincipalClass</key>
<string>NSApplication</string> <string>NSApplication</string>
<key>CGDisableCoalescedUpdates</key>
<true/>
</dict> </dict>
</plist> </plist>

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
@ -12,29 +12,29 @@
<string>2.0, Copyright EDuke32 Team</string> <string>2.0, Copyright EDuke32 Team</string>
<key>CFBundleIconFile</key> <key>CFBundleIconFile</key>
<string>mapster32.icns</string> <string>mapster32.icns</string>
<key>CFBundleIdentifier</key> <key>CFBundleIdentifier</key>
<string>com.eduke32.mapster32</string> <string>com.voidpoint.mapster32</string>
<key>CFBundleInfoDictionaryVersion</key> <key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string> <string>6.0</string>
<key>CFBundleName</key> <key>CFBundleName</key>
<string>Mapster32</string> <string>Mapster32</string>
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleSignature</key>
<string>MP32</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>2.0</string> <string>2.0</string>
<key>CFBundleSignature</key>
<string>MP32</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>2.0</string> <string>2.0</string>
<key>CSResourcesFileMapped</key> <key>CGDisableCoalescedUpdates</key>
<true/> <true/>
<key>CSResourcesFileMapped</key>
<true/>
<key>NSHumanReadableCopyright</key>
<string>Copyright Voidpoint, LLC</string>
<key>NSMainNibFile</key> <key>NSMainNibFile</key>
<string>build.osxmain</string> <string>build.osxmain</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright EDuke32 Team</string>
<key>NSPrincipalClass</key> <key>NSPrincipalClass</key>
<string>NSApplication</string> <string>NSApplication</string>
<key>CGDisableCoalescedUpdates</key>
<true/>
</dict> </dict>
</plist> </plist>

View file

@ -69,6 +69,9 @@ enet_deinitialize (void)
{ {
} }
// Why, Xcode? Why?
time_t time(time_t *);
enet_uint32 enet_uint32
enet_host_random_seed (void) enet_host_random_seed (void)
{ {