Reply to ld: symbol(s) not found for architecture arm64 This has caused a fair bit of headache for me, too. In general, favor clang++ for C++. There are a number of things that clang may not do, see, for example, StackOverflow How do I compile C++ with Clang?. Developer Tools & Services Xcode May ’24