Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[boost] visibility #4453

Merged
merged 3 commits into from
Feb 4, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions recipes/boost/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ class BoostConan(ConanFile):
"pch": [True, False],
"extra_b2_flags": "ANY", # custom b2 flags
"i18n_backend": ["iconv", "icu", None],
"visibility": ["global", "protected", "hidden"],
}
options.update({"without_{}".format(_name): [True, False] for _name in CONFIGURE_OPTIONS})

Expand Down Expand Up @@ -122,6 +123,7 @@ class BoostConan(ConanFile):
"pch": True,
"extra_b2_flags": "None",
"i18n_backend": "iconv",
"visibility": "hidden",
}
default_options.update({"without_{}".format(_name): False for _name in CONFIGURE_OPTIONS})
default_options.update({"without_{}".format(_name): True for _name in ("graph_parallel", "mpi", "python")})
Expand Down Expand Up @@ -370,10 +372,10 @@ def requirements(self):
if self._with_lzma:
self.requires("xz_utils/5.2.5")
if self._with_zstd:
self.requires("zstd/1.4.5")
self.requires("zstd/1.4.8")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

auto-added by conventions


if self._with_icu:
self.requires("icu/68.1")
self.requires("icu/68.2")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

auto-added by conventions

elif self._with_iconv:
self.requires("libiconv/1.16")

Expand Down Expand Up @@ -804,6 +806,7 @@ def add_defines(library):

# For details https://boostorg.github.io/build/manual/master/index.html
flags.append("threading=%s" % ("single" if not self.options.multithreading else "multi" ))
flags.append("visibility=%s" % self.options.visibility)

flags.append("link=%s" % ("static" if not self.options.shared else "shared"))
if self.settings.build_type == "Debug":
Expand Down Expand Up @@ -875,8 +878,6 @@ def add_defines(library):
cxx_flags.append("-DBOOST_AC_USE_PTHREADS")
cxx_flags.append("-DBOOST_SP_USE_PTHREADS")

cxx_flags.append("-fvisibility=hidden")
cxx_flags.append("-fvisibility-inlines-hidden")
cxx_flags.append("-fembed-bitcode")

if self._with_iconv:
Expand Down