No subject
Wed May 9 12:08:04 EDT 2012
If a user chooses to enable TXZ they will either have success or get an
appropriate error from CPack.
----------------------------------------------------------------------
(0029027) Eric NOULARD (developer) - 2012-04-01 10:39
http://cmake.org/Bug/view.php?id=13072#c29027
----------------------------------------------------------------------
Hi Mario,
I let Kitware guys give their opinion on this, but CMake tries to avoid platform
specific feature in his feature set unless it's obviously makes sense, like
not support Visual Studio Generator on Linux is just fine.
In the present case, the point of using libarchive is precisely the fact that
the same range of features are available on all CMake-supported platforms.
How would I write a portable CMakeLists.txt and use TXZ if I have not
"by-design" clue that TXZ will be available on a particular platform?
I can see two options for achieving this:
1) Create something like cmxzutils (from http://tukaani.org/xz/) and
ensure it compiles on all CMake supported platform
Then your patch is ok.
2) Create a TAR CPack generator (which does not exist yet)
and authorize this generator to have a CPACK_TAR_POSTPROCESS
option which could be used to specify a post-processing
command on the file(s) produced by the TAR generator.
set(CPACK_TAR_POSTPROCESS "xz;.xz;.txz")
would mean than xz would be called on the file(s)
resulting files would be appended the ".xz" suffix
in the end it should be renamed .txz.
This way one could write in its CMakeLists.txt
find_program(XZ_PROGRAM NAMES xz)
if (XZ_PROGRAM)
list(APPEND CPACK_GENERATORS "TAR")
set(CPACK_TAR_POSTPROCESS "${XZ_PROGRAM};.xz;.txz")
else (XZ_PROGRAM)
list(APPEND CPACK_GENERATORS "TBZ2")
endif(XZ_PROGRAM)
----------------------------------------------------------------------
(0029278) Eric NOULARD (developer) - 2012-04-20 20:55
http://cmake.org/Bug/view.php?id=13072#c29278
----------------------------------------------------------------------
Not working on this until I get feedback from other CMake dev.
Mario you can raise the discussion on cmake developer ML refering
to this if you want to try accelerate this process.
----------------------------------------------------------------------
(0029816) Shlomi Fish (reporter) - 2012-06-23 16:58
http://cmake.org/Bug/view.php?id=13072#c29816
----------------------------------------------------------------------
Since I'd also like to have tar.xz functionality in the upstream CMake, I've now
requested feedback from the CMake developer mailing list:
http://public.kitware.com/pipermail/cmake-developers/2012-June/004431.html
Regards,
â Shlomi Fish
----------------------------------------------------------------------
(0029821) Eric NOULARD (developer) - 2012-06-25 11:21
http://cmake.org/Bug/view.php?id=13072#c29821
----------------------------------------------------------------------
I think that for portability reason it's not reasonable
to include LZMA unless we can include a portable lzma library
in the CMake source.
I won't have time to do that myself though.
Another solution would be to dynamically check (when running CPack)
that the TXZ generator may run.
This is now possible using
cmCPackXXXGenerator::CanGenerate() interface which was introduced
for dynamically enabling RPM and DEB generator on OS (cf
http://cmake.org/Bug/view.php?id=13064).
The idea behind this is that the CPack generator
may always be compiled with the concerned generator activated
but the factory has a (simple) way to check whether if the generator
is usable or not **at run time**.
If the check is successfull then the generator may be used
(and appear in the cpack --help list) if not the factory
does not build the concerned generator and it does not appear
in the list.
The entry point for that behavior is the
cmCPackGeneratorFactory::cmCPackGeneratorFactory() constructor.
The CPack main program is using an instance of this factory class.
----------------------------------------------------------------------
(0029822) Eric NOULARD (developer) - 2012-06-25 11:22
http://cmake.org/Bug/view.php?id=13072#c29822
----------------------------------------------------------------------
Unassigning until we have feedback
Issue History
Date Modified Username Field Change
======================================================================
2012-03-29 16:33 Mario Lang New Issue
2012-03-29 16:33 Mario Lang File Added:
0001-cmCPackTXZGenerator-Add-tar.xz-archive-generation.patch
2012-03-29 16:36 Mario Lang File Added:
0002-Add-CPACK_BINARY_TXZ-and-CPACK_SOURCE_TXZ-options.patch
2012-03-29 16:52 Eric NOULARD Issue Monitored: Eric NOULARD
2012-03-30 17:20 Eric NOULARD Assigned To => Eric NOULARD
2012-03-30 17:20 Eric NOULARD Status new => assigned
2012-03-30 17:40 Eric NOULARD Note Added: 0029008
2012-03-30 17:43 Eric NOULARD Assigned To Eric NOULARD =>
2012-03-30 17:48 Eric NOULARD Relationship added has duplicate 0001104
2012-03-30 17:52 Eric NOULARD Note Added: 0029010
2012-03-30 19:04 Brad King Relationship added duplicate of 0011040
2012-03-30 19:05 Brad King Relationship deleted has duplicate 0001104
2012-03-30 19:06 Eric NOULARD Status assigned => new
2012-04-01 09:59 Mario Lang Note Added: 0029026
2012-04-01 10:39 Eric NOULARD Note Added: 0029027
2012-04-01 10:39 Eric NOULARD Note Edited: 0029027
2012-04-20 20:55 Eric NOULARD Note Added: 0029278
2012-04-20 20:55 Eric NOULARD Assigned To => Eric NOULARD
2012-04-20 20:55 Eric NOULARD Status new => feedback
2012-05-15 19:04 David Faure Issue Monitored: David Faure
2012-06-23 16:58 Shlomi Fish Note Added: 0029816
2012-06-25 11:21 Eric NOULARD Note Added: 0029821
2012-06-25 11:22 Eric NOULARD Note Added: 0029822
2012-06-25 11:22 Eric NOULARD Status feedback => new
======================================================================
More information about the cmake-developers
mailing list