In my attempt to answer my own question Clang linker reports "symbol not found", despite 'nm -m' revealing that the name exists in a library that is being linked against, I have discovered links that indicate that I must build Boost on OS X so that it explicitly uses Clang and links to libc++
here, here, and here.
Following the steps indicated (with the help of additional googling to assist with/confirm the process of editing user-config.jam
, placing it in my home directory, and other necessary steps), I have added the following lines to my ~/user-config.jam
file:
using clanglibcpp : 11
: "/usr/bin/clang++"
: <cxxflags>"-std=c++11 -stdlib=libc++" <linkflags>"-stdlib=libc++"
;
I have then run ./b2
from the $BOOST_ROOT
directory:
./b2 toolset=clanglibcpp-11 --with-filesystem variant=release link=static threading=multi
Unfortunately, no matter what I do, I receive the following error:
ERROR: rule "clanglibcpp.init" unknown in module "toolset"
I have confirmed that /usr/bin/clang++
exists at the path indicated (it does). I have also tried adding the above lines to $BOOST_ROOT/tools/build/v2/user-config.jam
(no luck). I have also tried running ./bootstrap.sh
from the boost root directory, as well as running ./b2 --clean
. No luck.
What am I supposed to do to actually get the toolset in user-config.jam
to take effect for my Boost build on OS X?