Do not install gradle. Use gradlew script.
This commit is contained in:
parent
e602897e6b
commit
b6bbf9b098
|
@ -7,7 +7,6 @@ from . import (
|
|||
aria2,
|
||||
armhf,
|
||||
flatpak,
|
||||
gradle,
|
||||
gumbo,
|
||||
icu4c,
|
||||
ios_fat_lib,
|
||||
|
|
|
@ -525,7 +525,7 @@ class GradleBuilder(Builder):
|
|||
shutil.copytree(self.source_path, self.build_path)
|
||||
|
||||
def _compile(self, context):
|
||||
command = "gradle {gradle_target} {gradle_option}"
|
||||
command = "./gradlew {gradle_target} {gradle_option}"
|
||||
command = command.format(
|
||||
gradle_target=self.gradle_target,
|
||||
gradle_option=self.gradle_option)
|
||||
|
|
|
@ -1,32 +0,0 @@
|
|||
from .base import (
|
||||
Dependency,
|
||||
ReleaseDownload,
|
||||
Builder as BaseBuilder)
|
||||
|
||||
from kiwixbuild.utils import Remotefile, pj, copy_tree, add_execution_right
|
||||
|
||||
class Gradle(Dependency):
|
||||
neutral = True
|
||||
name = "gradle"
|
||||
|
||||
class Source(ReleaseDownload):
|
||||
archive = Remotefile('gradle-5.2-bin.zip',
|
||||
'ff322863250159595e93b5a4d17a6f0d21c59a1a0497c1e1cf1d53826485503f',
|
||||
'https://services.gradle.org/distributions/gradle-5.2-bin.zip')
|
||||
|
||||
class Builder(BaseBuilder):
|
||||
@property
|
||||
def install_path(self):
|
||||
return self.buildEnv.install_dir
|
||||
|
||||
def build(self):
|
||||
self.command('install', self._install)
|
||||
|
||||
def _install(self, context):
|
||||
copy_tree(
|
||||
pj(self.source_path, "bin"),
|
||||
pj(self.install_path, "bin"),
|
||||
post_copy_function = add_execution_right)
|
||||
copy_tree(
|
||||
pj(self.source_path, "lib"),
|
||||
pj(self.install_path, "lib"))
|
|
@ -123,7 +123,7 @@ class AndroidX8664(AndroidPlatformInfo):
|
|||
|
||||
class Android(MetaPlatformInfo):
|
||||
name = "android"
|
||||
toolchain_names = ['android-sdk', 'gradle']
|
||||
toolchain_names = ['android-sdk']
|
||||
compatible_hosts = ['fedora', 'debian']
|
||||
|
||||
@property
|
||||
|
@ -143,10 +143,5 @@ class Android(MetaPlatformInfo):
|
|||
def sdk_builder(self):
|
||||
return get_target_step('android-sdk', 'neutral')
|
||||
|
||||
@property
|
||||
def gradle_builder(self):
|
||||
return get_target_step('gradle', 'neutral')
|
||||
|
||||
def set_env(self, env):
|
||||
env['ANDROID_HOME'] = self.sdk_builder.install_path
|
||||
env['PATH'] = ':'.join([pj(self.gradle_builder.install_path, 'bin'), env['PATH']])
|
||||
|
|
|
@ -54,7 +54,6 @@ base_deps_versions = {
|
|||
'libmicrohttpd' : '0.9.66',
|
||||
'gumbo' : '0.10.1',
|
||||
'icu4c' : '58.2',
|
||||
'gradle' : '5.2',
|
||||
'libaria2' : '1.33.1',
|
||||
'libmagic' : '5.35',
|
||||
'android-sdk' : 'r25.2.3',
|
||||
|
|
Loading…
Reference in New Issue