summaryrefslogtreecommitdiff
path: root/gentree.py
diff options
context:
space:
mode:
authorLuis R. Rodriguez <mcgrof@suse.com>2014-05-01 08:30:34 -0700
committerLuis R. Rodriguez <mcgrof@do-not-panic.com>2014-05-01 18:44:14 -0700
commit0ffe02d18a01276369cce4abc60aca82a7904270 (patch)
tree371eefe0748427dda72e633a6bae604a8801e014 /gentree.py
parent0fb30aaa303678b4a3ea888fa10bcb9fee9e0ac6 (diff)
backports: add gentree.py binary requirements
Signed-off-by: Luis R. Rodriguez <mcgrof@suse.com>
Diffstat (limited to 'gentree.py')
-rwxr-xr-xgentree.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/gentree.py b/gentree.py
index 10588842..8a8f6b6a 100755
--- a/gentree.py
+++ b/gentree.py
@@ -15,6 +15,7 @@ from lib import bpgit as git
from lib import bpgpg as gpg
from lib import bpkup as kup
from lib.tempdir import tempdir
+from lib import bpreqs as reqs
def read_copy_list(copyfile):
"""
@@ -438,6 +439,13 @@ def upload_release(args, rel_prep, logwrite=lambda x:None):
logwrite("kup-test: skipping cmd: %s" % kup_cmd)
def _main():
+ # Our binary requirements go here
+ req = reqs.Req()
+ req.require('git')
+ req.coccinelle('1.0.0-rc21')
+ if not req.reqs_match():
+ sys.exit(1)
+
# set up and parse arguments
parser = argparse.ArgumentParser(description='generate backport tree')
parser.add_argument('kerneldir', metavar='<kernel tree>', type=str,
@@ -880,6 +888,10 @@ def process(kerneldir, outdir, copy_list_file, git_revision=None,
git_debug_snapshot(args, "disable unsatisfied Makefile parts")
if (args.kup or args.kup_test):
+ req = reqs.Req()
+ req.kup()
+ if not req.reqs_match():
+ sys.exit(1)
upload_release(args, rel_prep, logwrite=logwrite)
logwrite('Done!')