aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorStanislav Ochotnicky <sochotnicky@gmail.com>2009-07-23 20:18:22 +0200
committerStanislav Ochotnicky <sochotnicky@gmail.com>2009-07-25 00:51:48 +0200
commita4939b91967a0bcdb3241db8530609b9b4b57846 (patch)
treea0372afba4f3fcdd2dc1ec7cc5a609d5b477ac1e /src
parentFix small bug in exception handling (diff)
downloadcollagen-a4939b91967a0bcdb3241db8530609b9b4b57846.tar.gz
collagen-a4939b91967a0bcdb3241db8530609b9b4b57846.tar.bz2
collagen-a4939b91967a0bcdb3241db8530609b9b4b57846.zip
Fixed cases where r0 was added to version
this caused a lot of problems with packages that were not found and so on..
Diffstat (limited to 'src')
-rw-r--r--src/tinderbox/__init__.py13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/tinderbox/__init__.py b/src/tinderbox/__init__.py
index 766e766..f72f227 100644
--- a/src/tinderbox/__init__.py
+++ b/src/tinderbox/__init__.py
@@ -108,7 +108,12 @@ class Tinderbox(object):
# setup logging!
os.chroot(config.WORK_CHROOT)
init_logging()
- package.version = "-".join(portage.pkgsplit(pkg)[1:])
+ pkgname, pkgver, pkgrev = portage.pkgsplit(pkg)
+
+ if pkgrev is "r0":
+ package.version = pkgver
+ else:
+ package.version = "%s-%s" % (pkgver, pkgrev)
self._emerge_package_subprocess(pkg, ebuild, dep_groups, package)
sys.exit(0)
@@ -188,7 +193,11 @@ class Tinderbox(object):
elif 0 == real_use_enabled.count(useflag):
real_use_enabled.append(useflag)
- dep_pkg = Package(dep_name,"%s-%s" % (dep_ver, dep_rev), real_use_enabled)
+ if dep_rev is'r0':
+ dep_ver_full = dep_ver
+ else:
+ dep_ver_full = "%s-%s" % (dep_ver, dep_rev)
+ dep_pkg = Package(dep_name, dep_ver_full, real_use_enabled)
package_infos.append(dep_pkg.get_info())