Skip to content

Commit

Permalink
Fix CMakeLists.txt for Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
Abestanis committed Oct 8, 2024
1 parent 428a28e commit 12561dd
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,8 @@ if(WIN32)
src/processhandle.cpp)
set(PLATFORM_EXE_SOURCES src/res/birdtray.rc)
set(PLATFORM_HEADERS src/windowtools_win.h src/birdtrayeventfilter.h src/processhandle.h)
find_package(Qt5WinExtras CONFIG REQUIRED)
list(APPEND REQUIRED_MODULES Qt6::WinExtras)
else()
find_library(X11 X11)
list(APPEND REQUIRED_MODULES X11)
set(PLATFORM_SOURCES src/windowtools_x11.cpp)
set(PLATFORM_HEADERS src/windowtools_x11.h)
endif(WIN32)
Expand Down Expand Up @@ -173,7 +171,7 @@ target_link_libraries(birdtray_lib PUBLIC ${REQUIRED_MODULES})
add_executable(birdtray
${EXECUTABLE_OPTIONS} src/main.cpp ${PLATFORM_EXE_SOURCES} ${RESOURCES_SOURCES}
${HEADERS} ${PLATFORM_HEADERS})
target_link_libraries(birdtray birdtray_lib X11)
target_link_libraries(birdtray birdtray_lib)

if(MSVC)
target_compile_options(birdtray_lib PUBLIC /utf-8)
Expand Down

0 comments on commit 12561dd

Please sign in to comment.