Hi James

On 29 Jan 2014, at 15:12, James Turner 
<[email protected]<mailto:[email protected]>> wrote:
I’m experimenting with using Cmake’s bundle support on OS-X for a project. (Up 
until now I have assembled the bundle by hand using a separate script which 
also creates the DMG). I have the situation, that I need the executable name to 
be different to the bundle name. MACOSX_BUNDLE_BUNDLE_NAME lets met set the 
name that appears in the CFBundleName key of the Info.plist, but the generated 
bundle still has the name of the target.
sorry, don't know about that, would be good to find out though! You can change 
the bundle display name using a plist file but this won't change the actual 
bundle's "folder" name.

One more thing, is there a standard way to install other components inside the 
bundle? I have seen some examples on the web which hardcode the bundle name as 
the destination path, which feels a bit ugly. (I’m thinking about helper 
applications and dylibs here, as well as the .icns file)
I'm sure you can write lots of cmake commands to copy stuff across. We've 
resorted to using a python script which is called at the end of the build. 
It'll copy a lot of the things like icns files, the osg and qt plugins, some 
gdal data files, etc. This python script is run though cmake's CONFIGURE 
command to resolve lots of the build time paths and version numbers…

This produces a complete bundle but it's no relocatable as is. We use a bash 
script  (also processed via CONFIGURE) which runs a combination of qt's 
macdeployqt (for the qt frameworks), dylibbundler (from macport) and 
install_name_tool to make sure all the bundle is completely relocatable.
It'll will also codesign the whole lot and create a nice dmg for the install :-)



Mike

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to