mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-15 23:42:37 +03:00
add MobAdMob srclib: FOSS admob replacement
This commit is contained in:
parent
94acf0ed2b
commit
cf8df0ba62
1 changed files with 18 additions and 0 deletions
|
@ -1170,6 +1170,24 @@ def getsrclib(spec, extlib_dir, sdk_path, basepath=False):
|
|||
vcs.gotorevision(ref)
|
||||
return sdir
|
||||
|
||||
if name == 'MobAdMob':
|
||||
sdir = os.path.join(extlib_dir, 'MobAdMob')
|
||||
vcs = getvcs('git',
|
||||
'https://github.com/mar-v-in/MobAdMob.git', sdir, sdk_path)
|
||||
vcs.gotorevision(ref)
|
||||
libdir = os.path.join(sdir, 'MobAdMob')
|
||||
pp = open(os.path.join(libdir, 'project.properties'), 'w')
|
||||
pp.write('android.library=true\n')
|
||||
pp.write('target=android-16\n')
|
||||
pp.close()
|
||||
if subprocess.call([os.path.join(sdk_path, 'tools', 'android'),
|
||||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating MobAdMob project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
raise BuildException('Unknown srclib ' + name)
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue