diff --git a/kgpg/CMakeLists.txt b/kgpg/CMakeLists.txt index 0e356492..28d632d0 100644 --- a/kgpg/CMakeLists.txt +++ b/kgpg/CMakeLists.txt @@ -1,10 +1,8 @@ project(kgpg) if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_SOURCE_DIR}) - include(FeatureSummary) + find_package(KDELibs4 4.21.0 REQUIRED) - find_package(KDE4 4.21.0 REQUIRED) - include(KDE4Defaults) include_directories(${KDE4_INCLUDES}) add_definitions(${QT_DEFINITIONS} ${KDE4_DEFINITIONS}) endif() @@ -17,9 +15,8 @@ set(kgpg_SRCS add_executable(kgpg ${kgpg_SRCS}) target_link_libraries(kgpg - ${KDE4_KDEUI_LIBS} - ${KDE4_KFILE_LIBS} - ${KDE4_KIO_LIBS} + KDE4::kdeui + KDE4::kio gpgme ) diff --git a/kman/CMakeLists.txt b/kman/CMakeLists.txt index d74b0559..0635d6d2 100644 --- a/kman/CMakeLists.txt +++ b/kman/CMakeLists.txt @@ -15,7 +15,7 @@ set(kman_sources add_executable(kman ${kman_sources}) target_link_libraries(kman KDE4::kdeui - KDE4::kfile + KDE4::kio KDE4::karchive ) diff --git a/kwrite/CMakeLists.txt b/kwrite/CMakeLists.txt index 8d0b37fc..053770fc 100644 --- a/kwrite/CMakeLists.txt +++ b/kwrite/CMakeLists.txt @@ -1,12 +1,11 @@ project(kwrite) -cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR) +if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_SOURCE_DIR}) + find_package(KDELibs4 4.19.0 REQUIRED) -find_package(KDE4 REQUIRED) -include(KDE4Defaults) - -include_directories(${KDE4_INCLUDES}) -add_definitions(${KDE4_DEFINITIONS} ${QT_DEFINITIONS}) + include_directories(${KDE4_INCLUDES}) + add_definitions(${QT_DEFINITIONS} ${KDE4_DEFINITIONS}) +endif() set(kwrite_sources kwritemain.cpp @@ -14,8 +13,23 @@ set(kwrite_sources ) add_executable(kwrite ${kwrite_sources}) -target_link_libraries(kwrite KDE4::ktexteditor KDE4::kio KDE4::kparts) +target_link_libraries(kwrite + KDE4::ktexteditor + KDE4::kio + KDE4::kparts +) -install(TARGETS kwrite DESTINATION ${KDE4_BIN_INSTALL_DIR}) -install(FILES kwriteui.rc DESTINATION ${KDE4_DATA_INSTALL_DIR}/kwrite) -install(PROGRAMS kwrite.desktop DESTINATION ${KDE4_XDG_APPS_INSTALL_DIR}) +install( + TARGETS kwrite + DESTINATION ${KDE4_BIN_INSTALL_DIR} +) + +install( + FILES kwriteui.rc + DESTINATION ${KDE4_DATA_INSTALL_DIR}/kwrite +) + +install( + PROGRAMS kwrite.desktop + DESTINATION ${KDE4_XDG_APPS_INSTALL_DIR} +) diff --git a/kwrite/kwriteapp.cpp b/kwrite/kwriteapp.cpp index 6d6235c4..146ac485 100644 --- a/kwrite/kwriteapp.cpp +++ b/kwrite/kwriteapp.cpp @@ -25,6 +25,7 @@ Boston, MA 02110-1301, USA. #include #include +#include KWriteApp::KWriteApp(KCmdLineArgs *m_args) : KApplication () diff --git a/kwrite/kwritemain.cpp b/kwrite/kwritemain.cpp index 58528ead..ba0828c9 100644 --- a/kwrite/kwritemain.cpp +++ b/kwrite/kwritemain.cpp @@ -19,7 +19,6 @@ */ #include "kwritemain.h" -#include "kwritemain.moc" #include "kwriteapp.h" #include #include @@ -672,7 +671,7 @@ int main(int argc, char **argv) ki18n("KWrite"), KDE_VERSION_STRING, ki18n( "KWrite - Text Editor" ), KAboutData::License_LGPL_V2, - ki18n( "(c) 2000-2013 The Kate Authors" ), KLocalizedString(), "http://www.kate-editor.org" ); + ki18n( "(c) 2000-2013 The Kate Authors" )); aboutData.addAuthor (ki18n("Christoph Cullmann"), ki18n("Maintainer"), "cullmann@kde.org", "http://www.cullmann.io"); aboutData.addAuthor (ki18n("Anders Lund"), ki18n("Core Developer"), "anders@alweb.dk", "http://www.alweb.dk"); aboutData.addAuthor (ki18n("Joseph Wenninger"), ki18n("Core Developer"), "jowenn@kde.org","http://stud3.tuwien.ac.at/~e9925371");