The reason for that is the following.

1.) I switched from qmake to cmake because I for my own think it is more robust 
and powerful as qmake especially when using different languages or want to 
build for multiple platforms (Makefile generator) or only to use cpack to 
create an installer with ease

2.) either I need to use "macdeployqt" or I use the BundleUtilities. So because 
I've already switched to CMake it would be fine if I can solve the "rest" of 
the problems with CMake too.

I don't know if I do something wrong, but here are the points which I want to 
do during the build process:
.) build the application and libraries
.) solve dependencies (post process with macdeployqt and/or BundleUtilities)
.) sign the required bundle and libraries (codesign)
.) build a Mac app store compatible package (productbuild)

The best here is that I only need to type in "make Product"

Step 1, 3 and 4 works
Step 2 work currently with macdeployqt but this step I would like to replace 
with the BundleUtilities (inline without extra files like macdeployqt)

The result is one (maybe big) CMakeLists.txt file which can simply copied to 
multiple projects and with few changes.

Best Regards


Am 02.12.2011 um 20:38 schrieb David Cole <[email protected]>:

> The answer to "Is this possible?" is almost nearly always "yes, of course."
> 
> The wiki page http://www.cmake.org/Wiki/BundleUtilitiesExample shows a
> basic code snippet like this:
> 
> set(APPS ...)  # paths to executables
> set(DIRS ...)   # directories to search for prerequisites
> INSTALL(CODE "
>   include(BundleUtilities)
>   fixup_bundle(\"${APPS}\"   \"\"   \"${DIRS}\")
>   " COMPONENT Runtime)
> 
> This encodes some CMake code into a CMake script file that runs at
> "make install" time...
> 
> To do the equivalent at build time, whether as a post_build step or as
> a custom target that depends on the bundled executable, the easiest
> way to do it is what Mike already suggested: configure a cmake script
> file to make the same calls that are presently made at install time.
> 
> Why are you averse to using a script file to achieve your goal?
> 
> Caveats: one thing to remember is that the install time fixup that
> BundleUtilities does is often an expensive operation, and you don't
> want to do it unless you have to. Another thing to remember is that it
> operates on the installed bundle app, and modifies the executable and
> copies files into the tree. If you do the same thing at build time to
> the copy of your app in the build tree, then you may encounter
> different results than running it in the install tree. Some files are
> required to be copied into their expected locations within the bundle
> before calling fixup_bundle... The install tree bundle and build tree
> bundles probably have different files in them unless you also copy all
> those libraries into the bundle as a build time step, too.
> 
> It may be better to simply do a "make install" rather than trying to
> use BundleUtilities strictly at build time...
> 
> 
> David
> 
> 
> On Fri, Dec 2, 2011 at 1:33 PM,  <[email protected]> wrote:
>> Thanks but I mean only within a CMakeLists file (add_custom_target) without 
>> an extra file.
>> 
>> Is this possible?
>> 
>> Best Regards
>> 
>> Am 02.12.2011 um 17:56 schrieb Michael Jackson <[email protected]>:
>> 
>>> Just thinking out loud here:
>>> 
>>> Create a shell script template.
>>> Configure the template at cmake time
>>> Run the script as a POST_BUILD custom target.
>>> 
>>> Inside the custom script you would call cmake with the specific 
>>> bundleUtilities code that you need to "fix up" the application.
>>> ___________________________________________________________
>>> Mike Jackson                    Principal Software Engineer
>>> BlueQuartz Software                            Dayton, Ohio
>>> [email protected]              www.bluequartz.net
>>> 
>>> On Dec 2, 2011, at 10:58 AM, [email protected] wrote:
>>> 
>>>> Hi,
>>>> 
>>>> i want to build an application bundle (on Mac OS X) where the dependencies 
>>>> are solved.
>>>> 
>>>> Normally I use BundleUtilities in combination with cpack as described in 
>>>> the BundleUtilities example to do so.
>>>> 
>>>> However, is there a way to run the BundleUtilities as a post build process?
>>>> 
>>>> Thanks in advance
>>>> 
>>>> Best Regards
>>>> NoRulez
>>>> --
>>>> 
>>>> Powered by www.kitware.com
>>>> 
>>>> Visit other Kitware open-source projects at 
>>>> http://www.kitware.com/opensource/opensource.html
>>>> 
>>>> Please keep messages on-topic and check the CMake FAQ at: 
>>>> http://www.cmake.org/Wiki/CMake_FAQ
>>>> 
>>>> Follow this link to subscribe/unsubscribe:
>>>> http://www.cmake.org/mailman/listinfo/cmake
>>> 
>> --
>> 
>> Powered by www.kitware.com
>> 
>> Visit other Kitware open-source projects at 
>> http://www.kitware.com/opensource/opensource.html
>> 
>> Please keep messages on-topic and check the CMake FAQ at: 
>> http://www.cmake.org/Wiki/CMake_FAQ
>> 
>> Follow this link to subscribe/unsubscribe:
>> http://www.cmake.org/mailman/listinfo/cmake
--

Powered by www.kitware.com

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

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

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

Reply via email to