我有
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -m64 -march=native -flto")
但我想删除-flto
特定目标编译:
file(GLOB TST_SOURCES "${CMAKE_SOURCE_DIR}/x64_test/*.cpp")
add_executable(_x64_test ${TST_SOURCES})
target_compile_options(_x64_test PRIVATE -Wall -DLITTLE_ENDIAN)
target_link_libraries(_x64_test PRIVATE test_iface pthread m)
可能吗?