Skip to content

Commit

Permalink
add option to disable dyload (#1502)
Browse files Browse the repository at this point in the history
  • Loading branch information
jgsogo authored May 5, 2020
1 parent 5992b6c commit 3c9f9ac
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions recipes/icu/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,14 @@ class ICUBase(ConanFile):
"fPIC": [True, False],
"data_packaging": ["files", "archive", "library", "static"],
"with_unit_tests": [True, False],
"silent": [True, False]}
"silent": [True, False],
"with_dyload": [True, False]}
default_options = {"shared": False,
"fPIC": True,
"data_packaging": "archive",
"with_unit_tests": False,
"silent": True}
"silent": True,
"with_dyload": True}

@property
def _is_msvc(self):
Expand Down Expand Up @@ -156,6 +158,9 @@ def build_config_args(self):
"--disable-samples",
"--disable-layout",
"--disable-layoutex"]

if not self.options.with_dyload:
args += ["--disable-dyload"]

if self.cross_building:
if self._env_build.build:
Expand Down Expand Up @@ -242,7 +247,7 @@ def lib_name(lib):

if not self.options.shared:
self.cpp_info.defines.append("U_STATIC_IMPLEMENTATION")
if self.settings.os == 'Linux':
if self.settings.os == 'Linux' and self.options.with_dyload:
self.cpp_info.libs.append('dl')

if self.settings.os == 'Windows':
Expand Down

0 comments on commit 3c9f9ac

Please sign in to comment.