Skip to content

Commit

Permalink
don't raise if compiler.cppstd set and compiler default standard is l…
Browse files Browse the repository at this point in the history
…ower then C++11
  • Loading branch information
SpaceIm committed Dec 8, 2022
1 parent af74024 commit 0dd9649
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions recipes/boost/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -457,12 +457,13 @@ def validate(self):
if any([not self.options.get_safe(f"without_{library}", True) for library in self._cxx11_boost_libraries]):
if self.settings.compiler.get_safe("cppstd"):
check_min_cppstd(self, 11)
version_cxx11_standard = self._min_compiler_version_default_cxx11
if version_cxx11_standard and Version(self.settings.compiler.version) < version_cxx11_standard:
raise ConanInvalidConfiguration(
f"Boost.{{{','.join(self._cxx11_boost_libraries)}}} requires a c++11 compiler "
"(please set compiler.cppstd or use a newer compiler)"
)
else:
version_cxx11_standard = self._min_compiler_version_default_cxx11
if version_cxx11_standard and Version(self.settings.compiler.version) < version_cxx11_standard:
raise ConanInvalidConfiguration(
f"Boost.{{{','.join(self._cxx11_boost_libraries)}}} requires a c++11 compiler "
"(please set compiler.cppstd or use a newer compiler)"
)

def _with_dependency(self, dependency):
"""
Expand Down

0 comments on commit 0dd9649

Please sign in to comment.