CPackDeb: Fix lintian md5sum file warning

Lintian warned about invalid md5sum file permissions.
This commit is contained in:
Raffi Enficiaud 2015-04-21 17:19:57 +02:00 committed by Brad King
parent 5a5ef00106
commit fdfe4586a0
1 changed files with 6 additions and 0 deletions

View File

@ -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 =