cmd_build: Implemented output repository creation.
authorEd Bartosh <eduard.bartosh@intel.com>
Mon, 3 Sep 2012 11:28:04 +0000 (14:28 +0300)
committerEd Bartosh <eduard.bartosh@intel.com>
Thu, 6 Sep 2012 08:24:25 +0000 (11:24 +0300)
When -o commandline option is used packages are copied to specified
output directory and now createrepo is called to create rpm repo out
of that directory.

Fixes: #74, #201
Change-Id: Ie06536fe367509bbd38088b4d6120da5436b7542

debian/control
distfiles/gbs.spec
gitbuildsys/cmd_build.py

index e41b893a444336fdb6280a2202f8612ed5ea9202..29b893d8b31a1005b62afc3ed93ba3f1306deaae 100644 (file)
@@ -16,7 +16,8 @@ Depends: ${misc:Depends}, ${python:Depends},
  qemu-arm-static (>= 0.14.1) | qemu-user-static,
  binfmt-support,
  sudo,
- git-buildpackage-rpm (= 0.6.0git20120810)
+ git-buildpackage-rpm (= 0.6.0git20120810),
+ createrepo
 Description: The command line tools for Tizen package developers
   The command line tools for Tizen package developers will
   be used to do packaging related tasks.
index c7f3af8abe270a70271fc9609197d42f1119c15d..72e73b87c5c4801551d1a5272d5cb50141900286 100644 (file)
@@ -17,6 +17,7 @@ Requires:   qemu >= 0.14.1
 Requires:   qemu-arm-static >= 0.14.1
 Requires:   sudo
 Requires:   git-buildpackage-rpm = 0.6.0git20120810
+Requires:   createrepo
 %if 0%{?fedora_version}
 Requires:   rpm-build
 %else
index bebefb6364dff3fd7ccb3cd8aa71dfb73009d084..f721c1eb5d81bd6362a95a51476e8aaa877bd588 100644 (file)
@@ -401,6 +401,8 @@ def do(opts, args):
                 msger.info('RPMs have been copied from %s to %s' \
                            % (out_dir, opts.out))
                 out_dir = os.path.abspath(opts.out)
+                subprocess.call(["createrepo", out_dir])
+                msger.info("RPM repo has been created: %s" % out_dir)
             msger.info('The buildroot was: %s' % build_root)
             msger.info('Binaries RPM packages can be found here:'\
                        '\n     %s' % out_dir)