chore: don't include sparkle when not enabled

Signed-off-by: seth <getchoo@tuta.io>
This commit is contained in:
seth 2023-07-27 00:59:01 -04:00
parent a8498b0dab
commit 51bfda937d
No known key found for this signature in database
GPG Key ID: D31BD0D494BBEE86
2 changed files with 3 additions and 2 deletions

View File

@ -131,7 +131,7 @@
#include "MangoHud.h"
#endif
#ifdef Q_OS_MAC
#if defined(Q_OS_MAC) && defined(SPARKLE_ENABLED)
#include "updater/MacSparkleUpdater.h"
#endif
@ -776,7 +776,7 @@ Application::Application(int &argc, char **argv) : QApplication(argc, argv)
if(BuildConfig.UPDATER_ENABLED)
{
qDebug() << "Initializing updater";
#ifdef Q_OS_MAC
#if defined(Q_OS_MAC) && defined(SPARKLE_ENABLED)
m_updater.reset(new MacSparkleUpdater());
#endif
qDebug() << "<> Updater started.";

View File

@ -1146,6 +1146,7 @@ if(APPLE)
file(ARCHIVE_EXTRACT INPUT ${CMAKE_BINARY_DIR}/Sparkle.tar.xz DESTINATION ${CMAKE_BINARY_DIR}/frameworks/Sparkle)
find_library(SPARKLE_FRAMEWORK Sparkle "${CMAKE_BINARY_DIR}/frameworks/Sparkle")
add_compile_definitions(SPARKLE_ENABLED)
endif()
target_link_libraries(Launcher_logic