Skip to content
Snippets Groups Projects
Commit 6626d617 authored by Henrik (Grubba) Grubbström's avatar Henrik (Grubba) Grubbström
Browse files

mkpackage: Support multiple sub-packages with the same name.

Gnu-tar doesn't like being asked to extract the same file multiple
times from the same tar-file. It claims that the second file doesn't
exist in the archive.

This can happen when a sub-package has been replaced with a fixed version.
parent ac26d69b
No related branches found
No related tags found
No related merge requests found
......@@ -182,6 +182,9 @@ class Package
// Figure out the contents.
"CONTENTS=`tar tf \"$TARFILE\" | sed -ne '/^"+
replace(basename(install_filename), ".", "\\.")+"/,$p'`\n"
// The same file may appear multiple times
// in a tar archive if it has been replaced.
"CONTENTS=`echo $CONTENTS|sort|uniq`\n"
// Check if we're going to use a special tar for e.g. --add.
"[ x\"$TAR\" = x ] && TAR=tar\n"
"[ x\"$CPIO\" = x ] && CPIO=cpio\n"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment