diff options
| author | Andreas Oberritter <obi@opendreambox.org> | 2010-12-08 13:38:23 +0000 |
|---|---|---|
| committer | Richard Purdie <rpurdie@linux.intel.com> | 2011-01-04 14:46:51 +0000 |
| commit | bd34e7d6dffbdcd3cfb0bc21daf73e9090e5110f (patch) | |
| tree | 4eb6fdd4501facd55b4921f7b09f35bac638b79f /bitbake/lib/bb/fetch/svn.py | |
| parent | 7bbde5b149751c2b38964b786b76a25f62199397 (diff) | |
| download | poky-bd34e7d6dffbdcd3cfb0bc21daf73e9090e5110f.tar.gz | |
fetchers: Add parameter scmdata=keep to include .git/ and others in generated tarballs.
* Allows generating version information from SCMs during build.
* Note that tar doesn't need to use --exclude '.git', because
git checkout-index doesn't clone the repository.
(Bitbake rev: 05cbc1d1a01c667c77688f36fbc5b61c5f452a3a)
Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/lib/bb/fetch/svn.py')
| -rw-r--r-- | bitbake/lib/bb/fetch/svn.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/bitbake/lib/bb/fetch/svn.py b/bitbake/lib/bb/fetch/svn.py index dc35c9d121..8f053abf74 100644 --- a/bitbake/lib/bb/fetch/svn.py +++ b/bitbake/lib/bb/fetch/svn.py | |||
| @@ -151,10 +151,16 @@ class Svn(Fetch): | |||
| 151 | logger.debug(1, "Running %s", svnfetchcmd) | 151 | logger.debug(1, "Running %s", svnfetchcmd) |
| 152 | runfetchcmd(svnfetchcmd, d) | 152 | runfetchcmd(svnfetchcmd, d) |
| 153 | 153 | ||
| 154 | scmdata = ud.parm.get("scmdata", "") | ||
| 155 | if scmdata == "keep": | ||
| 156 | tar_flags = "" | ||
| 157 | else: | ||
| 158 | tar_flags = "--exclude '.svn'" | ||
| 159 | |||
| 154 | os.chdir(ud.pkgdir) | 160 | os.chdir(ud.pkgdir) |
| 155 | # tar them up to a defined filename | 161 | # tar them up to a defined filename |
| 156 | try: | 162 | try: |
| 157 | runfetchcmd("tar --exclude '.svn' -czf %s %s" % (ud.localpath, ud.module), d) | 163 | runfetchcmd("tar %s -czf %s %s" % (tar_flags, ud.localpath, ud.module), d) |
| 158 | except: | 164 | except: |
| 159 | t, v, tb = sys.exc_info() | 165 | t, v, tb = sys.exc_info() |
| 160 | try: | 166 | try: |
