Changeset 8090 for code/branches/mac_osx/src
- Timestamp:
- Mar 18, 2011, 10:00:27 AM (14 years ago)
- Location:
- code/branches/mac_osx/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/mac_osx/src/CMakeLists.txt
r8084 r8090 140 140 SOURCE_FILES 141 141 Orxonox.cc 142 #OrxonoxMac.mm142 OrxonoxMac.mm 143 143 OUTPUT_NAME orxonox 144 144 ) … … 151 151 "/System/Library/Frameworks/Foundation.framework" 152 152 ) 153 154 # Tell Apple where to find the Info.plist file, used for Cocoa 155 # TODO: Of course, this only makes sense for development builds. CPack will take care of this otherwise 156 # Property XCODE_ATTRIBUTE_INFOPLIST_FILE is fo Xcode, while the other is for makefile generator 157 SET_TARGET_PROPERTIES(orxonox-main PROPERTIES 158 XCODE_ATTRIBUTE_INFOPLIST_FILE "${DEFAULT_DATA_PATH}/mac/Orxonox-Info.plist" 159 MACOSX_BUNDLE_INFO_PLIST "${DEFAULT_DATA_PATH}/mac/Orxonox-Info.plist" 160 ) 153 154 # Post-build step for the creation of the Dev-App bundle 155 INCLUDE(PrepareDevBundle) 156 ADD_CUSTOM_COMMAND( 157 TARGET orxonox-main 158 POST_BUILD 159 # Copy the Orxonox.app from the dummy location to the correct one 160 COMMAND ${CMAKE_COMMAND} -E copy_directory "${CMAKE_BINARY_DIR}/${DEFAULT_BUNDLE_PATH}/Dummy/${PROJECT_NAME}.app" "${CMAKE_BINARY_DIR}/${DEFAULT_BUNDLE_PATH}/${CMAKE_CFG_INTDIR}/${PROJECT_NAME}.app" 161 # Copy the executable into the Orxonox.app 162 COMMAND ${CMAKE_COMMAND} -E copy "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR}/${ORXONOX_EXECUTABLE_NAME}" "${CMAKE_BINARY_DIR}/${DEFAULT_BUNDLE_PATH}/${CMAKE_CFG_INTDIR}/${PROJECT_NAME}.app/Contents/MacOS" 163 # Copy the dev-build marker file to Orxonox.app 164 COMMAND ${CMAKE_COMMAND} -E copy "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR}/orxonox_dev_build.keep_me" "${CMAKE_BINARY_DIR}/${DEFAULT_BUNDLE_PATH}/${CMAKE_CFG_INTDIR}/${PROJECT_NAME}.app/Contents/MacOS" 165 # Create a shortcut of the application to the Desktop 166 COMMAND ${CMAKE_COMMAND} -E create_symlink "${CMAKE_BINARY_DIR}/${DEFAULT_BUNDLE_PATH}/${CMAKE_CFG_INTDIR}/${PROJECT_NAME}.app" "$ENV{HOME}/Desktop/${PROJECT_NAME}_${CMAKE_CFG_INTDIR}.app" 167 ) 161 168 ENDIF(APPLE) 162 169 -
code/branches/mac_osx/src/Orxonox.cc
r8084 r8090 53 53 #ifdef ORXONOX_USE_WINMAIN 54 54 INT WINAPI WinMain(HINSTANCE hInst, HINSTANCE, LPSTR strCmdLine, INT) 55 //#elif defined(ORXONOX_PLATFORM_APPLE)56 //int main_mac(int argc, char** argv)55 #elif defined(ORXONOX_PLATFORM_APPLE) 56 int main_mac(int argc, char** argv) 57 57 #else 58 58 int main(int argc, char** argv) 59 59 #endif 60 60 { 61 COUT(0) << "main mac" << std::endl;62 61 try 63 62 { 64 63 #ifndef ORXONOX_USE_WINMAIN 65 64 std::string strCmdLine; 66 for (int i = 1; i < argc; ++i)65 for (int i = 2; i < argc; ++i) 67 66 strCmdLine = strCmdLine + argv[i] + ' '; 68 67 #endif -
code/branches/mac_osx/src/OrxonoxMac.mm
r8083 r8090 9 9 #import "OrxonoxMac.h" 10 10 11 //#import <Foundation/Foundation.h>12 13 11 static int argc_s = 0; 14 12 static char** argv_s = 0; … … 16 14 int main(int argc, char** argv) 17 15 { 18 //NSLog(@"main");19 16 argc_s = argc; 20 17 argv_s = argv; 21 18 22 //NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init];23 //[[NSApplication sharedApplication] setDelegate:[[[OrxonoxAppDelegate alloc] init] autorelease]];24 19 int retVal = NSApplicationMain(argc, (const char**)argv); 25 //[pool drain];26 20 27 21 return retVal; … … 32 26 - (void)applicationDidFinishLaunching:(NSNotification *)notification 33 27 { 34 NSLog(@"applicationDidFinishLaunching");35 28 exit(main_mac(argc_s, argv_s)); 36 29 } -
code/branches/mac_osx/src/libraries/core/GraphicsManager.cc
r8043 r8090 316 316 317 317 // HACK 318 #ifdef ORXONOX_PLATFORM_APPLE319 //INFO: This will give our window focus, and not lock it to the terminal320 ProcessSerialNumber psn = {0, kCurrentProcess};321 TransformProcessType(&psn, kProcessTransformToForegroundApplication);322 SetFrontProcess(&psn);323 #endif318 //#ifdef ORXONOX_PLATFORM_APPLE 319 // //INFO: This will give our window focus, and not lock it to the terminal 320 // ProcessSerialNumber psn = {0, kCurrentProcess}; 321 // TransformProcessType(&psn, kProcessTransformToForegroundApplication); 322 // SetFrontProcess(&psn); 323 //#endif 324 324 // End of HACK 325 325 -
code/branches/mac_osx/src/orxonox/sound/SoundManager.cc
r8056 r8090 326 326 alListener3f(AL_POSITION, position.x, position.y, position.z); 327 327 ALenum error = alGetError(); 328 if (error == AL_INVALID_VALUE) 329 COUT(2) << "Sound: OpenAL: Invalid listener position" << std::endl; 328 if (error == AL_INVALID_VALUE) {} 329 // @TODO: Follow this constantly appearing, nerve-racking warning 330 //COUT(2) << "Sound: OpenAL: Invalid listener position" << std::endl; 330 331 } 331 332
Note: See TracChangeset
for help on using the changeset viewer.