Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions cmake/pch.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ set(COMMON_PCH_SET
<chrono>
<memory>
<vector>
<pthread.h>
<qdebug.h>
<qobject.h>
<qmetatype.h>
Expand All @@ -53,13 +54,20 @@ set(COMMON_PCH_SET
<qabstractitemmodel.h>
)

set(THREADS_PREFER_PTHREAD_FLAG ON)
find_package(Threads REQUIRED)

qs_add_pchset(common
DEPENDENCIES Qt::Quick
DEPENDENCIES
Qt::Quick
Threads::Threads
HEADERS ${COMMON_PCH_SET}
)

qs_add_pchset(large
DEPENDENCIES Qt::Quick
DEPENDENCIES
Qt::Quick
Threads::Threads
HEADERS
${COMMON_PCH_SET}
<qiodevice.h>
Expand All @@ -77,7 +85,9 @@ qs_add_pchset(large

# including qplugin.h directly will cause required symbols to disappear
qs_add_pchset(plugin
DEPENDENCIES Qt::Qml
DEPENDENCIES
Qt::Qml
Threads::Threads
HEADERS
<qobject.h>
<qjsonobject.h>
Expand Down
5 changes: 4 additions & 1 deletion src/services/polkit/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
set(THREADS_PREFER_PTHREAD_FLAG ON)
find_package(PkgConfig REQUIRED)
find_package(Threads REQUIRED)
pkg_check_modules(glib REQUIRED IMPORTED_TARGET glib-2.0>=2.36)
pkg_check_modules(gobject REQUIRED IMPORTED_TARGET gobject-2.0)
pkg_check_modules(polkit_agent REQUIRED IMPORTED_TARGET polkit-agent-1)
Expand Down Expand Up @@ -28,8 +30,9 @@ target_link_libraries(quickshell-service-polkit PRIVATE
PkgConfig::gobject
PkgConfig::polkit_agent
PkgConfig::polkit
Threads::Threads
)

qs_module_pch(quickshell-service-polkit)

target_link_libraries(quickshell PRIVATE quickshell-service-polkitplugin)
target_link_libraries(quickshell PRIVATE quickshell-service-polkitplugin Threads::Threads)