summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Cedilnik <andy.cedilnik@kitware.com>2002-11-04 19:50:32 (GMT)
committerAndy Cedilnik <andy.cedilnik@kitware.com>2002-11-04 19:50:32 (GMT)
commitc45fc1e4b3015a2f610c023a157f16277f2de701 (patch)
treeb1e0bc33843fcdfc1db7ccf9217b2356ed66b0ef
parenta9df6fdd8ec2cbe12287b1e12219d2fb893ccf80 (diff)
downloadCMake-c45fc1e4b3015a2f610c023a157f16277f2de701.zip
CMake-c45fc1e4b3015a2f610c023a157f16277f2de701.tar.gz
CMake-c45fc1e4b3015a2f610c023a157f16277f2de701.tar.bz2
Attempt to automate apple gui generation
-rw-r--r--Source/WXDialog/CMakeLists.txt28
-rw-r--r--Templates/AppleInfo.plist36
2 files changed, 64 insertions, 0 deletions
diff --git a/Source/WXDialog/CMakeLists.txt b/Source/WXDialog/CMakeLists.txt
index 12bdefa..0787a2d 100644
--- a/Source/WXDialog/CMakeLists.txt
+++ b/Source/WXDialog/CMakeLists.txt
@@ -27,6 +27,34 @@ IF ( CMAKE_WX_CAN_COMPILE )
TARGET_LINK_LIBRARIES(wxCMakeSetup ${WXWINDOWS_LIBRARY})
TARGET_LINK_LIBRARIES(wxCMakeSetup CMakeLib)
+ IF(APPLE)
+ SET(APPLE_GUI_EXECUTABLE wxCMakeSetup)
+ SET(APPLE_GUI_INFO_STRING "CMake version 1.5.0, (c) 2002 Kitware Inc.")
+ SET(APPLE_GUI_IDENTIFIER "com.kitware.wxCMakeSetup")
+ SET(APPLE_GUI_LONG_VERSION_STRING "1.5.0, (c) 2002 Kitware Inc.")
+ SET(APPLE_GUI_BUNDLE_NAME "CMake")
+ SET(APPLE_GUI_SHORT_VERSION_STRING "1.5.0")
+ SET(APPLE_GUI_BUNDLE_VERSION "1.5.0")
+ SET(APPLE_GUI_COPYRIGHT "Copyright 2002 Kitware Inc.")
+ CONFIGURE_FILE(${CMAKE_ROOT}/Templates/AppleInfo.plist
+ ${EXECUTABLE_OUTPUT_PATH}/CMake.app/Contents/Info.plist)
+ WRITE_FILE(${EXECUTABLE_OUTPUT_PATH}/CMake.app/Contents/PkgInfo "APPL????")
+
+ ADD_CUSTOM_COMMAND(
+ SOURCE wxCMakeSetup
+ COMMAND ${CMAKE_COMMAND}
+ ARGS -E copy
+ ${EXECUTABLE_OUTPUT_PATH}/wxCMakeSetup
+ ${EXECUTABLE_OUTPUT_PATH}/CMake.app/Contents/MacOS/wxCMakeSetup
+ TARGET wxCMakeSetup)
+ ADD_CUSTOM_COMMAND(
+ SOURCE wxCMakeSetup
+ COMMAND ${CMAKE_COMMAND}
+ ARGS -E chdir ${EXECUTABLE_OUTPUT_PATH}/CMake.app/Contents/MacOS
+ `${CMAKE_WX_CONFIG} --rezflags`
+ ${EXECUTABLE_OUTPUT_PATH}/CMake.app/Contents/MacOS/wxCMakeSetup)
+ ENDIF(APPLE)
+
INSTALL_TARGETS(/bin wxCMakeSetup)
IF(BUILD_TESTING)
diff --git a/Templates/AppleInfo.plist b/Templates/AppleInfo.plist
new file mode 100644
index 0000000..fe86f40
--- /dev/null
+++ b/Templates/AppleInfo.plist
@@ -0,0 +1,36 @@
+<?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">
+<plist version="1.0">
+<dict>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>English</string>
+ <key>CFBundleExecutable</key>
+ <string>${APPLE_GUI_EXECUTABLE}</string>
+ <key>CFBundleGetInfoString</key>
+ <string>${APPLE_GUI_INFO_STRING}</string>
+ <key>CFBundleIconFile</key>
+ <string>wxmac.icns</string>
+ <key>CFBundleIdentifier</key>
+ <string>${APPLE_GUI_IDENTIFIER}</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleLongVersionString</key>
+ <string>${APPLE_GUI_LONG_VERSION_STRING}</string>
+ <key>CFBundleName</key>
+ <string>${APPLE_GUI_BUNDLE_NAME}</string>
+ <key>CFBundlePackageType</key>
+ <string>APPL</string>
+ <key>CFBundleShortVersionString</key>
+ <string>${APPLE_GUI_SHORT_VERSION_STRING}</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleVersion</key>
+ <string>${APPLE_GUI_BUNDLE_VERSION}</string>
+ <key>CSResourcesFileMapped</key>
+ <true/>
+ <key>LSRequiresCarbon</key>
+ <true/>
+ <key>NSHumanReadableCopyright</key>
+ <string>${APPLE_GUI_COPYRIGHT}</string>
+</dict>
+</plist>