Fetch nlohmann_json for prebuilt TDLib builds
All checks were successful
Release App / release-app (push) Successful in 56s
All checks were successful
Release App / release-app (push) Successful in 56s
This commit is contained in:
@@ -17,6 +17,17 @@ set(TELEGRAM_TUI_TDLIB_ROOT ""
|
||||
set(CURSES_NEED_WIDE TRUE)
|
||||
find_package(Curses REQUIRED)
|
||||
|
||||
find_package(nlohmann_json QUIET)
|
||||
if(NOT nlohmann_json_FOUND)
|
||||
FetchContent_Declare(
|
||||
nlohmann_json
|
||||
GIT_REPOSITORY https://github.com/nlohmann/json.git
|
||||
GIT_TAG v3.11.3
|
||||
GIT_SHALLOW TRUE
|
||||
)
|
||||
FetchContent_MakeAvailable(nlohmann_json)
|
||||
endif()
|
||||
|
||||
set(TELEGRAM_TUI_APP_CONFIG_PATH "")
|
||||
if(DEFINED ENV{XDG_DATA_HOME} AND NOT "$ENV{XDG_DATA_HOME}" STREQUAL "")
|
||||
set(TELEGRAM_TUI_APP_CONFIG_PATH "$ENV{XDG_DATA_HOME}/telegram-tui/config.json")
|
||||
@@ -119,7 +130,7 @@ if(CLANG_FORMAT_BIN)
|
||||
endif()
|
||||
|
||||
target_include_directories(shinoa PRIVATE ${CURSES_INCLUDE_DIRS} ${CMAKE_CURRENT_BINARY_DIR})
|
||||
target_link_libraries(shinoa PRIVATE ${CURSES_LIBRARIES})
|
||||
target_link_libraries(shinoa PRIVATE ${CURSES_LIBRARIES} nlohmann_json::nlohmann_json)
|
||||
|
||||
if(TELEGRAM_TUI_USE_SYSTEM_TDLIB)
|
||||
target_link_libraries(shinoa PRIVATE Td::TdJson)
|
||||
|
||||
Reference in New Issue
Block a user