From b21ed0063b7e9486f52ced242737441459cfd32f Mon Sep 17 00:00:00 2001 From: NotTsunami <4589807+NotTsunami@users.noreply.github.com> Date: Sat, 18 Jan 2020 09:41:56 -0500 Subject: [PATCH] CMake: Fix WebUI checks When the CMake system was last revamped, the configure variable was changed from WEBUI to DISABLE_WEBUI, but we are still checking against WEBUI. This behavior was changed in https://github.com/qbittorrent/qBittorrent/commit/fa770871e98752465d4371fe6dea20f72d83c736 --- src/CMakeLists.txt | 4 ++-- src/app/CMakeLists.txt | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 1a9975a99..7aa76955c 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -75,6 +75,6 @@ if (Qt5Widgets_FOUND) add_subdirectory(gui) endif () -if (WEBUI) +if (NOT DISABLE_WEBUI) add_subdirectory(webui) -endif (WEBUI) +endif() diff --git a/src/app/CMakeLists.txt b/src/app/CMakeLists.txt index 84f703e99..2f79bd1dc 100644 --- a/src/app/CMakeLists.txt +++ b/src/app/CMakeLists.txt @@ -36,7 +36,7 @@ include(QbtTranslations) file(GLOB QBT_TS_FILES ../lang/*.ts) qbt_add_translations(qBittorrent QRC_FILE "../lang/lang.qrc" TS_FILES ${QBT_TS_FILES}) -if (WEBUI) +if (NOT DISABLE_WEBUI) file(GLOB QBT_WEBUI_TS_FILES ../webui/www/translations/*.ts) qbt_add_translations(qBittorrent QRC_FILE "../webui/www/translations/webui_translations.qrc" TS_FILES ${QBT_WEBUI_TS_FILES}) endif() @@ -97,9 +97,9 @@ else(Qt5Widgets_FOUND) ) endif (Qt5Widgets_FOUND) -if (WEBUI) +if (NOT DISABLE_WEBUI) target_link_libraries(qBittorrent PRIVATE qbt_webui) -endif (WEBUI) +endif() # we have to include resources into the bundle if (APPLE)