chiark / gitweb /
srclib: KoushWidgets for Clockworkmod Superuser
authorDavid Black <david8black@gmail.com>
Mon, 25 Feb 2013 12:02:31 +0000 (12:02 +0000)
committerDavid Black <david8black@gmail.com>
Mon, 25 Feb 2013 12:02:31 +0000 (12:02 +0000)
fdroidserver/common.py

index 1716ce3549ab0172c82e2ebf6524973fdf3c7a29..7626dc07b283d8a8ee4657b94f5ba7c1d27e6c49 100644 (file)
@@ -1532,6 +1532,20 @@ def getsrclib(spec, extlib_dir, sdk_path, basepath=False):
         vcs.gotorevision(ref)
         return sdir
 
+    if name == 'KoushWidgets':
+        sdir = os.path.join(extlib_dir, 'KoushWidgets')
+        vcs = getvcs('git',
+           'https://github.com/koush/Widgets', sdir, sdk_path)
+        vcs.gotorevision(ref)
+        libdir = os.path.join(sdir, 'Widgets')
+        if subprocess.call([os.path.join(sdk_path, 'tools', 'android'),
+            'update', 'project', '-p',
+            libdir]) != 0:
+            raise BuildException('Error updating KoushWidgets project')
+        if basepath:
+            return sdir
+        return libdir
+
     raise BuildException('Unknown srclib ' + name)