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: add BOOST_FILESYSTEM_VERSION #11988

Merged
merged 3 commits into from
Aug 17, 2022
Merged
Changes from 2 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
6 changes: 6 additions & 0 deletions recipes/boost/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ class BoostConan(ConanFile):
"system_no_deprecated": [True, False],
"asio_no_deprecated": [True, False],
"filesystem_no_deprecated": [True, False],
"filesystem_version": [None, "3", "4"],
"fPIC": [True, False],
"layout": ["system", "versioned", "tagged", "b2-default"],
"magic_autolink": [True, False], # enables BOOST_ALL_NO_LIB
Expand Down Expand Up @@ -113,6 +114,7 @@ class BoostConan(ConanFile):
"system_no_deprecated": False,
"asio_no_deprecated": False,
"filesystem_no_deprecated": False,
"filesystem_version": None,
"fPIC": True,
"layout": "system",
"magic_autolink": False,
Expand Down Expand Up @@ -546,6 +548,7 @@ def package_id(self):
self.info.options.header_only = True
else:
del self.info.options.debug_level
del self.info.options.filesystem_version
del self.info.options.pch
del self.info.options.python_executable # PATH to the interpreter is not important, only version matters
if self.options.without_python:
Expand Down Expand Up @@ -1434,6 +1437,9 @@ def package_info(self):
if self.options.filesystem_no_deprecated:
self.cpp_info.components["headers"].defines.append("BOOST_FILESYSTEM_NO_DEPRECATED")

if self.options.filesystem_version is not None:
self.cpp_info.components["headers"].defines.append("BOOST_FILESYSTEM_VERSION=%s" % self.options.filesystem_version)

if self.options.segmented_stacks:
self.cpp_info.components["headers"].defines.extend(["BOOST_USE_SEGMENTED_STACKS", "BOOST_USE_UCONTEXT"])

Expand Down