mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-14 11:10:30 +03:00
Merge compilesdk= into target=, better documentation about target=
This commit is contained in:
parent
778b15322c
commit
3e789bd6b5
4 changed files with 22 additions and 28 deletions
|
|
@ -595,17 +595,6 @@ def build_local(app, thisbuild, vcs, build_dir, output_dir, srclib_dir, extlib_d
|
|||
flavours = thisbuild['gradle'].split(',')
|
||||
gradle_dir = root_dir
|
||||
|
||||
|
||||
if 'compilesdk' in thisbuild:
|
||||
level = thisbuild["compilesdk"].split('-')[1]
|
||||
subprocess.call(['sed', '-i',
|
||||
's@compileSdkVersion[ ]*[0-9]*@compileSdkVersion '+level+'@g',
|
||||
'build.gradle'], cwd=root_dir)
|
||||
if '@' in thisbuild['gradle']:
|
||||
subprocess.call(['sed', '-i',
|
||||
's@compileSdkVersion[ ]*[0-9]*@compileSdkVersion '+level+'@g',
|
||||
'build.gradle'], cwd=gradle_dir)
|
||||
|
||||
if len(flavours) == 1 and flavours[0] in ['main', 'yes', '']:
|
||||
flavours[0] = ''
|
||||
|
||||
|
|
|
|||
|
|
@ -937,7 +937,7 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, onserver=
|
|||
|
||||
|
||||
# Generate (or update) the ant build file, build.xml...
|
||||
if (updatemode != 'no' and build['type'] == 'ant'):
|
||||
if updatemode != 'no' and build['type'] == 'ant':
|
||||
parms = [os.path.join(config['sdk_path'], 'tools', 'android'),
|
||||
'update', 'project']
|
||||
if 'target' in build and build['target']:
|
||||
|
|
@ -1013,6 +1013,16 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, onserver=
|
|||
if flavour in ['main', 'yes', '']:
|
||||
flavour = None
|
||||
|
||||
if 'target' in thisbuild:
|
||||
n = thisbuild["target"].split('-')[1]
|
||||
subprocess.call(['sed', '-i',
|
||||
's@compileSdkVersion[ ]*[0-9]*@compileSdkVersion '+n+'@g',
|
||||
'build.gradle'], cwd=root_dir)
|
||||
if '@' in thisbuild['gradle']:
|
||||
subprocess.call(['sed', '-i',
|
||||
's@compileSdkVersion[ ]*[0-9]*@compileSdkVersion '+n+'@g',
|
||||
'build.gradle'], cwd=gradle_dir)
|
||||
|
||||
# Remove forced debuggable flags
|
||||
print "Removing debuggable flags..."
|
||||
for path in manifest_paths(root_dir, flavour):
|
||||
|
|
|
|||
|
|
@ -698,7 +698,7 @@ def write_metadata(dest, app):
|
|||
# This defines the preferred order for the build items - as in the
|
||||
# manual, they're roughly in order of application.
|
||||
keyorder = ['disable', 'commit', 'subdir', 'submodules', 'init',
|
||||
'gradle', 'maven', 'oldsdkloc', 'target', 'compilesdk',
|
||||
'gradle', 'maven', 'oldsdkloc', 'target',
|
||||
'update', 'encoding', 'forceversion', 'forcevercode', 'rm',
|
||||
'fixtrans', 'fixapos', 'extlibs', 'srclibs', 'patch',
|
||||
'prebuild', 'scanignore', 'scandelete', 'build', 'buildjni',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue