<br><br><div class="gmail_quote">On Thu, Jul 21, 2011 at 5:01 AM, Domagoj Saric <span dir="ltr"><<a href="mailto:domagoj.saric@littleendian.com">domagoj.saric@littleendian.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On 19.7.2011. 13:41, Domagoj Saric wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi, I'm using CMake 2.8.5 and OS X 10.6.8. I'm trying to create an multi<br>
component installer with CPack and PackageMaker (an .mpkg) that would create a<br>
symlink as a post installation step. Simplified: the installer installs<br>
directories A and B and then I want to add a symlink in directory B that points<br>
to a file in directory A. I cannot just add the symlink in the installer because<br>
the user is allowed to change the target root installation directory (i.e. root<br>
of the system volume or the user directory) so I have to create the symlink<br>
at/after installation time in order to make it point to the correct location.<br>
<br>
Before even being able to test the post installation script functionality I ran<br>
into the following problems:<br>
<br>
- CPack (with PackageMaker) uses CPACK_PREFLIGHT_SCRIPT, CPACK_POSTFLIGHT_SCRIPT<br>
and CPACK_POSTUPGRADE_SCRIPT which are not available when targeting OS X 10.5 or<br>
later, only preinstall and postinstall seem to available then. The result is<br>
that no script is added when set( CPACK_OSX_PACKAGE_VERSION 10.5 )...<br>
<br>
- without set( CPACK_OSX_PACKAGE_VERSION 10.5 ) (defaults to 10.3) specified<br>
scripts are added to the root Resource folder of the installer (although<br>
stripped of the .sh extension and renamed to simply preflight, postflight and<br>
postupgrade) but they do not get executed. The "Scripts directory" (as seen when<br>
the resulting mpkg is opened in PackageMaker) is also set for the individual<br>
components but individual script entries are left blank.<br>
<br>
<br>
ps. how do install( CODE ) and install( SCRIPT ) relate to CPack? Do they get<br>
included in the generated installer in some way?<br>
</blockquote>
<br>
<br></div>
*bump*<br>
<br>
Apologies for nagging but Google searches about CMake, CPack and symlinks show that is not a rare problem/question..is there no comment/help on this from the CMake devs?<div><div></div><div class="h5"><br></div></div></blockquote>
<div><br></div><div>Just busy, that's all...</div><div><br></div><div>install(CODE) and install(SCRIPT) code is run at "make install" time. By default, CPack does a "make install" to an intermediate location in the build tree (underneath _CPack_Packages in your build tree) as part of building the final installer.</div>
<div><br></div><div>I don't know about the CPack post script stuff, or the OS X version differences you're talking about. I'll have to investigate / take a look later, but not sure I'll have the time for it this week. If you can give me easy-to-reproduce steps, that might help.</div>
<div><br></div><div><br></div><div>Hope this helps,</div><div>David</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><div class="h5">
<br>
<br>
<br>
-- <br>
"What Huxley teaches is that in the age of advanced technology, spiritual<br>
devastation is more likely to come from an enemy with a smiling face than<br>
from one whose countenance exudes suspicion and hate."<br>
Neil Postman<br>
______________________________<u></u>_________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/<u></u>opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/<u></u>CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/<u></u>listinfo/cmake</a><br>
</div></div></blockquote></div><br>