mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-15 15:32:30 +03:00
Handle split path srclibs properly on buildserver
This commit is contained in:
parent
8983aaf2f9
commit
ea8d90040e
2 changed files with 22 additions and 4 deletions
|
@ -843,10 +843,12 @@ class MetaDataException(Exception):
|
|||
|
||||
|
||||
# Get the specified source library.
|
||||
# Returns the path to it.
|
||||
# Returns the path to it. Normally this is the path to be used when referencing
|
||||
# it, which may be a subdirectory of the actual project. If you want the base
|
||||
# directory of the project, pass 'basepath=True'.
|
||||
# TODO: These are currently just hard-coded in this method. It will be a
|
||||
# metadata-driven system eventually, but not yet.
|
||||
def getsrclib(spec, extlib_dir, sdk_path):
|
||||
def getsrclib(spec, extlib_dir, sdk_path, basepath=False):
|
||||
name, ref = spec.split('@')
|
||||
|
||||
if name == 'GreenDroid':
|
||||
|
@ -866,6 +868,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating ActionBarSherlock project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'Amazing-ListView':
|
||||
|
@ -878,6 +882,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating Amazing-ListView project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'ViewPagerIndicator':
|
||||
|
@ -890,6 +896,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating Android-ViewPagerIndicator project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'UITableView':
|
||||
|
@ -902,6 +910,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating UITableView project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'ViewPagerTabs':
|
||||
|
@ -929,6 +939,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating ActionBar project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'ActionBarNW':
|
||||
|
@ -941,6 +953,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating ActionBarNW project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'FacebookSDK':
|
||||
|
@ -953,6 +967,8 @@ def getsrclib(spec, extlib_dir, sdk_path):
|
|||
'update', 'project', '-p',
|
||||
libdir]) != 0:
|
||||
raise BuildException('Error updating FacebookSDK project')
|
||||
if basepath:
|
||||
return sdir
|
||||
return libdir
|
||||
|
||||
if name == 'OI':
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue