[Buildroot] [PATCH] pkg-download.mk: Fix shallow clone

Peter Korsgaard jacmet at uclibc.org
Sun Dec 2 16:05:34 UTC 2012


>>>>> "Stephan" == Stephan Hoffmann <sho at relinux.de> writes:

 Stephan> Some git versions (e.g. 1.7.0) do not treat trying to shallow clone
 Stephan> a non existing branch or tag as a fatal error but report a warning
 Stephan> and clone HEAD instead. Thus the fallback mechanism does not work
 Stephan> in this case.

 Stephan> This patch introduces a check for the presence of the requested
 Stephan> version as a branch or tag before trying the shallow clone. It
 Stephan> also removes the need to do two clones when a sha1 is given as
 Stephan> a packege version.

Thanks, committed.

I really do think we need to move the git handling into an external
script, because this isn't really readable anymore - But that's for
post-2012.11.

I've changed the cut -b 42- into cut -f2- as that's more robust (and
readable imho).


-- 
Bye, Peter Korsgaard


More information about the buildroot mailing list