Skip to content

Commit 0089c49

Browse files
authored
Merge pull request #244 from hugueskamba/hk_cmake_rename_targets
CMake: Perform toolchain and language setup
2 parents a759039 + c8ff707 commit 0089c49

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

CMakeLists.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ set(MBED_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/mbed-os CACHE INTERNAL "")
88
set(MBED_CONFIG_PATH ${CMAKE_CURRENT_SOURCE_DIR}/.mbedbuild CACHE INTERNAL "")
99
set(APP_TARGET mbed-os-example-blinky)
1010

11+
include(${MBED_ROOT}/tools/cmake/app.cmake)
12+
1113
add_subdirectory(${MBED_ROOT})
1214

1315
add_executable(${APP_TARGET})
@@ -23,7 +25,10 @@ target_sources(${APP_TARGET}
2325
main.cpp
2426
)
2527

26-
target_link_libraries(${APP_TARGET} mbed-os)
28+
target_link_libraries(${APP_TARGET}
29+
PRIVATE
30+
mbed-os
31+
)
2732

2833
mbed_generate_bin_hex(${APP_TARGET})
2934

0 commit comments

Comments
 (0)