Currently we have 5 variables that are used to specify options for building libcxx
- LIBCXX_CXX_FEATURE_FLAGS
- LIBCXX_CXX_WARNING_FLAGS
- LIBCXX_CXX_REQUIRED_FLAGS
- compile_flags (in libcxx/lib)
- link_flags (in libcxx/lib)
The first three all get put into CMAKE_CXX_FLAGS.
This changes the way flags are handled by only using 3 different options:
- LIBCXX_CXX_FLAGS - general compile and link flags.
- LIBCXX_COMPILE_FLAGS - compile only flags.
- LIBCXX_LINK_FLAGS - link only flags.
This patch also removes the warning about -nostdinc++ being unused during linking.