blob: c121551a1cea6d98d307ea14cc92ed0ab04c6bc0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
# MAX25-Stack-Lite platform defaults.
#
# Lite ship policy (settled): BayCom/based (stacks/max25-bcpr) is in-scope and
# default ON on every POSIX-like Lite target — see product-repo-rules.md
# "CMake ship profile (Lite)" and design-principles.md. This module must not
# reintroduce the upstream MAX25-Stack default (bcpr opt-in/OFF) here, because
# CMake's option() in the top-level CMakeLists.txt cannot override a CACHE
# variable already created by an earlier include() — this module runs first.
set(MAX25_SYSTEM "${CMAKE_SYSTEM_NAME}")
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
set(MAX25_PLATFORM "linux")
set(MAX25_DEFAULT_BUILD_TNCS ON)
set(MAX25_DEFAULT_BUILD_MAX25_BCPR ON)
elseif(CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
set(MAX25_PLATFORM "freebsd")
set(MAX25_DEFAULT_BUILD_TNCS OFF)
set(MAX25_DEFAULT_BUILD_MAX25_BCPR ON)
elseif(CMAKE_SYSTEM_NAME MATCHES "OpenBSD|NetBSD|DragonFly")
set(MAX25_PLATFORM "bsd")
set(MAX25_DEFAULT_BUILD_TNCS OFF)
set(MAX25_DEFAULT_BUILD_MAX25_BCPR ON)
else()
set(MAX25_PLATFORM "generic")
set(MAX25_DEFAULT_BUILD_TNCS OFF)
set(MAX25_DEFAULT_BUILD_MAX25_BCPR OFF)
endif()
if(NOT DEFINED MAX25_BUILD_TNCS)
set(MAX25_BUILD_TNCS ${MAX25_DEFAULT_BUILD_TNCS} CACHE BOOL "Build stacks/tncs tools (not shipped in Lite; no-op)")
endif()
if(NOT DEFINED MAX25_BUILD_MAX25_BCPR)
set(MAX25_BUILD_MAX25_BCPR ${MAX25_DEFAULT_BUILD_MAX25_BCPR} CACHE BOOL "Build stacks/max25-bcpr BayCom/based SER12 (Lite: in-scope, default ON)")
endif()
message(STATUS "MAX25 platform=${MAX25_PLATFORM} system=${MAX25_SYSTEM}")
|