Skip to content

Commit

Permalink
Merge pull request #2919 from dgovil/boost_python_clang15_fixes
Browse files Browse the repository at this point in the history
Disable BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT for MacOS builds

(Internal change: 2317210)
  • Loading branch information
pixar-oss committed Feb 22, 2024
2 parents 3bcae24 + 1f77f0d commit b226a1c
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion build_scripts/build_usd.py
Original file line number Diff line number Diff line change
Expand Up @@ -895,7 +895,14 @@ def InstallBoost_Helper(context, force, buildArgs):
# Must specify toolset=clang to ensure install_name for boost
# libraries includes @rpath
b2_settings.append("toolset=clang")

#
# Xcode 15.3 (and hence Apple Clang 15) removed the global
# declaration of std::piecewise_construct which causes boost build
# to fail.
# https://developer.apple.com/documentation/xcode-release-notes/xcode-15_3-release-notes.
# A fix for the same is also available in boost 1.84:
# https://github.com/boostorg/container/commit/79a75f470e75f35f5f2a91e10fcc67d03b0a2160
b2_settings.append(f"define=BOOST_UNORDERED_HAVE_PIECEWISE_CONSTRUCT=0")
if macOSArch:
b2_settings.append("cxxflags=\"{0}\"".format(macOSArch))
b2_settings.append("cflags=\"{0}\"".format(macOSArch))
Expand Down

0 comments on commit b226a1c

Please sign in to comment.