GitLab's annual major release is around the corner. Along with a lot of new and exciting features, there will be a few breaking changes. Learn more here.

Commit a4bdd104 authored by Hans-Christoph Steiner's avatar Hans-Christoph Steiner
Browse files

Merge branch 'remove-kivy' into 'master'

build: remove unused, unmaintained Kivy build method

See merge request !441
parents b0b9f2f6 513c9589
Pipeline #16543833 passed with stage
in 48 minutes and 41 seconds
......@@ -31,6 +31,8 @@ metadata_v0:
- git checkout $GITCOMMIT
- cd fdroiddata
- ../tests/dump_internal_metadata_format.py
- sed -i -e '/kivy\W false/d'
metadata/dump_*/*.yaml
- diff -uw metadata/dump_*
debian_testing:
......
......@@ -489,9 +489,6 @@ def build_local(app, build, vcs, build_dir, output_dir, log_dir, srclib_dir, ext
p = FDroidPopen(cmd, cwd=root_dir)
elif bmethod == 'kivy':
pass
elif bmethod == 'buildozer':
pass
......@@ -637,67 +634,6 @@ def build_local(app, build, vcs, build_dir, output_dir, log_dir, srclib_dir, ext
bindir = os.path.join(root_dir, 'target')
elif bmethod == 'kivy':
logging.info("Building Kivy project...")
spec = os.path.join(root_dir, 'buildozer.spec')
if not os.path.exists(spec):
raise BuildException("Expected to find buildozer-compatible spec at {0}"
.format(spec))
defaults = {'orientation': 'landscape', 'icon': '',
'permissions': '', 'android.api': "18"}
bconfig = ConfigParser(defaults, allow_no_value=True)
bconfig.read(spec)
distdir = os.path.join('python-for-android', 'dist', 'fdroid')
if os.path.exists(distdir):
shutil.rmtree(distdir)
modules = bconfig.get('app', 'requirements').split(',')
cmd = 'ANDROIDSDK=' + config['sdk_path']
cmd += ' ANDROIDNDK=' + ndk_path
cmd += ' ANDROIDNDKVER=' + build.ndk
cmd += ' ANDROIDAPI=' + str(bconfig.get('app', 'android.api'))
cmd += ' VIRTUALENV=virtualenv'
cmd += ' ./distribute.sh'
cmd += ' -m ' + "'" + ' '.join(modules) + "'"
cmd += ' -d fdroid'
p = subprocess.Popen(cmd, cwd='python-for-android', shell=True)
if p.returncode != 0:
raise BuildException("Distribute build failed")
cid = bconfig.get('app', 'package.domain') + '.' + bconfig.get('app', 'package.name')
if cid != app.id:
raise BuildException("Package ID mismatch between metadata and spec")
orientation = bconfig.get('app', 'orientation', 'landscape')
if orientation == 'all':
orientation = 'sensor'
cmd = ['./build.py'
'--dir', root_dir,
'--name', bconfig.get('app', 'title'),
'--package', app.id,
'--version', bconfig.get('app', 'version'),
'--orientation', orientation
]
perms = bconfig.get('app', 'permissions')
for perm in perms.split(','):
cmd.extend(['--permission', perm])
if config.get('app', 'fullscreen') == 0:
cmd.append('--window')
icon = bconfig.get('app', 'icon.filename')
if icon:
cmd.extend(['--icon', os.path.join(root_dir, icon)])
cmd.append('release')
p = FDroidPopen(cmd, cwd=distdir)
elif bmethod == 'buildozer':
logging.info("Building Kivy project using buildozer...")
......@@ -812,11 +748,6 @@ def build_local(app, build, vcs, build_dir, output_dir, log_dir, srclib_dir, ext
raise BuildException('Failed to find output')
src = m.group(1)
src = os.path.join(bindir, src) + '.apk'
elif omethod == 'kivy':
src = os.path.join('python-for-android', 'dist', 'default', 'bin',
'{0}-{1}-release.apk'.format(
bconfig.get('app', 'title'),
bconfig.get('app', 'version')))
elif omethod == 'buildozer':
src = None
......
......@@ -213,7 +213,6 @@ build_flags_order = [
'patch',
'gradle',
'maven',
'kivy',
'buildozer',
'output',
'srclibs',
......@@ -256,7 +255,6 @@ class Build(dict):
self.patch = []
self.gradle = []
self.maven = False
self.kivy = False
self.buildozer = False
self.output = None
self.srclibs = []
......@@ -299,7 +297,7 @@ class Build(dict):
raise AttributeError("No such attribute: " + name)
def build_method(self):
for f in ['maven', 'gradle', 'kivy', 'buildozer']:
for f in ['maven', 'gradle', 'buildozer']:
if self.get(f):
return f
if self.output:
......@@ -310,7 +308,7 @@ class Build(dict):
def output_method(self):
if self.output:
return 'raw'
for f in ['maven', 'gradle', 'kivy', 'buildozer']:
for f in ['maven', 'gradle', 'buildozer']:
if self.get(f):
return f
return 'ant'
......@@ -871,7 +869,7 @@ def post_metadata_parse(app):
elif v == [False]:
return ['no']
_bool_allowed = ('disable', 'kivy', 'maven', 'buildozer')
_bool_allowed = ('disable', 'maven', 'buildozer')
builds = []
if 'builds' in app:
......@@ -1114,7 +1112,7 @@ def write_yaml(mf, app):
value = getattr(build, field)
if field == 'gradle' and value == ['off']:
value = [ruamel.yaml.scalarstring.SingleQuotedScalarString('off')]
if field in ('disable', 'kivy', 'maven', 'buildozer'):
if field in ('disable', 'maven', 'buildozer'):
if value == 'no':
continue
elif value == 'yes':
......
......@@ -55,7 +55,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -89,7 +88,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -123,7 +121,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -158,7 +155,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......
......@@ -76,7 +76,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -111,7 +110,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -147,7 +145,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -183,7 +180,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -219,7 +215,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -255,7 +250,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -290,7 +284,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -325,7 +318,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -360,7 +352,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -395,7 +386,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -430,7 +420,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -465,7 +454,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -499,7 +487,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -534,7 +521,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -568,7 +554,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -603,7 +588,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -638,7 +622,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -673,7 +656,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -715,7 +697,6 @@ builds:
gradleprops: []
init: rm android-libs/Donations/custom_rules.xml && git clone https://github.com/dschuermann/HtmlSpanner
android-libs/HtmlSpanner
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -762,7 +743,6 @@ builds:
gradleprops: []
init: rm android-libs/Donations/custom_rules.xml && git clone https://github.com/dschuermann/HtmlSpanner
android-libs/HtmlSpanner
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -804,7 +784,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -841,7 +820,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -878,7 +856,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -915,7 +892,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -952,7 +928,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -989,7 +964,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -1026,7 +1000,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -1063,7 +1036,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......
......@@ -73,7 +73,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -119,7 +118,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -157,7 +155,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -194,7 +191,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -231,7 +227,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -267,7 +262,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -303,7 +297,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -339,7 +332,6 @@ builds:
- 'yes'
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......
......@@ -77,7 +77,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -114,7 +113,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -151,7 +149,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -188,7 +185,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -222,7 +218,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -258,7 +253,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -294,7 +288,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -330,7 +323,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -366,7 +358,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -401,7 +392,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -436,7 +426,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -471,7 +460,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -506,7 +494,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -541,7 +528,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -576,7 +562,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -611,7 +596,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -646,7 +630,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -681,7 +664,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -716,7 +698,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -751,7 +732,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -786,7 +766,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -821,7 +800,6 @@ builds:
gradle: []
gradleprops: []
init: ''
kivy: false
maven: false
ndk: null
novcheck: false
......@@ -856,7 +834,6 @@ builds:
gradle: []
gradleprops: []
init: ''