2013-03-12 02:49:17 +05:30
|
|
|
project(libGroupView)
|
|
|
|
|
|
|
|
set(CMAKE_AUTOMOC ON)
|
|
|
|
|
|
|
|
# Find Qt
|
|
|
|
find_package(Qt5Core REQUIRED)
|
2013-03-14 00:12:41 +05:30
|
|
|
find_package(Qt5Widgets REQUIRED)
|
2013-03-12 02:49:17 +05:30
|
|
|
|
|
|
|
# Include Qt headers.
|
|
|
|
include_directories(${Qt5Base_INCLUDE_DIRS})
|
|
|
|
|
|
|
|
SET(LIBGROUPVIEW_HEADERS
|
2013-08-17 17:10:51 +05:30
|
|
|
include/groupview_config.h
|
2013-03-12 02:49:17 +05:30
|
|
|
|
|
|
|
# Public headers
|
2013-08-04 15:51:51 +05:30
|
|
|
include/categorizedsortfilterproxymodel.h
|
|
|
|
include/categorizedview.h
|
|
|
|
include/categorydrawer.h
|
2013-03-12 02:49:17 +05:30
|
|
|
|
|
|
|
# Private headers
|
2013-08-04 15:51:51 +05:30
|
|
|
src/categorizedsortfilterproxymodel_p.h
|
|
|
|
src/categorizedview_p.h
|
2013-03-12 02:49:17 +05:30
|
|
|
)
|
|
|
|
|
|
|
|
SET(LIBGROUPVIEW_SOURCES
|
2013-08-04 15:51:51 +05:30
|
|
|
src/categorizedsortfilterproxymodel.cpp
|
|
|
|
src/categorizedview.cpp
|
|
|
|
src/categorydrawer.cpp
|
2013-03-12 02:49:17 +05:30
|
|
|
)
|
|
|
|
|
|
|
|
# Set the include dir path.
|
|
|
|
SET(LIBGROUPVIEW_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include" PARENT_SCOPE)
|
|
|
|
|
|
|
|
# Include self.
|
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include)
|
|
|
|
include_directories(${CMAKE_BINARY_DIR}/include)
|
|
|
|
|
2013-08-26 06:23:29 +05:30
|
|
|
# Static link!
|
|
|
|
ADD_DEFINITIONS(-DLIBGROUPVIEW_STATIC)
|
|
|
|
|
2013-03-12 02:49:17 +05:30
|
|
|
add_definitions(-DLIBGROUPVIEW_LIBRARY)
|
|
|
|
|
2013-08-26 06:23:29 +05:30
|
|
|
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
|
|
|
|
2013-08-26 02:18:41 +05:30
|
|
|
add_library(libGroupView STATIC ${LIBGROUPVIEW_SOURCES} ${LIBGROUPVIEW_HEADERS})
|
2013-03-14 00:12:41 +05:30
|
|
|
qt5_use_modules(libGroupView Core Widgets)
|