* Prevent this error when creating empty packages.

tar: *: Cannot stat: No such file or directory
  tar: Error exit delayed from previous errors
This commit is contained in:
Dan McGee 2007-02-27 16:25:01 +00:00
parent 6673d188b9
commit 7f086a4c5c

View file

@ -165,11 +165,12 @@ class pmpkg:
# .FILELIST
if self.files:
os.system("tar cvf /dev/null * | sort >.FILELIST")
targets += " .FILELIST *"
else:
#prevent some pacman warnings... I expect a real package would
#always have at least one file...
os.system("touch .FILELIST")
targets += " .FILELIST *"
targets += " .FILELIST"
# Generate package archive
os.system("tar zcf %s %s" % (archive, targets))