From bac18750e3cd7dad184426ff69489fd0463f5277 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maximilian=20R=C3=B6hrle?= <4374065+edgale@users.noreply.github.com> Date: Mon, 16 May 2022 08:42:43 +0200 Subject: [PATCH] fix: added swagger paths to cmake --- CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5bf7136..d7a8cd8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -60,6 +60,13 @@ add_definitions( -DDATABASE_MIGRATIONS="${CMAKE_CURRENT_SOURCE_DIR}/sql" ) +set(SWAGGER_ROOT_PATH "/swagger" CACHE STRING "Default root path to the Swagger") +set(SWAGGER_UI_PATH "/ui" CACHE STRING "Default path suffix to the Swagger UI") +add_compile_definitions( + SWAGGER_ROOT_PATH="${SWAGGER_ROOT_PATH}" + SWAGGER_UI_PATH="${SWAGGER_UI_PATH}" +) + if(CMAKE_SYSTEM_NAME MATCHES Linux) find_package(Threads REQUIRED) target_link_libraries(crud-lib INTERFACE Threads::Threads ${CMAKE_DL_LIBS})