summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/fetch
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2010-09-24 15:46:59 -0700
committerRichard Purdie <rpurdie@linux.intel.com>2011-01-04 14:46:37 +0000
commit6491ed9e2ee6562a9ffc548fdd9ee6e13ba96657 (patch)
tree866b11c4cba450d613f9a38b26122b5f486be101 /bitbake/lib/bb/fetch
parentc81cd1be64a6d8c725fc7323d040ed2fad41c826 (diff)
downloadpoky-6491ed9e2ee6562a9ffc548fdd9ee6e13ba96657.tar.gz
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>
Diffstat (limited to 'bitbake/lib/bb/fetch')
-rw-r--r--bitbake/lib/bb/fetch/bzr.py2
-rw-r--r--bitbake/lib/bb/fetch/cvs.py2
-rw-r--r--bitbake/lib/bb/fetch/git.py2
-rw-r--r--bitbake/lib/bb/fetch/hg.py2
-rw-r--r--bitbake/lib/bb/fetch/svn.py2
5 files changed, 5 insertions, 5 deletions
diff --git a/bitbake/lib/bb/fetch/bzr.py b/bitbake/lib/bb/fetch/bzr.py
index 8b0bd9ff3a..3ca125f370 100644
--- a/bitbake/lib/bb/fetch/bzr.py
+++ b/bitbake/lib/bb/fetch/bzr.py
@@ -107,7 +107,7 @@ class Bzr(Fetch):
107 os.chdir(ud.pkgdir) 107 os.chdir(ud.pkgdir)
108 # tar them up to a defined filename 108 # tar them up to a defined filename
109 try: 109 try:
110 runfetchcmd("tar -czf %s %s" % (ud.localpath, os.path.basename(ud.pkgdir)), d) 110 runfetchcmd("tar --exclude '.bzr' --exclude '.bzrtags' -czf %s %s" % (ud.localpath, os.path.basename(ud.pkgdir)), d)
111 except: 111 except:
112 t, v, tb = sys.exc_info() 112 t, v, tb = sys.exc_info()
113 try: 113 try:
diff --git a/bitbake/lib/bb/fetch/cvs.py b/bitbake/lib/bb/fetch/cvs.py
index 1064b09e11..42d71ba9fe 100644
--- a/bitbake/lib/bb/fetch/cvs.py
+++ b/bitbake/lib/bb/fetch/cvs.py
@@ -162,7 +162,7 @@ class Cvs(Fetch):
162 # tar them up to a defined filename 162 # tar them up to a defined filename
163 if 'fullpath' in ud.parm: 163 if 'fullpath' in ud.parm:
164 os.chdir(pkgdir) 164 os.chdir(pkgdir)
165 myret = os.system("tar -czf %s %s" % (ud.localpath, localdir)) 165 myret = os.system("tar --exclude 'CVS' -czf %s %s" % (ud.localpath, localdir))
166 else: 166 else:
167 os.chdir(moddir) 167 os.chdir(moddir)
168 os.chdir('..') 168 os.chdir('..')
diff --git a/bitbake/lib/bb/fetch/git.py b/bitbake/lib/bb/fetch/git.py
index 57d758dcda..8a00a013f9 100644
--- a/bitbake/lib/bb/fetch/git.py
+++ b/bitbake/lib/bb/fetch/git.py
@@ -187,7 +187,7 @@ class Git(Fetch):
187 187
188 os.chdir(codir) 188 os.chdir(codir)
189 logger.info("Creating tarball of git checkout") 189 logger.info("Creating tarball of git checkout")
190 runfetchcmd("tar -czf %s %s" % (ud.localpath, os.path.join(".", "*") ), d) 190 runfetchcmd("tar --exclude '.git' -czf %s %s" % (ud.localpath, os.path.join(".", "*") ), d)
191 191
192 os.chdir(ud.clonedir) 192 os.chdir(ud.clonedir)
193 bb.utils.prunedir(codir) 193 bb.utils.prunedir(codir)
diff --git a/bitbake/lib/bb/fetch/hg.py b/bitbake/lib/bb/fetch/hg.py
index ab00d43033..9c11debd80 100644
--- a/bitbake/lib/bb/fetch/hg.py
+++ b/bitbake/lib/bb/fetch/hg.py
@@ -145,7 +145,7 @@ class Hg(Fetch):
145 145
146 os.chdir(ud.pkgdir) 146 os.chdir(ud.pkgdir)
147 try: 147 try:
148 runfetchcmd("tar -czf %s %s" % (ud.localpath, ud.module), d) 148 runfetchcmd("tar --exclude '.hg' --exclude '.hgrags' -czf %s %s" % (ud.localpath, ud.module), d)
149 except: 149 except:
150 t, v, tb = sys.exc_info() 150 t, v, tb = sys.exc_info()
151 try: 151 try:
diff --git a/bitbake/lib/bb/fetch/svn.py b/bitbake/lib/bb/fetch/svn.py
index 34f8132257..c236e413fd 100644
--- a/bitbake/lib/bb/fetch/svn.py
+++ b/bitbake/lib/bb/fetch/svn.py
@@ -159,7 +159,7 @@ class Svn(Fetch):
159 os.chdir(ud.pkgdir) 159 os.chdir(ud.pkgdir)
160 # tar them up to a defined filename 160 # tar them up to a defined filename
161 try: 161 try:
162 runfetchcmd("tar -czf %s %s" % (ud.localpath, ud.module), d) 162 runfetchcmd("tar --exclude '.svn' -czf %s %s" % (ud.localpath, ud.module), d)
163 except: 163 except:
164 t, v, tb = sys.exc_info() 164 t, v, tb = sys.exc_info()
165 try: 165 try: