From b4694d637bb37158e601b99a9d0d815654e32f1f Mon Sep 17 00:00:00 2001 From: AdenKoperczak Date: Thu, 17 Apr 2025 10:51:27 -0400 Subject: [PATCH] Ensure atomic is only linked for non-windows OS's --- scwx-qt/scwx-qt.cmake | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scwx-qt/scwx-qt.cmake b/scwx-qt/scwx-qt.cmake index 86606d9e..674bc661 100644 --- a/scwx-qt/scwx-qt.cmake +++ b/scwx-qt/scwx-qt.cmake @@ -686,13 +686,17 @@ else() target_compile_options(supercell-wx PRIVATE "$<$:-g>") endif() +# link atomic only for Linux +if (!MSVC) + target_link_libraries(scwx-qt PUBLIC atomic) +endif() + target_link_libraries(scwx-qt PUBLIC Qt${QT_VERSION_MAJOR}::Widgets Qt${QT_VERSION_MAJOR}::OpenGLWidgets Qt${QT_VERSION_MAJOR}::Multimedia Qt${QT_VERSION_MAJOR}::Positioning Qt${QT_VERSION_MAJOR}::SerialPort Qt${QT_VERSION_MAJOR}::Svg - atomic Boost::json Boost::timer QMapLibre::Core