diff --git a/cmake/TelinkSDK.cmake b/cmake/TelinkSDK.cmake index 48cbbf1..15f0e59 100644 --- a/cmake/TelinkSDK.cmake +++ b/cmake/TelinkSDK.cmake @@ -17,6 +17,11 @@ SET(TOOLCHAIN_BIN_DIR ${TOOLCHAIN_PREFIX}/bin) SET(TOOLCHAIN_INC_DIR ${TOOLCHAIN_PREFIX}/include) SET(TOOLCHAIN_LIB_DIR ${TOOLCHAIN_PREFIX}/lib) +IF(WIN32) + SET(TOOL_EXECUTABLE_SUFFIX ".exe") + SET(CMAKE_C_COMPILER_WORKS 1) +ENDIF() + IF(NOT CMAKE_C_COMPILER) SET(CMAKE_C_COMPILER ${TOOLCHAIN_BIN_DIR}/${TARGET_PREFIX}gcc${TOOL_EXECUTABLE_SUFFIX}) ENDIF()