Add a option to skip the source installation.
It make the kiwix-build.py script run a bit father.
This commit is contained in:
parent
0390135a42
commit
81796e7125
|
@ -710,6 +710,7 @@ class android_ndk(Toolchain):
|
||||||
|
|
||||||
class Builder:
|
class Builder:
|
||||||
def __init__(self, options):
|
def __init__(self, options):
|
||||||
|
self.options = options
|
||||||
self.targets = OrderedDict()
|
self.targets = OrderedDict()
|
||||||
self.buildEnv = buildEnv = BuildEnv(options, self.targets)
|
self.buildEnv = buildEnv = BuildEnv(options, self.targets)
|
||||||
|
|
||||||
|
@ -738,6 +739,10 @@ class Builder:
|
||||||
yield targetName
|
yield targetName
|
||||||
|
|
||||||
def prepare_sources(self):
|
def prepare_sources(self):
|
||||||
|
if self.options.skip_source_prepare:
|
||||||
|
print("SKIP")
|
||||||
|
return
|
||||||
|
|
||||||
toolchain_sources = (tlc.source for tlc in self.buildEnv.toolchains if tlc.source)
|
toolchain_sources = (tlc.source for tlc in self.buildEnv.toolchains if tlc.source)
|
||||||
for toolchain_source in toolchain_sources:
|
for toolchain_source in toolchain_sources:
|
||||||
print("prepare sources for toolchain {} :".format(toolchain_source.name))
|
print("prepare sources for toolchain {} :".format(toolchain_source.name))
|
||||||
|
@ -784,6 +789,8 @@ def parse_args():
|
||||||
" log files per commands"))
|
" log files per commands"))
|
||||||
parser.add_argument('--no-cert-check', action='store_true',
|
parser.add_argument('--no-cert-check', action='store_true',
|
||||||
help="Skip SSL certificate verification during download")
|
help="Skip SSL certificate verification during download")
|
||||||
|
parser.add_argument('--skip-source-prepare', action='store_true',
|
||||||
|
help="Skip the source download part")
|
||||||
return parser.parse_args()
|
return parser.parse_args()
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue