diff options
author | Eric NOULARD <eric.noulard@gmail.com> | 2010-08-23 14:14:40 (GMT) |
---|---|---|
committer | Eric NOULARD <eric.noulard@gmail.com> | 2010-08-23 14:14:40 (GMT) |
commit | 40dc97dc73b67d76442b386b73c57437fa72db34 (patch) | |
tree | 791ced92f94cc0ff369aba2352576268d46219bc /Source/CPack/cmCPackRPMGenerator.cxx | |
parent | b718597b8bf50cee6be222915f41294f9fe89f5e (diff) | |
download | CMake-40dc97dc73b67d76442b386b73c57437fa72db34.zip CMake-40dc97dc73b67d76442b386b73c57437fa72db34.tar.gz CMake-40dc97dc73b67d76442b386b73c57437fa72db34.tar.bz2 |
CPack Backward-compatibly enforce DESTDIR for DEB and RPM
Diffstat (limited to 'Source/CPack/cmCPackRPMGenerator.cxx')
-rw-r--r-- | Source/CPack/cmCPackRPMGenerator.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Source/CPack/cmCPackRPMGenerator.cxx b/Source/CPack/cmCPackRPMGenerator.cxx index 01b6b06..0641418 100644 --- a/Source/CPack/cmCPackRPMGenerator.cxx +++ b/Source/CPack/cmCPackRPMGenerator.cxx @@ -11,6 +11,7 @@ ============================================================================*/ #include "cmCPackRPMGenerator.h" #include "cmCPackLog.h" +#include "cmSystemTools.h" //---------------------------------------------------------------------- cmCPackRPMGenerator::cmCPackRPMGenerator() @@ -26,7 +27,10 @@ cmCPackRPMGenerator::~cmCPackRPMGenerator() int cmCPackRPMGenerator::InitializeInternal() { this->SetOptionIfNotSet("CPACK_PACKAGING_INSTALL_PREFIX", "/usr"); - + if (cmSystemTools::IsOff(this->GetOption("CPACK_SET_DESTDIR"))) + { + this->SetOption("CPACK_SET_DESTDIR", "I_ON"); + } return this->Superclass::InitializeInternal(); } |