chiark / gitweb /
new srclib AppMsg
authorDavid Black <david8black@gmail.com>
Thu, 3 Jan 2013 17:48:00 +0000 (17:48 +0000)
committerDavid Black <david8black@gmail.com>
Thu, 3 Jan 2013 17:48:00 +0000 (17:48 +0000)
fdroidserver/common.py

index 8c41f29297e5cd2095d556a7d63de04d0ce580ad..84d15fc0925c3a8c5d27e453a0962a16283bbe28 100644 (file)
@@ -1381,6 +1381,20 @@ def getsrclib(spec, extlib_dir, sdk_path, basepath=False):
         vcs.gotorevision(ref)
         return sdir
 
+    if name == 'AppMsg':
+        sdir = os.path.join(extlib_dir, 'AppMsg')
+        vcs = getvcs('git',
+           'https://github.com/johnkil/Android-AppMsg.git', sdir, sdk_path)
+        vcs.gotorevision(ref)
+        libdir = os.path.join(sdir, 'library')
+        if subprocess.call([os.path.join(sdk_path, 'tools', 'android'),
+            'update', 'project', '-p',
+            libdir]) != 0:
+            raise BuildException('Error updating AppMsg project')
+        if basepath:
+            return sdir
+        return libdir
+
     raise BuildException('Unknown srclib ' + name)