[pacman-dev] [PATCH] makepkg: Extract from any file bsdtar can recognize

Allan McRae allan at archlinux.org
Wed Jun 2 21:35:54 EDT 2010


On 03/06/10 10:40, Dan McGee wrote:
> From: Nezmer<git at nezmer.info>
>
> If "file -bizL" does not return a supported type, check if the file is
> recognized by bsdtar and if yes extract from it.
>
> Dan: use '-q' option to prevent needing to seek the entire archive.
>
> Signed-off-by: Nezmer<git at nezmer.info>
> Signed-off-by: Dan McGee<dan at archlinux.org>
> ---
>
> I think I got the '-q' option working just fine as long as you order the
> options correctly to bsdtar. This appears to work on random files I was
> testing it on from the command line.
>
> $ time bsdtar -tf /var/cache/makepkg/src/linux-2.6.34.tar.bz2 -q '*'; echo return: $?
> linux-2.6.34/
>
> real    0m0.079s
> user    0m0.063s
> sys     0m0.010s
> return: 0
>
> -Dan
>

Looks good.   Pushed to my post-3.4 branch.

Allan


More information about the pacman-dev mailing list