cmake:Parameters to $ must resolve to either '0' or '1'.
如下是一段简单的cmake脚本,用于设置target的编译选项:当编译器为msvc,且CMAKE_BUILD_TYPE为Release时,为target添加-arch:AVX2编译选项,当编译器为gcc,且CMAKE_BUILD_TYPE为Release时,为target添加-mavx2编译选项。这里用到了$表达式(cmake-generator-expressions)target_compil