Fix dependency detection for zim-tools.
This commit is contained in:
parent
da31dd428e
commit
39a93b07b3
|
@ -13,12 +13,12 @@ class AllBaseDependencies(Dependency):
|
||||||
@classmethod
|
@classmethod
|
||||||
def get_dependencies(cls, platformInfo, allDeps):
|
def get_dependencies(cls, platformInfo, allDeps):
|
||||||
base_deps = ['zlib', 'lzma', 'zstd', 'xapian-core', 'pugixml', 'libcurl', 'icu4c', 'mustache', 'libmicrohttpd']
|
base_deps = ['zlib', 'lzma', 'zstd', 'xapian-core', 'pugixml', 'libcurl', 'icu4c', 'mustache', 'libmicrohttpd']
|
||||||
# zimwriterfs from zim-tools
|
|
||||||
if platformInfo.build not in ('android', 'win32'):
|
|
||||||
base_deps += ['libmagic', 'gumbo']
|
|
||||||
|
|
||||||
# zimtools
|
# zimtools
|
||||||
|
# We do not build zimtools at all on "android" and "iOS"
|
||||||
if platformInfo.build not in ('android', 'iOS'):
|
if platformInfo.build not in ('android', 'iOS'):
|
||||||
base_deps += ['docoptcpp']
|
base_deps += ['docoptcpp']
|
||||||
|
if platformInfo.build != 'win32':
|
||||||
|
# zimwriterfs
|
||||||
|
base_deps += ['libmagic', 'gumbo']
|
||||||
|
|
||||||
return base_deps
|
return base_deps
|
||||||
|
|
|
@ -12,12 +12,18 @@ class ZimTools(Dependency):
|
||||||
git_dir = "zim-tools"
|
git_dir = "zim-tools"
|
||||||
|
|
||||||
class Builder(MesonBuilder):
|
class Builder(MesonBuilder):
|
||||||
dependencies = ['libzim', 'docoptcpp']
|
@classmethod
|
||||||
|
def get_dependencies(cls, platformInfo, allDeps):
|
||||||
|
base_deps = ['libzim', 'docoptcpp']
|
||||||
|
if platformInfo.build != 'win32':
|
||||||
|
base_deps += ['libmagic', 'gumbo']
|
||||||
|
return base_deps
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def configure_option(self):
|
def configure_option(self):
|
||||||
base_option = ""
|
base_option = ""
|
||||||
if self.buildEnv.platformInfo.build not in ('android', 'win32'):
|
# We don't build zimwriterfs on win32, and so we don't have magic
|
||||||
|
if self.buildEnv.platformInfo.build != 'win32':
|
||||||
base_option += " -Dmagic-install-prefix={buildEnv.install_dir}"
|
base_option += " -Dmagic-install-prefix={buildEnv.install_dir}"
|
||||||
if self.buildEnv.platformInfo.static:
|
if self.buildEnv.platformInfo.static:
|
||||||
base_option += " -Dstatic-linkage=true"
|
base_option += " -Dstatic-linkage=true"
|
||||||
|
|
Loading…
Reference in New Issue