1+ include (${CMAKE_CURRENT_LIST_DIR} /Platform/Other/FindArduinoSDK.cmake)
2+
13function (_find_required_programs)
24
35 # Find ASM compiler
@@ -27,17 +29,19 @@ function(_find_required_programs)
2729
2830endfunction ()
2931
30- function (_setup_remaining_sdk_paths )
32+ function (_setup_sdk_internal_paths )
3133
34+ set (ARDUINO_SDK_BIN_PATH "${ARDUINO_SDK_PATH} /hardware/tools/avr/bin" CACHE PATH
35+ "Path to Arduino SDK's binaries folder" )
36+ set (ARDUINO_SDK_ROOT_PATH "${ARDUINO_SDK_PATH} /hardware/tools/avr" CACHE PATH
37+ "Path to Arduino SDK's sys-root folder" )
3238 set (ARDUINO_SDK_LIBRARIES_PATH "${ARDUINO_SDK_PATH} /libraries" CACHE PATH
3339 "Path to SDK's libraries directory" )
3440 set (ARDUINO_SDK_EXAMPLES_PATH "${ARDUINO_SDK_PATH} /examples" CACHE PATH
3541 "Path to SDK's examples directory" )
3642
3743endfunction ()
3844
39- include (${CMAKE_CURRENT_LIST_DIR} /Platform/Other/FindArduinoSDK.cmake)
40-
4145set (CMAKE_SYSTEM_NAME Arduino)
4246
4347# Add current directory to CMake Module path automatically
@@ -54,12 +58,7 @@ if (NOT ARDUINO_SDK_PATH)
5458 set (ARDUINO_SDK_PATH "${arduino_sdk_path} " CACHE PATH "Arduino SDK Path" )
5559endif ()
5660
57- set (ARDUINO_SDK_BIN_PATH "${ARDUINO_SDK_PATH} /hardware/tools/avr/bin" CACHE PATH
58- "Path to Arduino SDK's binaries folder" )
59- set (ARDUINO_SDK_ROOT_PATH "${ARDUINO_SDK_PATH} /hardware/tools/avr" CACHE PATH
60- "Path to Arduino SDK's sys-root folder" )
61-
62- _setup_remaining_sdk_paths()
61+ _setup_sdk_internal_paths()
6362_find_required_programs()
6463
6564# where is the target environment
0 commit comments