summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorRaffi Enficiaud <raffi.enficiaud@mines-paris.org>2015-04-21 15:19:57 (GMT)
committerBrad King <brad.king@kitware.com>2015-04-23 13:02:49 (GMT)
commitfdfe4586a047d9b6cc64efdd22fbdc67e9f1193f (patch)
tree1044eb20abf3c45c879f86a84cee81a0ce3ad432 /Source
parent5a5ef00106662da5c6400d76438289f505b4a1ff (diff)
downloadCMake-fdfe4586a047d9b6cc64efdd22fbdc67e9f1193f.zip
CMake-fdfe4586a047d9b6cc64efdd22fbdc67e9f1193f.tar.gz
CMake-fdfe4586a047d9b6cc64efdd22fbdc67e9f1193f.tar.bz2
CPackDeb: Fix lintian md5sum file warning
Lintian warned about invalid md5sum file permissions.
Diffstat (limited to 'Source')
-rw-r--r--Source/CPack/cmCPackDebGenerator.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/CPack/cmCPackDebGenerator.cxx b/Source/CPack/cmCPackDebGenerator.cxx
index 18597e8..0137374 100644
--- a/Source/CPack/cmCPackDebGenerator.cxx
+++ b/Source/CPack/cmCPackDebGenerator.cxx
@@ -20,6 +20,7 @@
#include <cmsys/Glob.hxx>
#include <limits.h> // USHRT_MAX
+#include <sys/stat.h>
// NOTE:
// A debian package .deb is simply an 'ar' archive. The only subtle difference
@@ -524,6 +525,11 @@ int cmCPackDebGenerator::createDeb()
// Do not end the md5sum file with yet another (invalid)
}
+ // set md5sum file permissins to RW-R--R-- so that deb lintian doesn't warn
+ // about it
+ cmSystemTools::SetPermissions(md5filename.c_str(),
+ S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH);
+
cmd = this->GetOption("GEN_CPACK_DEBIAN_FAKEROOT_EXECUTABLE");
cmd += cmake_tar + "tar czf control.tar.gz ./control ./md5sums";
const char* controlExtra =