Files
Liu 464eed1402 build: centralize package versions and standardize on C11
versions.json is now the single source of truth; scripts/sync-versions.mjs keeps xmake descriptors, tracked version headers and package.json in sync. Sub-library versions are aligned with the published 1.0.0 packages. C11 is set at the project level, and _GNU_SOURCE is defined on POSIX so strict C11 still exposes clock_gettime, strdup and recursive pthread mutexes.
2026-11-19 22:03:59 +08:00

24 lines
685 B
Lua

target("librouter")
set_version("1.0.0")
set_kind("$(kind)")
add_files("src/*.c")
add_deps("yutil")
set_configdir("include/router")
add_configfiles("src/version.h.in")
add_headerfiles("include/router.h", "include/(router/*.h)")
if is_kind("static") then
set_configvar("LIBROUTER_STATIC_BUILD", 1)
elseif is_plat("windows") then
add_defines("LIBROUTER_DLL_EXPORT")
end
target("librouter-tests")
set_default(false)
set_kind("binary")
set_group("tests")
set_rundir("tests")
add_files("tests/test.c")
add_deps("ctest", "librouter")
add_rules("tests.runnable")
add_tests("default", {group = "tests"})