I'm not certain about needing CMAKE_SYSTEM_PROCESSOR here or if it is fine to just use CMAKE_C_COMPILER_TARGET/CMAKE_CXX_COMPILER_TARGET for this? If there isn't a complaint from CMake about Swift not supporting CMAKE_OSX_ARCHITECTURES, I don't care too much, this should be fine....
The documentation forCMAKE_<LANG>_COMPILER_TARGET,https://cmake.org/cmake/help/latest/variable/CMAKE_LANG_COMPILER_TARGET.html, says: This variable may only be set in a toolchain file specified by the CMAKE_TOOLCHAIN_FILE variable. However in practice in one test I did, it worked just f...
注意:必须先include(CheckCXXCompilerFlag) 例子1:在检查当前编译器是否支持c++11 CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11) CHECK_CXX_COMPILER_FLAG("-std=c++0x"COMPILER_SUPPORTS_CXX0X) if(COMPILER_SUPPORTS_CXX11) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std...
For details see:https://corecheck.dev/bitcoin/bitcoin/pulls/31366. Reviews Seethe guidelinefor information on the review process. Type If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update....