CMakeLists.txt
changeset 7256 5b97b9946cde
parent 7233 225179f64fd8
child 7264 4c438ad3eddc
equal deleted inserted replaced
7254:aa4461ec7737 7256:5b97b9946cde
    50 IF(NOT BUILD_ENGINE_LIBRARY)
    50 IF(NOT BUILD_ENGINE_LIBRARY)
    51     SET(BUILD_ENGINE_LIBRARY 0)
    51     SET(BUILD_ENGINE_LIBRARY 0)
    52 ENDIF(NOT BUILD_ENGINE_LIBRARY)
    52 ENDIF(NOT BUILD_ENGINE_LIBRARY)
    53 set(target_dir "bin")
    53 set(target_dir "bin")
    54 
    54 
    55 
       
    56 #bundle .app setup
    55 #bundle .app setup
    57 if(APPLE)
    56 if(APPLE OR CROSSAPPLE)
    58     set(CMAKE_FIND_FRAMEWORK "FIRST")
       
    59 
       
    60     #paths for creating the bundle
    57     #paths for creating the bundle
    61     set(bundle_name Hedgewars.app)
    58     set(bundle_name Hedgewars.app)
    62     set(frameworks_dir ${bundle_name}/Contents/Frameworks/)
    59     set(frameworks_dir ${bundle_name}/Contents/Frameworks/)
    63     set(CMAKE_INSTALL_PREFIX ${bundle_name}/Contents/MacOS/)
    60     set(CMAKE_INSTALL_PREFIX ${bundle_name}/Contents/MacOS/)
    64     set(DATA_INSTALL_DIR "../Resources/")
    61     set(DATA_INSTALL_DIR "../Resources/")
    65     set(target_dir ".")
    62     set(target_dir ".")
       
    63     set(minimum_macosx_version "10.6")
       
    64 endif()
       
    65 
       
    66 if(APPLE)
       
    67     set(CMAKE_FIND_FRAMEWORK "FIRST")
    66 
    68 
    67     #what system are we building for
    69     #what system are we building for
    68     set(minimum_macosx_version $ENV{MACOSX_DEPLOYMENT_TARGET})
    70     set(minimum_macosx_version $ENV{MACOSX_DEPLOYMENT_TARGET})
    69 
    71 
    70     #detect on which system we are: if sw_vers cannot be found for any reason (re)use minimum_macosx_version
    72     #detect on which system we are: if sw_vers cannot be found for any reason (re)use minimum_macosx_version