2020-04-22 06:20:34 +10:00
|
|
|
# Find Zephyr. This also loads Zephyr's build system.
|
|
|
|
cmake_minimum_required(VERSION 3.13.1)
|
2020-04-26 12:41:20 +10:00
|
|
|
|
2020-05-02 04:58:00 +10:00
|
|
|
list(APPEND BOARD_ROOT ${CMAKE_SOURCE_DIR})
|
2020-05-06 06:09:05 +10:00
|
|
|
list(APPEND DTS_ROOT ${CMAKE_SOURCE_DIR})
|
2020-04-22 06:20:34 +10:00
|
|
|
|
2020-05-17 07:30:30 +10:00
|
|
|
include(cmake/keymap.cmake)
|
|
|
|
|
2020-04-26 12:41:20 +10:00
|
|
|
find_package(Zephyr)
|
2020-04-22 06:20:34 +10:00
|
|
|
project(zmk)
|
|
|
|
|
2020-05-19 03:42:41 +10:00
|
|
|
if(EXISTS ${KEYMAP_DIR}/keymap.c)
|
2020-05-18 23:11:46 +10:00
|
|
|
message(STATUS "ADDING THE KEYMAP SOURCE")
|
2020-05-19 03:42:41 +10:00
|
|
|
target_sources(app PRIVATE ${KEYMAP_DIR}/keymap.c)
|
2020-05-18 23:11:46 +10:00
|
|
|
endif()
|
|
|
|
|
|
|
|
|
2020-04-22 06:20:34 +10:00
|
|
|
# Add your source file to the "app" target. This must come after
|
|
|
|
# find_package(Zephyr) which defines the target.
|
2020-05-11 07:13:24 +10:00
|
|
|
target_include_directories(app PRIVATE include)
|
2020-05-02 09:14:18 +10:00
|
|
|
target_sources(app PRIVATE src/kscan.c)
|
2020-05-04 05:49:33 +10:00
|
|
|
target_sources(app PRIVATE src/keymap.c)
|
2020-05-15 23:41:06 +10:00
|
|
|
target_sources(app PRIVATE src/hid.c)
|
2020-05-18 23:11:46 +10:00
|
|
|
target_sources_ifdef(CONFIG_ZMK_BLE app PRIVATE src/ble.c)
|
2020-05-25 08:22:16 +10:00
|
|
|
target_sources_ifdef(CONFIG_ZMK_KSCAN_MOCK_DRIVER app PRIVATE src/kscan_mock.c)
|
2020-05-06 06:09:05 +10:00
|
|
|
target_sources(app PRIVATE src/usb_hid.c)
|
2020-05-18 23:11:46 +10:00
|
|
|
target_sources_ifdef(CONFIG_ZMK_BLE app PRIVATE src/hog.c)
|
2020-05-13 04:15:33 +10:00
|
|
|
target_sources(app PRIVATE src/endpoints.c)
|
2020-04-22 06:20:34 +10:00
|
|
|
target_sources(app PRIVATE src/main.c)
|
2020-05-11 07:13:24 +10:00
|
|
|
target_sources(app PRIVATE src/handlers.c)
|
2020-04-22 06:20:34 +10:00
|
|
|
|