Previously, tar was called manually with os.system. This caused one fork per
package/db creation, which is costly, especially on cygwin. Besides, it also
caused some problems with directory with whitespaces (that could also be
fixed with quotes, but well..)
Using tarfile module is cleaner and more efficient, and still easy enough.
Benchmark (time make check) :
- windows / cygwin
prepatch:
real 6m36.360s
user 2m28.914s
sys 2m35.866s
postpatch:
real 5m25.428s
user 1m26.029s
sys 2m0.006s
- linux
prepatch:
real 1m22.629s
user 0m31.498s
sys 0m18.899s
postpatch:
real 1m11.465s
user 0m26.382s
sys 0m12.986s
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
This is something pacman can do on its own straight from the archive, and we
will reduce the chance of problems occurring becuase of inproper FILELIST
generation as we have had in the past with special characters in filenames.
Once we remove it from makepkg. we can remove any usage of it from all of
our other tools, including pacman, pactest, and contrib/ utilities.
Note that removing it from pacman uncovered a few other bugs anyway, so this
was probably a good move.
Signed-off-by: Dan McGee <dan@archlinux.org>
Update the GPL boilerplate to direct people to the GNU website for a copy of
the license, as well as bump all of Judd's copyrights to 2007.
Signed-off-by: Dan McGee <dan@archlinux.org>
Remove any checks dealing with requiredby from pactest (but not actually
from the pactests themselves). Of course, we should probably find a new way
to check requiredby values of packages since there is no guarantee our code
is working perfectly.
Signed-off-by: Dan McGee <dan@archlinux.org>
Actually use python commands to generate the filelist instead of os.system
calls that don't necessarily work everywhere. Noticed when running "make
check" on FreeBSD where the tar program is actually bsdtar.
Signed-off-by: Dan McGee <dan@archlinux.org>
* Added a custom 'mkdir' function which makes parents and doesn't fail on
existence
* Added output for 'SKIP' messages (it did not indicate WHY it was skipped)
* Added the ability to generate DB packages in the sync dir (not the cache dir)
for testing downloading. (self.cachepkgs = False)
* Added pmtest.path for the full path to the package file