[Bug 266748] '#include <memory_resource>' isn't available despite it being required by c++17
Date: Mon, 03 Oct 2022 04:18:19 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=266748
--- Comment #7 from Mark Millard <marklmi26-fbsd@yahoo.com> ---
(In reply to Mark Millard from comment #6)
Hmm. CMake/TestCxx17Library.cmake has this for when it
rejects the C++17 library support:
elseif(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
message(
"Compiler detected is clang++.\n If not using libcxx, ensure a GCC
toolchain version equal or greater "
"than 9.0 gets picked up. Check with 'clang++ -v'. Or use the
--gcc-toolchain compiler option "
"(added to CMAKE_CXX_FLAGS) to point to a newer GCC installation."
)
--gcc-toolchain is not something I was aware of. Its description from:
https://releases.llvm.org/15.0.0/tools/clang/docs/ClangCommandLineReference.html
is:
--gcc-toolchain=<arg>
Search for GCC installation in the specified directory on targets which
commonly use GCC. The directory usually contains
‘lib{,32,64}/gcc{,-cross}/$triple’ and ‘include’. If specified, sysroot is
skipped for GCC detection. Note: executables (e.g. ld) used by the compiler are
not overridden by the selected GCC installation
I wonder if getting that set up is an option via ports.
Correction to earlier note: The "If not using libcxx" suggests that libstdc++
might not be required for clang if/when libc++ is sufficient --but the above
indicates that libstdc++ would still be a possibility.
But, I also seem to remember that there is a C++ language change that creates
a ABI change requirement that is pending for FreeBSD. Such could create
problems until things match up for clang++ vs. g++ .
--
You are receiving this mail because:
You are the assignee for the bug.