From 4eb95fd4cce6b0ec4ae672a2847539e22722ffb4 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Mon, 4 Feb 2019 11:06:55 +0100 Subject: [PATCH] Pass correct option `-Dstatic_linkage` to libzim in native_mixed platform. In native_mixed, we want to build a shared lib but we need to compile with the static lib of the dependencies. --- kiwixbuild/dependencies/libzim.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kiwixbuild/dependencies/libzim.py b/kiwixbuild/dependencies/libzim.py index 6113dce..fdcff3a 100644 --- a/kiwixbuild/dependencies/libzim.py +++ b/kiwixbuild/dependencies/libzim.py @@ -2,6 +2,7 @@ from .base import ( Dependency, GitClone, MesonBuilder) +from kiwixbuild._global import option class Libzim(Dependency): name = "libzim" @@ -21,4 +22,6 @@ class Libzim(Dependency): return "-DUSE_BUFFER_HEADER=false" if platformInfo.build == 'iOS': return "-Db_bitcode=true" + if platformInfo.name == 'native_mixed' and option('target') == 'libzim': + return "-Dstatic-linkage=true" return ""