[CMake] TGZ installer following links
John R. Cary
cary at txcorp.com
Tue Jun 21 10:34:26 EDT 2011
On 6/21/11 6:28 AM, Brad King wrote:
> On 06/17/2011 04:59 PM, Eric Noulard wrote:
>> OK I have the same behavior on my box using your example.
>> I did open a bug report:
>> http://public.kitware.com/Bug/view.php?id=12284
> I posted an explanation here:
>
> http://www.cmake.org/Bug/view.php?id=12284#c26931
>
> CPack recursively collects all *files* in the installation tree and hands
> them as individual paths to the archive tool. Therefore it walks through
> the directory symlink and collects the files inside. This has existed in
> every version of CPack both before and after the switch to libarchive.
Just in case anyone is interested, here is my workaround:
add_custom_target(bindist
COMMAND ${CMAKE_MAKE_PROGRAM} package
COMMAND tar czf ${FLAVOR_PACKAGE_NAME}.tar.gz -C
${CMAKE_BINARY_DIR}/_CPack_Packages/${CMAKE_SYSTEM_NAME}/TGZ
${FLAVOR_PACKAGE_NAME}
COMMAND rm
${CMAKE_BINARY_DIR}/_CPack_Packages/${CMAKE_SYSTEM_NAME}/TGZ/${FLAVOR_PACKAGE_NAME}.tar.gz
)
John
More information about the CMake
mailing list