|
|
@@ -239,10 +239,22 @@ SET(CMAKE_SYSTEM_FRAMEWORK_PATH
|
|
|
# default to searching for application bundles first
|
|
|
SET(CMAKE_FIND_APPBUNDLE FIRST)
|
|
|
# set up the default search directories for application bundles
|
|
|
+SET(_apps_paths)
|
|
|
+FOREACH(_path
|
|
|
+ "~/Applications"
|
|
|
+ "/Applications"
|
|
|
+ "${OSX_DEVELOPER_ROOT}/../Applications" # Xcode 4.3+
|
|
|
+ "${OSX_DEVELOPER_ROOT}/Applications" # pre-4.3
|
|
|
+ )
|
|
|
+ GET_FILENAME_COMPONENT(_apps "${_path}" ABSOLUTE)
|
|
|
+ IF(EXISTS "${_apps}")
|
|
|
+ LIST(APPEND _apps_paths "${_apps}")
|
|
|
+ ENDIF()
|
|
|
+ENDFOREACH()
|
|
|
+LIST(REMOVE_DUPLICATES _apps_paths)
|
|
|
SET(CMAKE_SYSTEM_APPBUNDLE_PATH
|
|
|
- ~/Applications
|
|
|
- /Applications
|
|
|
- ${OSX_DEVELOPER_ROOT}/Applications)
|
|
|
+ ${_apps_paths})
|
|
|
+UNSET(_apps_paths)
|
|
|
|
|
|
INCLUDE(Platform/UnixPaths)
|
|
|
LIST(APPEND CMAKE_SYSTEM_PREFIX_PATH
|