zmk/CMakeLists.txt
Pete Johanson f478438f01 Implement raise/lower for default keymap.
* Properly allow includes for keymaps to allow defining
  custom keycodes, and then adding them to the
  keymap.overlay file.
* Fix keymap.c loading after build refactor.
* Fix for deactivating a layer working properly.
* Fix default keymap to put transparent in proper spots to
  make raise/lower keycodes work as expected.
* Add custom raise/lower keycode handling to default
  keymap.
2020-05-18 13:42:41 -04:00

31 lines
953 B
CMake

# Find Zephyr. This also loads Zephyr's build system.
cmake_minimum_required(VERSION 3.13.1)
list(APPEND BOARD_ROOT ${CMAKE_SOURCE_DIR})
list(APPEND DTS_ROOT ${CMAKE_SOURCE_DIR})
include(cmake/keymap.cmake)
find_package(Zephyr)
project(zmk)
if(EXISTS ${KEYMAP_DIR}/keymap.c)
message(STATUS "ADDING THE KEYMAP SOURCE")
target_sources(app PRIVATE ${KEYMAP_DIR}/keymap.c)
endif()
# Add your source file to the "app" target. This must come after
# find_package(Zephyr) which defines the target.
target_include_directories(app PRIVATE include)
target_sources(app PRIVATE src/kscan.c)
target_sources(app PRIVATE src/keymap.c)
target_sources(app PRIVATE src/hid.c)
target_sources_ifdef(CONFIG_ZMK_BLE app PRIVATE src/ble.c)
target_sources(app PRIVATE src/usb_hid.c)
target_sources_ifdef(CONFIG_ZMK_BLE app PRIVATE src/hog.c)
target_sources(app PRIVATE src/endpoints.c)
target_sources(app PRIVATE src/main.c)
target_sources(app PRIVATE src/handlers.c)