2010/8/6 Chris Wolf <[email protected]>: > > e.g for : install(TARGETS usb LIBRARY DESTINATION lib) > > (where project name is "libusb") > > The CPack-generated TGZ archive will contain: > libusb-0.1.1-Darwin/lib/libusb.dylib > > ...this, regardless of the setting of CPACK_INCLUDE_TOPLEVEL_DIRECTORY! > > (I would have expected set(CPACK_INCLUDE_TOPLEVEL_DIRECTORY 0) > to result in the archive to contain: ./lib/libusb.dylib)
This is the case on my box (Linux Debian Squeeze x86_64), I can strip off the prefix if I do: cpack -D CPACK_INCLUDE_TOPLEVEL_DIRECTORY=0 -G TGZ or if I set(CPACK_INCLUDE_TOPLEVEL_DIRECTORY 0) Which version of CMake are you using on which platform? May be it's a bug. > Another observation regarding the CPack-generated *.pkg > (wrapped in a *.dmg) : > > The path is prefixed by "./usr", somehow: > > (assuming the *.dmg is already mounted) > $ cd ./libusb-0.1.1-Darwin.pkg/Contents > $ lsbom -s Archive.bom > . > ./usr > ./usr/lib > ./usr/lib/libusb.dylib > > So where does the "./usr/" prefix come from? I'm do not know the dmg CPack Generator (is it PackageMaker or DragNDrop?) and I'm not a mac user but each CPack generator has a default "builtin" CPACK_PACKAGING_INSTALL_PREFIX. Try set(CPACK_PACKAGING_INSTALL_PREFIX. "/whatever") -- Erk Membre de l'April - « promouvoir et défendre le logiciel libre » - http://www.april.org _______________________________________________ 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
