diff options
author | Andreas Hasenack <andreas@mandriva.com> | 2006-07-10 20:08:25 +0000 |
---|---|---|
committer | Andreas Hasenack <andreas@mandriva.com> | 2006-07-10 20:08:25 +0000 |
commit | 7d05483906567000a4952c1826b2a001e20a8ed2 (patch) | |
tree | b6ded40080d54aa5ed9bede42bfdf745a08515c7 | |
parent | 482d308aa4738883f7faf62534c8cf27be68439f (diff) | |
download | mgarepo-7d05483906567000a4952c1826b2a001e20a8ed2.tar mgarepo-7d05483906567000a4952c1826b2a001e20a8ed2.tar.gz mgarepo-7d05483906567000a4952c1826b2a001e20a8ed2.tar.bz2 mgarepo-7d05483906567000a4952c1826b2a001e20a8ed2.tar.xz mgarepo-7d05483906567000a4952c1826b2a001e20a8ed2.zip |
- imported moredefines fixtopic/V1_5_X@959
-rw-r--r-- | RepSys/rpmutil.py | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/RepSys/rpmutil.py b/RepSys/rpmutil.py index 7b6446f..48efd1c 100644 --- a/RepSys/rpmutil.py +++ b/RepSys/rpmutil.py @@ -37,6 +37,13 @@ def get_srpm(pkgdirurl, scripts = []): svn = SVN() tmpdir = tempfile.mktemp() + topdir = "--define '_topdir %s'" % tmpdir + builddir = "--define '_builddir %s/%s'" % (tmpdir, "BUILD") + rpmdir = "--define '_rpmdir %s/%s'" % (tmpdir, "RPMS") + sourcedir = "--define '_sourcedir %s/%s'" % (tmpdir, "SOURCES") + specdir = "--define '_specdir %s/%s'" % (tmpdir, "SPECS") + srcrpmdir = "--define '_srcrpmdir %s/%s'" % (tmpdir, "SRPMS") + patchdir = "--define '_patchdir %s/%s'" % (tmpdir, "SOURCES") try: if mode == "version": geturl = os.path.join(pkgdirurl, "versions", @@ -64,9 +71,11 @@ def get_srpm(pkgdirurl, if status != 0: raise Error, "script %s failed" % script if packager: - packager = " --define 'packager %s'" % packager - execcmd("rpm -bs --nodeps --define '_topdir %s'%s %s" % - (tmpdir, packager, spec)) + packager = "--define 'packager %s'" % packager + + execcmd("rpm -bs --nodeps %s %s %s %s %s %s %s %s %s" % + (topdir, builddir, rpmdir, sourcedir, + specdir, srcrpmdir, patchdir, packager, spec)) if revision: srpm = glob.glob(os.path.join(srpmsdir, "*.src.rpm"))[0] srpmbase = os.path.basename(srpm) |