fetchers: Use tar --exclude pattern to remove SCM files

This option will exclude the SCM metadata from tar files.

Tested with gcc where svn tar which used to be 156M for gcc 4.5
is now 77M

(Bitbake rev: f264cb6d43472525ad787b0887764ea696ec52ba)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
This commit is contained in:
Khem Raj
2010-09-24 15:46:59 -07:00
committed by Richard Purdie
parent c81cd1be64
commit 6491ed9e2e
5 changed files with 5 additions and 5 deletions

View File

@@ -187,7 +187,7 @@ class Git(Fetch):
os.chdir(codir)
logger.info("Creating tarball of git checkout")
runfetchcmd("tar -czf %s %s" % (ud.localpath, os.path.join(".", "*") ), d)
runfetchcmd("tar --exclude '.git' -czf %s %s" % (ud.localpath, os.path.join(".", "*") ), d)
os.chdir(ud.clonedir)
bb.utils.prunedir(codir)