2008-09-24 20:32:01 +01:00
|
|
|
# Copyright (C) 2008 by Volker Lanz <vl@fidra.de>
|
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or modify
|
|
|
|
# it under the terms of the GNU General Public License as published by
|
|
|
|
# the Free Software Foundation; either version 2 of the License, or
|
|
|
|
# at your option) any later version.
|
|
|
|
#
|
|
|
|
# This program is distributed in the hope that it will be useful,
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
# GNU General Public License for more details.
|
|
|
|
#
|
|
|
|
# You should have received a copy of the GNU General Public License
|
|
|
|
# along with this program; if not, write to the
|
|
|
|
# Free Software Foundation, Inc.,
|
|
|
|
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
|
|
|
2008-12-27 22:12:42 +00:00
|
|
|
############################################
|
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
file(GLOB partitionmanagerprivate_SRCS
|
2008-09-24 20:32:01 +01:00
|
|
|
core/*.cpp
|
|
|
|
util/*.cpp
|
|
|
|
ops/*.cpp
|
|
|
|
jobs/*.cpp
|
|
|
|
fs/*.cpp
|
2008-12-27 22:12:42 +00:00
|
|
|
gui/*.cpp
|
2008-09-24 20:32:01 +01:00
|
|
|
)
|
|
|
|
|
2010-01-27 00:28:43 +00:00
|
|
|
qt4_add_dbus_adaptor(partitionmanagerprivate_SRCS org.kde.PartitionManager.xml gui/partitionmanagerwidget.h PartitionManagerWidget)
|
|
|
|
|
2009-04-21 17:36:43 +01:00
|
|
|
file(GLOB partitionmanagerprivate_UIFILES gui/*.ui kcm/*.ui)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
kde4_add_ui_files(partitionmanagerprivate_SRCS ${partitionmanagerprivate_UIFILES})
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
kde4_add_kcfg_files(partitionmanagerprivate_SRCS config.kcfgc)
|
2008-09-24 20:32:01 +01:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
kde4_add_library(partitionmanagerprivate SHARED ${partitionmanagerprivate_SRCS})
|
2008-09-24 20:32:01 +01:00
|
|
|
|
2010-01-26 11:35:23 +00:00
|
|
|
target_link_libraries(partitionmanagerprivate libfatlabel ${KDE4_KDECORE_LIBS} ${KDE4_KFILE_LIBS} ${KDE4_KIO_LIBS} ${LIBPARTED_LIBS} ${UUID_LIBRARIES} ${BLKID_LIBRARIES} ${KDE4_KDEUI_LIBS} ${KDE4_SOLID_LIBS})
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-02-16 22:02:13 +00:00
|
|
|
install(TARGETS partitionmanagerprivate ${INSTALL_TARGETS_DEFAULT_ARGS})
|
2010-01-27 10:27:37 +00:00
|
|
|
# install(FILES org.kde.PartitionManager.xml DESTINATION ${DBUS_INTERFACES_INSTALL_DIR})
|
2008-12-27 22:12:42 +00:00
|
|
|
|
|
|
|
############################################
|
|
|
|
|
2009-03-25 17:05:32 +00:00
|
|
|
file(GLOB partitionmanager-bin_SRCS main.cpp)
|
2008-09-24 20:32:01 +01:00
|
|
|
|
2009-03-25 17:05:32 +00:00
|
|
|
kde4_add_app_icon(partitionmanager-bin_SRCS "${CMAKE_CURRENT_SOURCE_DIR}/../icons/hi*-apps-partitionmanager.png")
|
2009-03-25 12:11:10 +00:00
|
|
|
|
2009-03-25 17:05:32 +00:00
|
|
|
kde4_add_executable(partitionmanager-bin ${partitionmanager-bin_SRCS})
|
2008-09-24 20:32:01 +01:00
|
|
|
|
2009-11-14 21:08:26 +00:00
|
|
|
target_link_libraries(partitionmanager-bin partitionmanagerprivate ${KDE4_KDEUI_LIBS})
|
2008-09-24 20:32:01 +01:00
|
|
|
|
2009-03-25 17:05:32 +00:00
|
|
|
if(UNIX)
|
2009-04-29 13:46:38 +01:00
|
|
|
add_custom_target(partitionmanager ALL
|
|
|
|
COMMAND sed -e 's,@INSTALL_PATH@,${BIN_INSTALL_DIR},g' < ${CMAKE_CURRENT_SOURCE_DIR}/partitionmanager.in > ${CMAKE_CURRENT_BINARY_DIR}/partitionmanager
|
|
|
|
)
|
2009-03-25 17:05:32 +00:00
|
|
|
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/partitionmanager DESTINATION ${BIN_INSTALL_DIR})
|
|
|
|
endif(UNIX)
|
|
|
|
install(TARGETS partitionmanager-bin ${INSTALL_TARGETS_DEFAULT_ARGS})
|
2009-01-09 10:11:36 +00:00
|
|
|
install(FILES gui/partitionmanagerui.rc DESTINATION ${DATA_INSTALL_DIR}/partitionmanager)
|
|
|
|
install(FILES partitionmanager.desktop DESTINATION ${XDG_APPS_INSTALL_DIR})
|
2008-09-24 20:32:01 +01:00
|
|
|
|
2008-12-27 22:12:42 +00:00
|
|
|
############################################
|
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
option(PARTMAN_KPART "Build a kpart for KDE Partition Manager" OFF)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
if(PARTMAN_KPART)
|
|
|
|
file(GLOB partitionmanagerpart_SRCS kpart/partitionmanagerpart.cpp)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
kde4_add_plugin(partitionmanagerpart ${partitionmanagerpart_SRCS})
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
target_link_libraries(partitionmanagerpart
|
2008-12-27 22:12:42 +00:00
|
|
|
${KDE4_KPARTS_LIBS}
|
|
|
|
${KDE4_KDECORE_LIBS}
|
|
|
|
partitionmanagerprivate
|
|
|
|
)
|
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
install(TARGETS partitionmanagerpart DESTINATION ${PLUGIN_INSTALL_DIR})
|
|
|
|
install(FILES kpart/partitionmanagerpart.desktop DESTINATION ${SERVICES_INSTALL_DIR})
|
|
|
|
install(FILES kpart/partitionmanagerpart.rc DESTINATION ${DATA_INSTALL_DIR}/partitionmanagerpart)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
option(PARTMAN_KPART_TEST "Build a kpart test application for KDE Partition Manager" OFF)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
if(PARTMAN_KPART_TEST)
|
|
|
|
add_subdirectory(kpart/test)
|
|
|
|
endif(PARTMAN_KPART_TEST)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-01-09 10:11:36 +00:00
|
|
|
endif(PARTMAN_KPART)
|
2008-12-27 22:12:42 +00:00
|
|
|
|
2009-04-21 17:36:43 +01:00
|
|
|
############################################
|
|
|
|
|
2009-08-21 13:10:25 +01:00
|
|
|
option(PARTMAN_KCM "Build a kcm for KDE Partition Manager" OFF)
|
2009-04-21 17:36:43 +01:00
|
|
|
|
|
|
|
if(PARTMAN_KCM)
|
|
|
|
file(GLOB partitionmanagerkcm_SRCS kcm/partitionmanagerkcm.cpp)
|
|
|
|
|
|
|
|
kde4_add_plugin(kcm_partitionmanager ${partitionmanagerkcm_SRCS})
|
|
|
|
|
|
|
|
target_link_libraries(kcm_partitionmanager
|
2009-04-23 17:42:53 +01:00
|
|
|
${KDE4_KUTILS_LIBS}
|
2009-04-21 17:36:43 +01:00
|
|
|
${KDE4_KDEUI_LIBS}
|
|
|
|
partitionmanagerprivate
|
|
|
|
)
|
|
|
|
|
|
|
|
install(TARGETS kcm_partitionmanager DESTINATION ${PLUGIN_INSTALL_DIR})
|
|
|
|
install(FILES kcm/kcm_partitionmanager.desktop DESTINATION ${SERVICES_INSTALL_DIR})
|
|
|
|
|
|
|
|
endif(PARTMAN_KCM)
|
|
|
|
|