Also use new Zephyr CI environment and compile all boards. Board migration script example: python ../zephyr/scripts/utils/board_v1_to_v2.py --board-root . \ -v libresolar -g libresolar -b pwm_2420_lus -s stm32l072xx
22 lines
641 B
CMake
22 lines
641 B
CMake
# Copyright (c) The Libre Solar Project Contributors
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
cmake_minimum_required(VERSION 3.13.1)
|
|
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
|
|
|
|
project(libre_solar_charge_controller)
|
|
|
|
add_subdirectory(src)
|
|
|
|
# determine git tag and commit hash for automatic firmware versioning
|
|
find_package(Git)
|
|
if(GIT_FOUND)
|
|
execute_process(
|
|
COMMAND ${GIT_EXECUTABLE} describe --long --dirty --tags
|
|
OUTPUT_VARIABLE FIRMWARE_VERSION_ID
|
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
|
else()
|
|
set(FIRMWARE_VERSION_ID "unknown")
|
|
endif()
|
|
add_definitions(-DFIRMWARE_VERSION_ID="${FIRMWARE_VERSION_ID}")
|