2015-06-11 12:10:07 +02:00
|
|
|
cmake_minimum_required(VERSION 2.8.11)
|
2018-11-29 22:26:51 +01:00
|
|
|
set(CMAKE_CXX_STANDARD 11)
|
2010-02-28 18:28:56 +01:00
|
|
|
|
|
|
|
set(QXT-SOURCES
|
|
|
|
qxtglobal.cpp
|
|
|
|
qxtglobalshortcut.cpp
|
|
|
|
)
|
|
|
|
|
|
|
|
set(QXT-MOC-HEADERS
|
|
|
|
qxtglobalshortcut.h
|
|
|
|
)
|
|
|
|
|
2011-11-29 12:27:35 +01:00
|
|
|
include_directories(${X11_INCLUDE_DIR})
|
2015-04-11 22:45:27 +02:00
|
|
|
include_directories(${Qt5Gui_PRIVATE_INCLUDE_DIRS})
|
2011-11-29 12:27:35 +01:00
|
|
|
|
2010-02-28 18:28:56 +01:00
|
|
|
if(WIN32)
|
|
|
|
set(QXT-SOURCES ${QXT-SOURCES} qxtglobalshortcut_win.cpp)
|
|
|
|
elseif(APPLE)
|
|
|
|
set(QXT-SOURCES ${QXT-SOURCES} qxtglobalshortcut_mac.cpp)
|
|
|
|
else(WIN32)
|
|
|
|
set(QXT-SOURCES ${QXT-SOURCES} qxtglobalshortcut_x11.cpp)
|
|
|
|
endif(WIN32)
|
|
|
|
|
2015-04-11 22:45:27 +02:00
|
|
|
QT5_WRAP_CPP(QXT-SOURCES-MOC ${QXT-MOC-HEADERS})
|
2010-02-28 18:28:56 +01:00
|
|
|
|
2010-06-22 18:07:29 +02:00
|
|
|
ADD_LIBRARY(qxt STATIC
|
2010-02-28 18:28:56 +01:00
|
|
|
${QXT-SOURCES}
|
|
|
|
${QXT-SOURCES-MOC}
|
|
|
|
)
|
2015-04-11 22:45:27 +02:00
|
|
|
|
2017-01-09 15:19:54 +01:00
|
|
|
if(WIN32)
|
2018-04-16 01:05:32 +02:00
|
|
|
target_link_libraries(qxt Qt5::Core Qt5::Widgets)
|
2017-01-09 15:19:54 +01:00
|
|
|
else(WIN32)
|
2018-04-16 01:05:32 +02:00
|
|
|
target_link_libraries(qxt Qt5::Core Qt5::Widgets Qt5::X11Extras)
|
2017-01-09 15:19:54 +01:00
|
|
|
endif(WIN32)
|