diff options
author | Brad King <brad.king@kitware.com> | 2012-06-06 11:29:19 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2012-06-06 11:29:19 (GMT) |
commit | a34015d356c2a4084029e57a822c96330408c8d6 (patch) | |
tree | f97dee042ee336780dcdc0d3da4d579fe14002f2 /Source/cmArchiveWrite.cxx | |
parent | 6218aba37ad9990304f91bf6c27e014fbf8ad684 (diff) | |
download | CMake-a34015d356c2a4084029e57a822c96330408c8d6.zip CMake-a34015d356c2a4084029e57a822c96330408c8d6.tar.gz CMake-a34015d356c2a4084029e57a822c96330408c8d6.tar.bz2 |
cmArchiveWrite: Clear fflags from archive entries
When reading archive entries from disk strip any "fflags" entry headers
that may have been loaded from the filesystem when libarchive is built
with HAVE_STRUCT_STAT_ST_FLAGS (struct stat has 'st_flags'). The local
filesystem flags are not useful for distribution. Furthermore, GNU tar
does not understand the "SCHILY.fflags" extended header used to store
the flags in the archive. Use the approach from commit e8558efa
(cmArchiveWrite: Clear xattr and acl from entries, 2011-04-07) to remove
the flags and avoid producing the non-portable extended header.
Diffstat (limited to 'Source/cmArchiveWrite.cxx')
-rw-r--r-- | Source/cmArchiveWrite.cxx | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Source/cmArchiveWrite.cxx b/Source/cmArchiveWrite.cxx index dc6b749..b410e44 100644 --- a/Source/cmArchiveWrite.cxx +++ b/Source/cmArchiveWrite.cxx @@ -240,6 +240,7 @@ bool cmArchiveWrite::AddFile(const char* file, // Clear acl and xattr fields not useful for distribution. archive_entry_acl_clear(e); archive_entry_xattr_clear(e); + archive_entry_set_fflags(e, 0, 0); if(archive_write_header(this->Archive, e) != ARCHIVE_OK) { this->Error = "archive_write_header: "; |