diff --git a/CMakeLists.txt b/CMakeLists.txt index 712323bc..4eae5b5d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,174 +1,172 @@ cmake_minimum_required(VERSION 3.5) set(KF5_VERSION "5.68.0") # handled by release scripts set(KF5_DEP_VERSION "5.67.0") # handled by release scripts project(KIO VERSION ${KF5_VERSION}) include(FeatureSummary) find_package(ECM 5.67.0 NO_MODULE) set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake Modules." URL "https://commits.kde.org/extra-cmake-modules") feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES) set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake ) include(KDEInstallDirs) include(KDEFrameworkCompilerSettings NO_POLICY_SCOPE) include(KDECMakeSettings) include(ECMGenerateExportHeader) include(ECMMarkAsTest) include(ECMSetupVersion) include(ECMGenerateHeaders) include(ECMAddQch) include(ECMMarkNonGuiExecutable) include(ECMQtDeclareLoggingCategory) include(ECMSourceVersionControl) ecm_setup_version( PROJECT VARIABLE_PREFIX KIO VERSION_HEADER "${CMAKE_CURRENT_BINARY_DIR}/src/kio_version.h" PACKAGE_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/KF5KIOConfigVersion.cmake" SOVERSION 5) option(KIOCORE_ONLY "Only compile KIOCore, not KIOWidgets or anything that depends on it. This will disable support for cookies and passwordhandling (prompting and storing)." OFF) option(KIO_FORK_SLAVES "If set we start the slaves via QProcess. It's also possible to change this by setting the environment variable KDE_FORK_SLAVES." OFF) # Enable state assertion by default on Jenkins and from-git builds. # This option should eventually be dropped and always be enabled. set(ASSERT_SLAVE_STATES_DEFAULT OFF) if(DEFINED ENV{JENKINS_SERVER_COOKIE} OR ECM_SOURCE_UNDER_VERSION_CONTROL) set(ASSERT_SLAVE_STATES_DEFAULT ON) endif() option(KIO_ASSERT_SLAVE_STATES "Used to control whether slave state assertions are enabled. When not enabled only warnings are generated." ${ASSERT_SLAVE_STATES_DEFAULT}) option(BUILD_QCH "Build API documentation in QCH format (for e.g. Qt Assistant, Qt Creator & KDevelop)" OFF) add_feature_info(QCH ${BUILD_QCH} "API documentation in QCH format (for e.g. Qt Assistant, Qt Creator & KDevelop)") option(BUILD_DESIGNERPLUGIN "Build plugin for Qt Designer" ON) add_feature_info(DESIGNERPLUGIN ${BUILD_DESIGNERPLUGIN} "Build plugin for Qt Designer") find_package(KF5Archive ${KF5_DEP_VERSION} REQUIRED) find_package(KF5Config ${KF5_DEP_VERSION} REQUIRED) find_package(KF5CoreAddons ${KF5_DEP_VERSION} REQUIRED) find_package(KF5Crash ${KF5_DEP_VERSION} REQUIRED) find_package(KF5DBusAddons ${KF5_DEP_VERSION} REQUIRED) find_package(KF5I18n ${KF5_DEP_VERSION} REQUIRED) find_package(KF5Service ${KF5_DEP_VERSION} REQUIRED) find_package(KF5DocTools ${KF5_DEP_VERSION}) find_package(KF5Solid ${KF5_DEP_VERSION} REQUIRED) # for kio_trash if (NOT KIOCORE_ONLY) find_package(KF5Bookmarks ${KF5_DEP_VERSION} REQUIRED) find_package(KF5Completion ${KF5_DEP_VERSION} REQUIRED) find_package(KF5ConfigWidgets ${KF5_DEP_VERSION} REQUIRED) find_package(KF5IconThemes ${KF5_DEP_VERSION} REQUIRED) find_package(KF5ItemViews ${KF5_DEP_VERSION} REQUIRED) find_package(KF5JobWidgets ${KF5_DEP_VERSION} REQUIRED) find_package(KF5WidgetsAddons ${KF5_DEP_VERSION} REQUIRED) find_package(KF5WindowSystem ${KF5_DEP_VERSION} REQUIRED) endif() if (UNIX) find_package(KF5Auth ${KF5_DEP_VERSION} REQUIRED) endif() # tell what is missing without doctools set_package_properties(KF5DocTools PROPERTIES DESCRIPTION "Provides tools to generate documentation in various format from DocBook files" TYPE OPTIONAL PURPOSE "Required to build help ioslave and documentation" ) set(REQUIRED_QT_VERSION 5.12.0) find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Widgets DBus Network Concurrent Xml Test) find_package(GSSAPI) set_package_properties(GSSAPI PROPERTIES DESCRIPTION "Allows KIO to make use of certain HTTP authentication services" URL "http://web.mit.edu/kerberos/www" TYPE OPTIONAL PURPOSE "A MIT or HEIMDAL flavor of GSSAPI can be used" ) if (NOT APPLE AND NOT WIN32) find_package(X11) endif() set(HAVE_X11 ${X11_FOUND}) if (HAVE_X11) find_package(Qt5 ${REQUIRED_QT_VERSION} CONFIG REQUIRED X11Extras) endif() # Qt 5.13 deprecated QComboBox::currentIndexChanged(QString) and Qt 5.14 undid that... if (NOT Qt5Widgets_VERSION VERSION_LESS 5.14.0) add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0x050d00) endif() add_definitions(-DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x054300) # we use KPixmapProvider in public API add_definitions(-DKCOMPLETION_DISABLE_DEPRECATED_BEFORE_AND_AT=0x054100) add_definitions(-DTRANSLATION_DOMAIN=\"kio5\") if (IS_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/po") ki18n_install(po) if (KF5DocTools_FOUND) kdoctools_install(po) endif() endif() if (KF5DocTools_FOUND) add_subdirectory(docs) endif() include(CheckLibraryExists) add_subdirectory(src) if(BUILD_TESTING) add_subdirectory(autotests) if (NOT KIOCORE_ONLY) add_subdirectory(tests) endif() endif() add_subdirectory(kconf_update) # create a Config.cmake and a ConfigVersion.cmake file and install them set(CMAKECONFIG_INSTALL_DIR "${KDE_INSTALL_CMAKEPACKAGEDIR}/KF5KIO") if (BUILD_QCH) ecm_install_qch_export( TARGETS KF5KIO_QCH FILE KF5KIOQchTargets.cmake DESTINATION "${CMAKECONFIG_INSTALL_DIR}" COMPONENT Devel ) set(PACKAGE_INCLUDE_QCHTARGETS "include(\"\${CMAKE_CURRENT_LIST_DIR}/KF5KIOQchTargets.cmake\")") endif() include(CMakePackageConfigHelpers) configure_package_config_file( "${CMAKE_CURRENT_SOURCE_DIR}/KF5KIOConfig.cmake.in" "${CMAKE_CURRENT_BINARY_DIR}/KF5KIOConfig.cmake" PATH_VARS KDE_INSTALL_DBUSINTERFACEDIR INSTALL_DESTINATION ${CMAKECONFIG_INSTALL_DIR} ) install(FILES "${CMAKE_CURRENT_BINARY_DIR}/KF5KIOConfig.cmake" "${CMAKE_CURRENT_BINARY_DIR}/KF5KIOConfigVersion.cmake" DESTINATION "${CMAKECONFIG_INSTALL_DIR}" COMPONENT Devel ) install(EXPORT KF5KIOTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE KF5KIOTargets.cmake NAMESPACE KF5:: ) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/src/kio_version.h DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5} COMPONENT Devel ) -install(FILES kio.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR}) - feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES) diff --git a/kio.categories b/kio.categories deleted file mode 100644 index 8ad16225..00000000 --- a/kio.categories +++ /dev/null @@ -1,20 +0,0 @@ -kf5.kio.cookiejar kcookiejar (KIO) IDENTIFIER [KIO_COOKIEJAR] -kf5.kio.core.copyjob KIO::CopyJob (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [KIO_COPYJOB_DEBUG] -kf5.kio.core.dirlister KCoreDirLister (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [KIO_CORE_DIRLISTER] -kf5.kio.core KIOCore (KIO) IDENTIFIER [KIO_CORE] -kf5.kio.core.sambashare sambashare (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [KIO_CORE_SAMBASHARE] -kf5.kiod KIO Daemon (KIO) IDENTIFIER [KIOD_CATEGORY] -kf5.kio.favicons FavIcons (KIO) IDENTIFIER [FAVICONS_LOG] -kf5.kio.kdirmodel KDirModel (KIO) IDENTIFIER [category] -kf5.kio.kio_file kiofile (KIO) IDENTIFIER [KIO_FILE] -kf5.kio.kio_ftp kio ftp (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [KIO_FTP] -kf5.kio.kio_http KIO HTTP slave (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [KIO_HTTP] -kf5.kio.kio_http.auth kio http auth (KIO) IDENTIFIER [KIO_HTTP_AUTH] -kf5.kio.kio_http.filter kio http filter (KIO) IDENTIFIER [KIO_HTTP_FILTER] -kf5.kio.trash kio trash (KIO) IDENTIFIER [KIO_TRASH] -kf5.kio.useragentdlg kio useragentdialog (KIO) IDENTIFIER [KIO_USERAGENTDLG] -kf5.kio.widgets KIOWidgets (KIO) IDENTIFIER [KIO_WIDGETS] -org.kde.kio.kpasswdserver KPasswdServer (KIO) IDENTIFIER [category] -org.kde.kurifilter-localdomain KUriFilter Local Domain (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [category] -org.kde.kurifilter-ikws KUriFilter IKWS (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [category] -org.kde.kurifilter-shorturi KUriFilter Shorturi (KIO) DEFAULT_SEVERITY [WARNING] IDENTIFIER [category] diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index cb08d45c..7357ae2b 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,103 +1,109 @@ add_subdirectory(core) # KIOCore-only executables add_subdirectory(protocoltojson) add_subdirectory(kntlm) add_subdirectory(ioslaves) add_subdirectory(kiod) add_subdirectory(kssld) add_subdirectory(kioslave) if (NOT KIOCORE_ONLY) add_subdirectory(kpasswdserver) add_subdirectory(gui) add_subdirectory(widgets) add_subdirectory(filewidgets) add_subdirectory(kioexec) add_subdirectory(urifilters) add_subdirectory(kcms) if(NOT WIN32 AND NOT ANDROID) # arpa/nameser.h add_subdirectory(kpac) endif() set(NON_KIOCORE_LINK_QCHS Qt5Widgets_QCH Qt5Network_QCH KF5Completion_QCH KF5WidgetsAddons_QCH KF5JobWidgets_QCH KF5Bookmarks_QCH KF5ItemViews_QCH KF5XmlGui_QCH KF5Solid_QCH ) if(BUILD_DESIGNERPLUGIN) add_subdirectory(designer) endif() endif() +ecm_qt_install_logging_categories( + EXPORT KIO + FILE kio.categories + DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR} +) + if (BUILD_QCH) macro(_make_absolute var_name base_path) set(_result) foreach(_path ${${var_name}}) if(IS_ABSOLUTE "${_path}") list(APPEND _result "${_path}") else() list(APPEND _result "${base_path}/${_path}") endif() endforeach() set(${var_name} ${_result}) endmacro() _make_absolute(KIONTLM_QCH_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/(kntlm") _make_absolute(KIOCore_QCH_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/core") _make_absolute(KIOGui_QCH_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/gui") _make_absolute(KIOWidgets_QCH_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/widgets") _make_absolute(KIOFileWidgets_QCH_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/filewidgets") ecm_add_qch( KF5KIO_QCH NAME KIO BASE_NAME KF5KIO VERSION ${KF5_VERSION} ORG_DOMAIN org.kde SOURCES # using only public headers, to cover only public API ${KIONTLM_QCH_SOURCES} ${KIOCore_QCH_SOURCES} ${KIOGui_QCH_SOURCES} ${KIOWidgets_QCH_SOURCES} ${KIOFileWidgets_QCH_SOURCES} MD_MAINPAGE "${CMAKE_SOURCE_DIR}/README.md" IMAGE_DIRS "${CMAKE_SOURCE_DIR}/docs/pics" LINK_QCHS KF5CoreAddons_QCH KF5Service_QCH ${NON_KIOCORE_LINK_QCHS} BLANK_MACROS KIOCORE_EXPORT KIOCORE_DEPRECATED_EXPORT KIOCORE_DEPRECATED "KIOCORE_DEPRECATED_VERSION(x, y, t)" KNTLM_EXPORT "KNTLM_DEPRECATED_VERSION(x, y, t)" KIOGUI_EXPORT KIOGUI_DEPRECATED_EXPORT KIOGUI_DEPRECATED "KIOGUI_DEPRECATED_VERSION(x, y, t)" KIOWIDGETS_EXPORT KIOWIDGETS_DEPRECATED_EXPORT KIOWIDGETS_DEPRECATED "KIOWIDGETS_DEPRECATED_VERSION(x, y, t)" KIOFILEWIDGETS_EXPORT KIOFILEWIDGETS_DEPRECATED_EXPORT KIOFILEWIDGETS_DEPRECATED "KIOFILEWIDGETS_DEPRECATED_VERSION(x, y, t)" TAGFILE_INSTALL_DESTINATION ${KDE_INSTALL_QTQCHDIR} QCH_INSTALL_DESTINATION ${KDE_INSTALL_QTQCHDIR} COMPONENT Devel ) endif() diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index 3c078805..017bb8af 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt @@ -1,305 +1,335 @@ project(KIOCore) include (ConfigureChecks.cmake) configure_file(config-kiocore.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kiocore.h ) configure_file(config-kmountpoint.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kmountpoint.h) # KSSL_HAVE_SSL only used in kssl/ksslsettings.cpp, but currently ifdefed out #find_package(OpenSSL) #set_package_properties(OpenSSL PROPERTIES DESCRIPTION "Support for secure network communications (SSL and TLS)" # URL "http://openssl.org" # TYPE RECOMMENDED # PURPOSE "KDE uses OpenSSL for the bulk of secure communications, including secure web browsing via HTTPS" # ) #if(OPENSSL_FOUND) # set(KSSL_HAVE_SSL 1) # include_directories(${OPENSSL_INCLUDE_DIR}) #endif() set(kiocore_SRCS idleslave.cpp klocalsocket.cpp connectionbackend.cpp connection.cpp connectionserver.cpp krecentdocument.cpp kfileitemlistproperties.cpp tcpslavebase.cpp directorysizejob.cpp forwardingslavebase.cpp chmodjob.cpp kdiskfreespaceinfo.cpp usernotificationhandler.cpp ksambasharedata.cpp ksambashare.cpp knfsshare.cpp kfileitem.cpp davjob.cpp deletejob.cpp copyjob.cpp filejob.cpp mkdirjob.cpp mkpathjob.cpp kpasswdserverloop.cpp kpasswdserverclient.cpp kremoteencoding.cpp sessiondata.cpp slavebase.cpp dataslave.cpp dataprotocol.cpp desktopexecparser.cpp emptytrashjob.cpp authinfo.cpp slaveinterface.cpp slave.cpp job_error.cpp job.cpp filecopyjob.cpp listjob.cpp mimetypejob.cpp multigetjob.cpp restorejob.cpp simplejob.cpp specialjob.cpp statjob.cpp storedtransferjob.cpp transferjob.cpp filesystemfreespacejob.cpp scheduler.cpp slaveconfig.cpp kprotocolmanager.cpp hostinfo.cpp kdirnotify.cpp kurlauthorized.cpp kacl.cpp udsentry.cpp global.cpp metadata.cpp kprotocolinfo.cpp kprotocolinfofactory.cpp jobtracker.cpp jobuidelegateextension.cpp jobuidelegatefactory.cpp kmountpoint.cpp kcoredirlister.cpp faviconscache.cpp ksslcertificatemanager.cpp ksslerroruidata.cpp ktcpsocket.cpp kssl/ksslsettings.cpp kioglobal_p.cpp batchrenamejob.cpp ) -ecm_qt_declare_logging_category(kiocore_SRCS HEADER kiocoredebug.h IDENTIFIER KIO_CORE CATEGORY_NAME kf5.kio.core) +ecm_qt_declare_logging_category(kiocore_SRCS + HEADER kiocoredebug.h + IDENTIFIER KIO_CORE + CATEGORY_NAME kf5.kio.core + DESCRIPTION "KIOCore (KIO)" + EXPORT KIO +) + +ecm_qt_export_logging_category( + IDENTIFIER KIO_COPYJOB_DEBUG + CATEGORY_NAME kf5.kio.core.copyjob + DEFAULT_SEVERITY Warning + DESCRIPTION "KIO::CopyJob (KIO)" + EXPORT KIO +) + +ecm_qt_export_logging_category( + IDENTIFIER KIO_CORE_DIRLISTER + CATEGORY_NAME kf5.kio.core.dirlister + DEFAULT_SEVERITY Warning + DESCRIPTION "KCoreDirLister (KIO)" + EXPORT KIO +) + +ecm_qt_export_logging_category( + IDENTIFIER KIO_CORE_SAMBASHARE + CATEGORY_NAME kf5.kio.core.sambashare + DEFAULT_SEVERITY Warning + DESCRIPTION "sambashare (KIO)" + EXPORT KIO +) if (UNIX) set(kiocore_SRCS ${kiocore_SRCS} klocalsocket_unix.cpp kioglobal_p_unix.cpp ) endif() if (WIN32) set(kiocore_SRCS ${kiocore_SRCS} klocalsocket_win.cpp kioglobal_p_win.cpp ) endif() qt5_add_dbus_interface(kiocore_SRCS org.kde.KSlaveLauncher.xml klauncher_interface) qt5_add_dbus_interface(kiocore_SRCS org.kde.KIOFuse.VFS.xml kiofuse_interface) set_source_files_properties(org.kde.KPasswdServer.xml PROPERTIES INCLUDE authinfo.h ) qt5_add_dbus_interface(kiocore_SRCS org.kde.KPasswdServer.xml kpasswdserver_interface) install(FILES org.kde.KDirNotify.xml DESTINATION ${KDE_INSTALL_DBUSINTERFACEDIR} RENAME kf5_org.kde.KDirNotify.xml) install(FILES org.kde.KPasswdServer.xml DESTINATION ${KDE_INSTALL_DBUSINTERFACEDIR} RENAME kf5_org.kde.KPasswdServer.xml) install(FILES org.kde.KSlaveLauncher.xml DESTINATION ${KDE_INSTALL_DBUSINTERFACEDIR} RENAME kf5_org.kde.KSlaveLauncher.xml) add_library(KF5KIOCore ${kiocore_SRCS}) add_library(KF5::KIOCore ALIAS KF5KIOCore) ecm_generate_export_header(KF5KIOCore BASE_NAME KIOCore GROUP_BASE_NAME KF VERSION ${KF5_VERSION} DEPRECATED_BASE_VERSION 0 DEPRECATION_VERSIONS 3.0 3.1 3.4 4.0 4.3 4.5 4.6 5.0 5.2 5.8 5.24 5.45 5.48 5.63 5.61 5.64 5.65 5.66 ) # TODO: add support for EXCLUDE_DEPRECATED_BEFORE_AND_AT to all KIO libs # needs fixing of undeprecated API being still implemented using own deprecated API target_include_directories(KF5KIOCore PUBLIC "$" # kio_version.h "$" ) target_include_directories(KF5KIOCore INTERFACE "$") target_link_libraries(KF5KIOCore PUBLIC KF5::CoreAddons # KJob KF5::Service Qt5::Network Qt5::Concurrent # QtConcurrentRun in hostinfo.cpp Qt5::DBus PRIVATE Qt5::Xml # davjob.cpp uses QDom KF5::I18n KF5::Crash KF5::DBusAddons # KDEInitInterface ) if (UNIX) target_link_libraries(KF5KIOCore PRIVATE KF5::AuthCore) #SlaveBase uses KAuth::Action endif() if(ACL_FOUND) target_link_libraries(KF5KIOCore PRIVATE ${ACL_LIBS}) endif() set_target_properties(KF5KIOCore PROPERTIES VERSION ${KIO_VERSION_STRING} SOVERSION ${KIO_SOVERSION} EXPORT_NAME KIOCore ) # this should be done by cmake, see bug 371721 if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND Qt5Core_VERSION VERSION_GREATER 5.8.0) add_custom_command( OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/moc_predefs.h COMMAND "${CMAKE_CXX_COMPILER}" "-dM" "-E" "-c" "${CMAKE_ROOT}/Modules/CMakeCXXCompilerABI.cpp" > ${CMAKE_CURRENT_BINARY_DIR}/moc_predefs.h ) set_property(TARGET KF5KIOCore APPEND PROPERTY AUTOMOC_MOC_OPTIONS --include ${CMAKE_CURRENT_BINARY_DIR}/moc_predefs.h) set_property(TARGET KF5KIOCore APPEND PROPERTY AUTOGEN_TARGET_DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/moc_predefs.h) endif() # Headers prefixed with KIO/ ecm_generate_headers(KIOCore_CamelCase_HEADERS HEADER_NAMES IdleSlave ConnectionServer TCPSlaveBase DirectorySizeJob ForwardingSlaveBase Job # ### should forward to job_base.h, not job.h... JobTracker Global ChmodJob DeleteJob CopyJob EmptyTrashJob FileJob MkdirJob MkpathJob SlaveBase SlaveConfig HostInfo MetaData UDSEntry JobUiDelegateExtension JobUiDelegateFactory SlaveInterface Slave FileCopyJob ListJob MimetypeJob MultiGetJob RestoreJob SimpleJob SpecialJob StatJob StoredTransferJob TransferJob Scheduler AuthInfo DavJob DesktopExecParser FileSystemFreeSpaceJob BatchRenameJob PREFIX KIO REQUIRED_HEADERS KIO_namespaced_HEADERS ) # Create local forwarding header for kio/job_base.h set(REGULAR_HEADER_NAME ${CMAKE_CURRENT_BINARY_DIR}/kio/job_base.h) if (NOT EXISTS ${REGULAR_HEADER_NAME}) file(WRITE ${REGULAR_HEADER_NAME} "#include \"${CMAKE_CURRENT_SOURCE_DIR}/job_base.h\"\n") endif() install(TARGETS KF5KIOCore EXPORT KF5KIOTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) list(APPEND KIO_namespaced_HEADERS http_slave_defaults.h ioslave_defaults.h job_base.h jobclasses.h ) install(FILES ${KIO_namespaced_HEADERS} DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOCore/kio COMPONENT Devel ) # Headers not prefixed with KIO/ ecm_generate_headers(KIOCore_HEADERS HEADER_NAMES KACL KUrlAuthorized KCoreDirLister KRemoteEncoding KDirNotify KDiskFreeSpaceInfo KFileItem KFileItemListProperties KMountPoint KNFSShare KSambaShare KSambaShareData KPasswdServerClient KProtocolInfo KProtocolManager KRecentDocument KSslCertificateManager KSslErrorUiData KTcpSocket REQUIRED_HEADERS KIOCore_HEADERS ) ecm_generate_headers(KIOCore_HEADERS HEADER_NAMES KSSLSettings RELATIVE kssl REQUIRED_HEADERS KIOCore_HEADERS ) install(FILES ${KIOCore_CamelCase_HEADERS} DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOCore/KIO COMPONENT Devel) install(FILES ksslcertificatemanager_p.h ${KIOCore_HEADERS} ${CMAKE_CURRENT_BINARY_DIR}/kiocore_export.h DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOCore COMPONENT Devel) install(FILES accept-languages.codes DESTINATION ${KDE_INSTALL_CONFDIR}) # make available to ecm_add_qch in parent folder set(KIOCore_QCH_SOURCES ${KIOCore_HEADERS} ${KIO_namespaced_HEADERS} PARENT_SCOPE) include(ECMGeneratePriFile) ecm_generate_pri_file(BASE_NAME KIOCore LIB_NAME KF5KIOCore DEPS "KCoreAddons KService" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOCore) install(FILES ${PRI_FILENAME} DESTINATION ${ECM_MKSPECS_INSTALL_DIR}) diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt index 59e661e1..1142476d 100644 --- a/src/gui/CMakeLists.txt +++ b/src/gui/CMakeLists.txt @@ -1,52 +1,58 @@ set(kiogui_SRCS faviconrequestjob.cpp ) -ecm_qt_declare_logging_category(kiogui_SRCS HEADER favicons_debug.h IDENTIFIER FAVICONS_LOG CATEGORY_NAME kf5.kio.favicons) +ecm_qt_declare_logging_category(kiogui_SRCS + HEADER favicons_debug.h + IDENTIFIER FAVICONS_LOG + CATEGORY_NAME kf5.kio.favicons + DESCRIPTION "FavIcons (KIO)" + EXPORT KIO +) add_library(KF5KIOGui ${kiogui_SRCS}) generate_export_header(KF5KIOGui BASE_NAME KIOGui) add_library(KF5::KIOGui ALIAS KF5KIOGui) target_include_directories(KF5KIOGui INTERFACE "$") target_link_libraries(KF5KIOGui PUBLIC KF5::KIOCore Qt5::Gui PRIVATE KF5::I18n ) set_target_properties(KF5KIOGui PROPERTIES VERSION ${KIO_VERSION_STRING} SOVERSION ${KIO_SOVERSION} EXPORT_NAME KIOGui ) # Headers prefixed with KIO/ ecm_generate_headers(KIOGui_CamelCase_HEADERS HEADER_NAMES FavIconRequestJob PREFIX KIO REQUIRED_HEADERS KIO_namespaced_gui_HEADERS ) install(FILES ${KIOGui_CamelCase_HEADERS} DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOGui/KIO COMPONENT Devel) install(TARGETS KF5KIOGui EXPORT KF5KIOTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) install(FILES ${KIO_namespaced_gui_HEADERS} DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOGui/kio COMPONENT Devel) install(FILES ${KIOGui_HEADERS} ${CMAKE_CURRENT_BINARY_DIR}/kiogui_export.h DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOGui COMPONENT Devel) # make available to ecm_add_qch in parent folder set(KIOGui_QCH_SOURCES ${KIOGui_HEADERS} ${KIO_namespaced_gui_HEADERS} PARENT_SCOPE) include(ECMGeneratePriFile) ecm_generate_pri_file(BASE_NAME KIOGui LIB_NAME KF5KIOGui DEPS "KIOCore" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOGui) install(FILES ${PRI_FILENAME} DESTINATION ${ECM_MKSPECS_INSTALL_DIR}) diff --git a/src/ioslaves/file/CMakeLists.txt b/src/ioslaves/file/CMakeLists.txt index 78b88f24..96080817 100644 --- a/src/ioslaves/file/CMakeLists.txt +++ b/src/ioslaves/file/CMakeLists.txt @@ -1,46 +1,53 @@ project(kioslave-file) include(ConfigureChecks.cmake) ########### next target ############### if(WIN32) set(kio_file_PART_SRCS file.cpp file_win.cpp ) else() set(kio_file_PART_SRCS file.cpp file_unix.cpp fdreceiver.cpp legacycodec.cpp ) endif() find_package(ACL) set(HAVE_LIBACL ${ACL_FOUND}) set(HAVE_POSIX_ACL ${ACL_FOUND}) set_package_properties(ACL PROPERTIES DESCRIPTION "LibACL" URL "ftp://oss.sgi.com/projects/xfs/cmd_tars" TYPE RECOMMENDED PURPOSE "Support for manipulating access control lists") check_include_files(sys/xattr.h HAVE_SYS_XATTR_H) configure_file(config-kioslave-file.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kioslave-file.h ) +ecm_qt_export_logging_category( + IDENTIFIER KIO_FILE + CATEGORY_NAME kf5.kio.kio_file + DESCRIPTION "kiofile (KIO)" + EXPORT KIO +) + add_library(kio_file MODULE ${kio_file_PART_SRCS}) target_link_libraries(kio_file KF5::KIOCore KF5::I18n Qt5::DBus Qt5::Network) if(UNIX) target_link_libraries(kio_file Qt5::Network KF5::AuthCore) endif() if (HAVE_VOLMGT AND CMAKE_SYSTEM_NAME MATCHES SunOS) target_link_libraries(kio_file -lvolmgt) endif () if(ACL_FOUND) target_link_libraries(kio_file ${ACL_LIBS}) endif() set_target_properties(kio_file PROPERTIES OUTPUT_NAME "file") set_target_properties(kio_file PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/kf5/kio") install(TARGETS kio_file DESTINATION ${KDE_INSTALL_PLUGINDIR}/kf5/kio) if (UNIX) add_subdirectory(kauth) endif() diff --git a/src/ioslaves/ftp/CMakeLists.txt b/src/ioslaves/ftp/CMakeLists.txt index f9e69a0c..db6ca811 100644 --- a/src/ioslaves/ftp/CMakeLists.txt +++ b/src/ioslaves/ftp/CMakeLists.txt @@ -1,19 +1,26 @@ project(kioslave-ftp) include(ConfigureChecks.cmake) configure_file(config-kioslave-ftp.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kioslave-ftp.h ) ########### next target ############### set(kio_ftp_PART_SRCS ftp.cpp ) +ecm_qt_export_logging_category( + IDENTIFIER KIO_FTP + CATEGORY_NAME kf5.kio.kio_ftp + DEFAULT_SEVERITY Warning + DESCRIPTION "kio ftp (KIO)" + EXPORT KIO +) add_library(kio_ftp MODULE ${kio_ftp_PART_SRCS}) target_link_libraries(kio_ftp Qt5::Network KF5::KIOCore KF5::I18n) set_target_properties(kio_ftp PROPERTIES OUTPUT_NAME "ftp") set_target_properties(kio_ftp PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/kf5/kio") install(TARGETS kio_ftp DESTINATION ${KDE_INSTALL_PLUGINDIR}/kf5/kio) diff --git a/src/ioslaves/http/CMakeLists.txt b/src/ioslaves/http/CMakeLists.txt index acfbb744..b2dd26dc 100644 --- a/src/ioslaves/http/CMakeLists.txt +++ b/src/ioslaves/http/CMakeLists.txt @@ -1,93 +1,114 @@ project(kioslave-http) include(ECMMarkNonGuiExecutable) include(ConfigureChecks.cmake) configure_file(config-kioslave-http.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kioslave-http.h ) find_package(X11) set(HAVE_X11 ${X11_FOUND}) if(GSSAPI_FOUND) set(HAVE_LIBGSSAPI 1) if(GSSAPI_FLAVOR STREQUAL "MIT") set(GSSAPI_MIT 1) else() set(GSSAPI_MIT 0) endif() include_directories( ${GSSAPI_INCS} ) else() set(HAVE_LIBGSSAPI 0) set(GSSAPI_MIT 0) endif() configure_file(config-gssapi.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-gssapi.h ) include_directories(${ZLIB_INCLUDE_DIR}) if (NOT KIOCORE_ONLY) add_subdirectory( kcookiejar ) endif() ########### next target ############### set(kio_http_cache_cleaner_SRCS http_cache_cleaner.cpp ) add_executable(kio_http_cache_cleaner ${kio_http_cache_cleaner_SRCS}) # Mark it as non-gui so we won't create an app bundle on Mac OS X ecm_mark_nongui_executable(kio_http_cache_cleaner) target_link_libraries(kio_http_cache_cleaner Qt5::DBus Qt5::Network # QLocalSocket ${ZLIB_LIBRARY} KF5::KIOCore # KProtocolManager KF5::I18n) install(TARGETS kio_http_cache_cleaner DESTINATION ${KDE_INSTALL_LIBEXECDIR_KF5} ) ########### next target ############### # kio/httpfilter/Makefile.am: httpfilter set(kio_http_PART_SRCS http.cpp httpauthentication.cpp httpfilter.cpp ) +ecm_qt_export_logging_category( + IDENTIFIER KIO_HTTP + CATEGORY_NAME kf5.kio.kio_http + DEFAULT_SEVERITY Warning + DESCRIPTION "KIO HTTP slave (KIO)" + EXPORT KIO +) + +ecm_qt_export_logging_category( + IDENTIFIER KIO_HTTP_AUTH + CATEGORY_NAME kf5.kio.kio_http.auth + DESCRIPTION "kio http auth (KIO)" + EXPORT KIO +) + +ecm_qt_export_logging_category( + IDENTIFIER KIO_HTTP_FILTER + CATEGORY_NAME kf5.kio.kio_http.filter + DESCRIPTION "kio http filter (KIO)" + EXPORT KIO +) add_library(kio_http MODULE ${kio_http_PART_SRCS}) target_link_libraries(kio_http Qt5::DBus Qt5::Network # QLocalSocket etc. Qt5::Xml # QDom KF5::KIOCore KF5::KIONTLM KF5::Archive ${ZLIB_LIBRARY} KF5::I18n ) if(GSSAPI_FOUND) target_link_libraries(kio_http ${GSSAPI_LIBS} ) endif() set_target_properties(kio_http PROPERTIES OUTPUT_NAME "http") set_target_properties(kio_http PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/kf5/kio") install(TARGETS kio_http DESTINATION ${KDE_INSTALL_PLUGINDIR}/kf5/kio) ########### install files ############### install( FILES http_cache_cleaner.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR} ) diff --git a/src/ioslaves/http/kcookiejar/CMakeLists.txt b/src/ioslaves/http/kcookiejar/CMakeLists.txt index ae03a48f..b894815e 100644 --- a/src/ioslaves/http/kcookiejar/CMakeLists.txt +++ b/src/ioslaves/http/kcookiejar/CMakeLists.txt @@ -1,49 +1,56 @@ ####### kcookiejar: command line tool for talking to the kded kcookiejar module ####### qt5_generate_dbus_interface(${CMAKE_CURRENT_SOURCE_DIR}/kcookieserver.h org.kde.KCookieServer.xml) set(kcookieserver_xml ${CMAKE_CURRENT_BINARY_DIR}/org.kde.KCookieServer.xml) set_source_files_properties(${kcookieserver_xml} PROPERTIES INCLUDE "kcookiejar_include.h") qt5_add_dbus_interfaces(kcookiejar_SRCS ${kcookieserver_xml}) set(kcookiejar_SRCS ${kcookiejar_SRCS} main.cpp) add_executable( kcookiejar5 ${kcookiejar_SRCS}) ecm_mark_nongui_executable(kcookiejar5) target_link_libraries( kcookiejar5 Qt5::DBus KF5::I18n KF5::WidgetsAddons ) install(TARGETS kcookiejar5 ${KF5_INSTALL_TARGETS_DEFAULT_ARGS} ) ########### kded kcookiejar module ############### set(kded_kcookiejar_SRCS kcookiejar.cpp kcookieserver.cpp kcookiewin.cpp ) +ecm_qt_export_logging_category( + IDENTIFIER KIO_COOKIEJAR + CATEGORY_NAME kf5.kio.cookiejar + DESCRIPTION "kcookiejar (KIO)" + EXPORT KIO +) + qt5_add_dbus_adaptor( kded_kcookiejar_SRCS ${CMAKE_CURRENT_BINARY_DIR}/org.kde.KCookieServer.xml kcookieserver.h KCookieServer ) kcoreaddons_add_plugin(kded_kcookiejar INSTALL_NAMESPACE "kf5/kded" JSON kcookiejar.json SOURCES ${kded_kcookiejar_SRCS}) set_target_properties(kded_kcookiejar PROPERTIES OUTPUT_NAME kcookiejar ) target_link_libraries(kded_kcookiejar KF5::WindowSystem KF5::ConfigCore KF5::CoreAddons KF5::DBusAddons KF5::I18n KF5::WidgetsAddons ) ########### install files ############### install( FILES domain_info DESTINATION ${KDE_INSTALL_DATADIR_KF5}/kcookiejar ) install( FILES ${CMAKE_CURRENT_BINARY_DIR}/org.kde.KCookieServer.xml DESTINATION ${KDE_INSTALL_DBUSINTERFACEDIR} RENAME kf5_org.kde.KCookieServer.xml) kdbusaddons_generate_dbus_service_file(kded5 org.kde.kcookiejar5 ${KDE_INSTALL_FULL_BINDIR}) diff --git a/src/ioslaves/remote/CMakeLists.txt b/src/ioslaves/remote/CMakeLists.txt index 21615385..df0a3f02 100644 --- a/src/ioslaves/remote/CMakeLists.txt +++ b/src/ioslaves/remote/CMakeLists.txt @@ -1,19 +1,23 @@ add_subdirectory( kdedmodule ) set(kio_remote_SRCS kio_remote.cpp remoteimpl.cpp ) -ecm_qt_declare_logging_category(kio_remote_SRCS HEADER debug.h - IDENTIFIER KIOREMOTE_LOG - CATEGORY_NAME kf5.kio.kio_remote - DEFAULT_SEVERITY Info) +ecm_qt_declare_logging_category(kio_remote_SRCS + HEADER debug.h + IDENTIFIER KIOREMOTE_LOG + CATEGORY_NAME kf5.kio.kio_remote + DEFAULT_SEVERITY Info + DESCRIPTION "kio_remote (KIO)" + EXPORT KIO +) kcoreaddons_add_plugin(kio_remote SOURCES ${kio_remote_SRCS} INSTALL_NAMESPACE kf5/kio) target_link_libraries(kio_remote KF5::KIOCore KF5::I18n Qt5::Network) set_target_properties(kio_remote PROPERTIES OUTPUT_NAME "remote") diff --git a/src/ioslaves/trash/CMakeLists.txt b/src/ioslaves/trash/CMakeLists.txt index 549c4baa..3e07b763 100644 --- a/src/ioslaves/trash/CMakeLists.txt +++ b/src/ioslaves/trash/CMakeLists.txt @@ -1,87 +1,93 @@ # find_package(Strigi) # set_package_properties(Strigi PROPERTIES DESCRIPTION "Desktop indexing and search support" # URL "http://strigi.sourceforge.net" # TYPE ${STRIGI_TYPE} # ) # if (WIN32) # set (STRIGI_TYPE "OPTIONAL") # else () # set (STRIGI_TYPE "REQUIRED") # endif () if(BUILD_TESTING) if(WIN32) message(AUTHOR_WARNING "kio_trash unit tests are broken on Windows, disabling them") else() add_subdirectory(tests) endif() endif() ########### next target ############### -ecm_qt_declare_logging_category(kio_trash_PART_DEBUG_SRCS HEADER kiotrashdebug.h IDENTIFIER KIO_TRASH CATEGORY_NAME kf5.kio.trash) +ecm_qt_declare_logging_category(kio_trash_PART_DEBUG_SRCS + HEADER kiotrashdebug.h + IDENTIFIER KIO_TRASH + CATEGORY_NAME kf5.kio.trash + DESCRIPTION "kio trash (KIO)" + EXPORT KIO +) if(WIN32) set(kio_trash_PART_SRCS kio_trash_win.cpp ${kio_trash_PART_DEBUG_SRCS}) else() # Files that are shared with the KCM. Unix specific. set (trashcommon_unix_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/trashimpl.cpp ${CMAKE_CURRENT_SOURCE_DIR}/discspaceutil.cpp ${CMAKE_CURRENT_SOURCE_DIR}/trashsizecache.cpp ${CMAKE_CURRENT_SOURCE_DIR}/kinterprocesslock.cpp ) set(kio_trash_PART_SRCS kio_trash.cpp ${trashcommon_unix_SRCS} ${kio_trash_PART_DEBUG_SRCS}) endif() add_library(kio_trash MODULE ${kio_trash_PART_SRCS}) target_link_libraries(kio_trash KF5::Solid KF5::KIOCore Qt5::DBus Qt5::Network KF5::I18n KF5::ConfigCore KF5::ConfigGui ) if(APPLE) target_link_libraries(kio_trash "-framework DiskArbitration -framework CoreFoundation") endif(APPLE) set_target_properties(kio_trash PROPERTIES OUTPUT_NAME "trash") set_target_properties(kio_trash PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/kf5/kio") install(TARGETS kio_trash DESTINATION ${KDE_INSTALL_PLUGINDIR}/kf5/kio ) set(ktrash_SRCS ktrash.cpp ) add_executable(ktrash5 ${ktrash_SRCS}) target_compile_definitions(ktrash5 PRIVATE -DPROJECT_VERSION="${PROJECT_VERSION}") ecm_mark_nongui_executable(ktrash5) target_link_libraries(ktrash5 KF5::KIOCore KF5::I18n KF5::ConfigCore KF5::ConfigGui ) install(TARGETS ktrash5 ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) ########### next target ############### # currently not on win32, TODO! if(NOT WIN32 AND NOT KIOCORE_ONLY) set(kcm_trash_PART_SRCS kcmtrash.cpp ${trashcommon_unix_SRCS} ${kio_trash_PART_DEBUG_SRCS}) add_library(kcm_trash MODULE ${kcm_trash_PART_SRCS}) target_link_libraries(kcm_trash Qt5::DBus KF5::I18n KF5::ConfigWidgets KF5::KIOCore KF5::Solid) if(APPLE) target_link_libraries(kcm_trash "-framework DiskArbitration -framework CoreFoundation") endif(APPLE) install(TARGETS kcm_trash DESTINATION ${KDE_INSTALL_PLUGINDIR}) endif() ########### install files ############### install( FILES kcmtrash.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR} ) diff --git a/src/kcms/kio/CMakeLists.txt b/src/kcms/kio/CMakeLists.txt index 3bb827fd..55aea069 100644 --- a/src/kcms/kio/CMakeLists.txt +++ b/src/kcms/kio/CMakeLists.txt @@ -1,55 +1,62 @@ add_subdirectory( uasproviders ) find_package(KF5TextWidgets ${KF5_DEP_VERSION} REQUIRED) ########### next target ############### set(kcm_kio_PART_SRCS main.cpp kcookiesmain.cpp kcookiespolicies.cpp kcookiesmanagement.cpp kcookiespolicyselectiondlg.cpp smbrodlg.cpp useragentdlg.cpp kproxydlg.cpp useragentinfo.cpp useragentselectordlg.cpp netpref.cpp cache.cpp ksaveioconfig.cpp) ki18n_wrap_ui(kcm_kio_PART_SRCS cache.ui useragentselectordlg.ui useragentdlg.ui kproxydlg.ui kcookiespolicies.ui kcookiesmanagement.ui kcookiespolicyselectiondlg.ui) +ecm_qt_export_logging_category( + IDENTIFIER KIO_USERAGENTDLG + CATEGORY_NAME kf5.kio.useragentdlg + DESCRIPTION "kio useragentdialog (KIO)" + EXPORT KIO +) + add_library(kcm_kio MODULE ${kcm_kio_PART_SRCS}) target_link_libraries(kcm_kio PUBLIC Qt5::DBus KF5::ConfigCore KF5::ConfigGui KF5::ConfigWidgets KF5::Completion KF5::KIOCore KF5::KIOWidgets KF5::IconThemes KF5::ItemViews # KTreeWidgetSearchLine KF5::TextWidgets # KPluralHandlingSpinBox PRIVATE KF5::I18n) install(TARGETS kcm_kio DESTINATION ${KDE_INSTALL_PLUGINDIR} ) ########### install files ############### install( FILES smb.desktop cookies.desktop useragent.desktop cache.desktop netpref.desktop proxy.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR} ) install( FILES uasprovider.desktop DESTINATION ${KDE_INSTALL_KSERVICETYPES5DIR} ) diff --git a/src/kiod/CMakeLists.txt b/src/kiod/CMakeLists.txt index 8795fbde..f68fc230 100644 --- a/src/kiod/CMakeLists.txt +++ b/src/kiod/CMakeLists.txt @@ -1,29 +1,36 @@ include(ECMMarkNonGuiExecutable) set(kiod_SRCS kiod_main.cpp) if (APPLE) set(kiod_SRCS ${kiod_SRCS} kiod_agent.mm) endif() +ecm_qt_export_logging_category( + IDENTIFIER KIOD_CATEGORY + CATEGORY_NAME kf5.kiod + DESCRIPTION "KIO Daemon (KIO)" + EXPORT KIO +) + add_executable(kiod5 ${kiod_SRCS}) target_link_libraries(kiod5 KF5::KIOCore # ksslcertificatemanager KF5::DBusAddons # kdedmodule KF5::CoreAddons # kpluginfactory Qt5::Network Qt5::DBus Qt5::Widgets # QApplication ) if (APPLE) target_link_libraries(kiod5 "-framework AppKit -framework CoreFoundation") # Mark it as non-gui so we won't create an app bundle on Mac OS X ecm_mark_nongui_executable(kiod5) endif () install(TARGETS kiod5 DESTINATION ${KDE_INSTALL_LIBEXECDIR_KF5}) kdbusaddons_generate_dbus_service_file(kiod5 org.kde.kiod5 ${KDE_INSTALL_FULL_LIBEXECDIR_KF5}) diff --git a/src/kioexec/CMakeLists.txt b/src/kioexec/CMakeLists.txt index 16f6daa4..e266bedb 100644 --- a/src/kioexec/CMakeLists.txt +++ b/src/kioexec/CMakeLists.txt @@ -1,46 +1,49 @@ set(kioexecd_SRCS kioexecd.cpp) qt5_generate_dbus_interface(${CMAKE_CURRENT_SOURCE_DIR}/kioexecd.h org.kde.KIOExecd.xml) qt5_add_dbus_adaptor(kioexecd_SRCS ${CMAKE_CURRENT_BINARY_DIR}/org.kde.KIOExecd.xml kioexecd.h KIOExecd) ecm_qt_declare_logging_category(kioexecd_SRCS HEADER kioexecdebug.h IDENTIFIER KIOEXEC - CATEGORY_NAME kf5.kio.execd) + CATEGORY_NAME kf5.kio.execd + DESCRIPTION "kioexecd (KIO)" + EXPORT KIO +) kcoreaddons_add_plugin(kioexecd SOURCES ${kioexecd_SRCS} JSON kioexecd.json INSTALL_NAMESPACE "kf5/kiod") target_link_libraries(kioexecd KF5::I18n KF5::DBusAddons KF5::WidgetsAddons KF5::KIOCore) kdbusaddons_generate_dbus_service_file(kiod5 org.kde.kioexecd ${KDE_INSTALL_FULL_LIBEXECDIR_KF5}) # next target set(kioexec_SRCS main.cpp) qt5_add_dbus_interface(kioexec_SRCS ${CMAKE_CURRENT_BINARY_DIR}/org.kde.KIOExecd.xml kioexecdinterface) add_executable(kioexec ${kioexec_SRCS}) configure_file(config-kioexec.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kioexec.h) ecm_mark_nongui_executable(kioexec) target_link_libraries(kioexec Qt5::Widgets KF5::I18n KF5::KIOWidgets # KRun KF5::WidgetsAddons # KMessageBox KF5::WindowSystem # KStartupInfo KF5::DBusAddons # KDBusService ) if (HAVE_X11) target_link_libraries(kioexec Qt5::X11Extras) endif() install(TARGETS kioexec DESTINATION ${KDE_INSTALL_LIBEXECDIR_KF5} ) diff --git a/src/kpasswdserver/CMakeLists.txt b/src/kpasswdserver/CMakeLists.txt index 3cc98c0f..09360ac3 100644 --- a/src/kpasswdserver/CMakeLists.txt +++ b/src/kpasswdserver/CMakeLists.txt @@ -1,37 +1,44 @@ find_package(KF5Wallet ${KF5_DEP_VERSION}) # tell what is missing without wallet set_package_properties(KF5Wallet PROPERTIES DESCRIPTION "Safe desktop-wide storage for passwords" TYPE OPTIONAL PURPOSE "Required to have permanent storage of passwords for kpasswdserver" ) if (KF5Wallet_FOUND) add_definitions(-DHAVE_KF5WALLET) set(WALLET_LIB KF5::Wallet) endif() if(BUILD_TESTING) add_subdirectory(autotests) endif() set(kiod_kpasswdserver_SRCS kpasswdserver.cpp kiod_kpasswdserver.cpp) qt5_add_dbus_adaptor(kiod_kpasswdserver_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../core/org.kde.KPasswdServer.xml kpasswdserver.h KPasswdServer) +ecm_qt_export_logging_category( + IDENTIFIER category + CATEGORY_NAME org.kde.kio.kpasswdserver + DESCRIPTION "KPasswdServer (KIO)" + EXPORT KIO +) + kcoreaddons_add_plugin(kiod_kpasswdserver INSTALL_NAMESPACE "kf5/kiod" JSON kpasswdserver.json SOURCES ${kiod_kpasswdserver_SRCS}) set_target_properties(kiod_kpasswdserver PROPERTIES OUTPUT_NAME kpasswdserver ) target_link_libraries(kiod_kpasswdserver KF5::DBusAddons # KDED Module Qt5::DBus KF5::KIOCore KF5::WidgetsAddons # KPasswordDialog KF5::I18n KF5::WindowSystem ${WALLET_LIB} ) kdbusaddons_generate_dbus_service_file(kiod5 org.kde.kpasswdserver ${KDE_INSTALL_FULL_LIBEXECDIR_KF5}) diff --git a/src/urifilters/ikws/CMakeLists.txt b/src/urifilters/ikws/CMakeLists.txt index ebe5828e..976f86dd 100644 --- a/src/urifilters/ikws/CMakeLists.txt +++ b/src/urifilters/ikws/CMakeLists.txt @@ -1,47 +1,55 @@ add_subdirectory(searchproviders) #### set(kuriikwsfilter_SRCS kuriikwsfiltereng.cpp kuriikwsfilter.cpp searchprovider.cpp searchproviderregistry.cpp ) ki18n_wrap_ui(kuriikwsfilter_SRCS ikwsopts_ui.ui searchproviderdlg_ui.ui) +ecm_qt_export_logging_category( + IDENTIFIER category + CATEGORY_NAME org.kde.kurifilter-ikws + DEFAULT_SEVERITY Warning + DESCRIPTION "KUriFilter IKWS (KIO)" + EXPORT KIO +) + kcoreaddons_add_plugin(kuriikwsfilter INSTALL_NAMESPACE "kf5/urifilters" JSON kuriikwsfilter.json SOURCES ${kuriikwsfilter_SRCS}) target_link_libraries(kuriikwsfilter KF5::ConfigWidgets # KCModule KF5::KIOWidgets # KUriFilter KF5::I18n Qt5::DBus ) ##### set(kurisearchfilter_SRCS kurisearchfilter.cpp kuriikwsfiltereng.cpp ikwsopts.cpp searchproviderdlg.cpp searchprovider.cpp searchproviderregistry.cpp ) ki18n_wrap_ui(kurisearchfilter_SRCS ikwsopts_ui.ui searchproviderdlg_ui.ui) kcoreaddons_add_plugin(kurisearchfilter INSTALL_NAMESPACE "kf5/urifilters" JSON kurisearchfilter.json SOURCES ${kurisearchfilter_SRCS}) target_link_libraries(kurisearchfilter KF5::ConfigWidgets # KCModule KF5::KIOWidgets # KUriFilter KF5::I18n Qt5::DBus ) ########### install files ############### install( FILES searchprovider.desktop DESTINATION ${KDE_INSTALL_KSERVICETYPES5DIR} ) diff --git a/src/urifilters/localdomain/CMakeLists.txt b/src/urifilters/localdomain/CMakeLists.txt index 4de825a6..ba03d751 100644 --- a/src/urifilters/localdomain/CMakeLists.txt +++ b/src/urifilters/localdomain/CMakeLists.txt @@ -1,6 +1,14 @@ set(localdomainurifilter_SRCS localdomainurifilter.cpp ) +ecm_qt_export_logging_category( + IDENTIFIER category + CATEGORY_NAME org.kde.kurifilter-localdomain + DEFAULT_SEVERITY Warning + DESCRIPTION "KUriFilter Local Domain (KIO)" + EXPORT KIO +) + kcoreaddons_add_plugin(localdomainurifilter INSTALL_NAMESPACE "kf5/urifilters" JSON localdomainurifilter.json SOURCES ${localdomainurifilter_SRCS}) target_link_libraries(localdomainurifilter KF5::KIOWidgets) diff --git a/src/urifilters/shorturi/CMakeLists.txt b/src/urifilters/shorturi/CMakeLists.txt index 02787470..0f09a050 100644 --- a/src/urifilters/shorturi/CMakeLists.txt +++ b/src/urifilters/shorturi/CMakeLists.txt @@ -1,8 +1,16 @@ set(kshorturifilter_SRCS kshorturifilter.cpp) +ecm_qt_export_logging_category( + IDENTIFIER category + CATEGORY_NAME org.kde.kurifilter-shorturi + DEFAULT_SEVERITY Warning + DESCRIPTION "KUriFilter Shorturi (KIO)" + EXPORT KIO +) + kcoreaddons_add_plugin(kshorturifilter INSTALL_NAMESPACE "kf5/urifilters" JSON kshorturifilter.json SERVICETYPES ${CMAKE_SOURCE_DIR}/src/widgets/kurifilterplugin.desktop SOURCES ${kshorturifilter_SRCS}) target_link_libraries(kshorturifilter KF5::I18n KF5::KIOWidgets Qt5::DBus) install( FILES kshorturifilterrc DESTINATION ${KDE_INSTALL_CONFDIR} ) diff --git a/src/widgets/CMakeLists.txt b/src/widgets/CMakeLists.txt index 28db1096..04455c80 100644 --- a/src/widgets/CMakeLists.txt +++ b/src/widgets/CMakeLists.txt @@ -1,214 +1,227 @@ project(KIOWidgets) #include (ConfigureChecks.cmake) # Device desktop files aren't really used anymore set(KIO_NO_SOLID TRUE) find_package(ACL) set(HAVE_LIBACL ${ACL_FOUND}) set(HAVE_POSIX_ACL ${ACL_FOUND}) set_package_properties(ACL PROPERTIES DESCRIPTION "LibACL" URL "ftp://oss.sgi.com/projects/xfs/cmd_tars" TYPE RECOMMENDED PURPOSE "Support for manipulating access control lists") configure_file(config-kiowidgets.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kiowidgets.h) set(kiowidgets_SRCS accessmanager.cpp accessmanagerreply_p.cpp fileundomanager.cpp kacleditwidget.cpp kpropertiesdialog.cpp kurlrequesterdialog.cpp kurlcombobox.cpp kfileitemactions.cpp delegateanimationhandler.cpp imagefilter.cpp kfileitemdelegate.cpp kdesktopfileactions.cpp kopenwithdialog.cpp kfile.cpp pastedialog.cpp paste.cpp clipboardupdater.cpp kabstractfileitemactionplugin.cpp koverlayiconplugin.cpp kbuildsycocaprogressdialog.cpp kurlrequester.cpp krun.cpp sslui.cpp kurlpixmapprovider.cpp pixmaploader.cpp thumbsequencecreator.cpp thumbcreator.cpp kshellcompletion.cpp kurlcompletion.cpp kurifilter.cpp dropjob.cpp openfilemanagerwindowjob.cpp pastejob.cpp previewjob.cpp renamedialog.cpp ksslcertificatebox.cpp kdynamicjobtracker.cpp ksslinfodialog.cpp joburlcache.cpp skipdialog.cpp jobuidelegate.cpp kdirlister.cpp kdirmodel.cpp executablefileopendialog.cpp dndpopupmenuplugin.cpp kurifiltersearchprovideractions.cpp renamefiledialog.cpp ) if (WIN32) list(APPEND kiowidgets_SRCS krun_win.cpp ) else() list(APPEND kiowidgets_SRCS kautomount.cpp ) endif() -ecm_qt_declare_logging_category(kiowidgets_SRCS HEADER kio_widgets_debug.h IDENTIFIER KIO_WIDGETS CATEGORY_NAME kf5.kio.widgets) +ecm_qt_declare_logging_category(kiowidgets_SRCS + HEADER kio_widgets_debug.h + IDENTIFIER KIO_WIDGETS + CATEGORY_NAME kf5.kio.widgets + DESCRIPTION "KIOWidgets (KIO)" + EXPORT KIO +) + +ecm_qt_export_logging_category( + IDENTIFIER category + CATEGORY_NAME kf5.kio.kdirmodel + DESCRIPTION "KDirModel (KIO)" + EXPORT KIO +) qt5_add_dbus_adaptor(kiowidgets_SRCS org.kde.kio.FileUndoManager.xml fileundomanager_p.h KIO::FileUndoManagerPrivate fileundomanager_adaptor KIOFileUndoManagerAdaptor) qt5_add_dbus_interface(kiowidgets_SRCS org.kde.kuiserver.xml kuiserver_interface) ki18n_wrap_ui(kiowidgets_SRCS checksumswidget.ui certificateparty.ui sslinfo.ui kpropertiesdesktopadvbase.ui kpropertiesdesktopbase.ui ) add_library(KF5KIOWidgets ${kiowidgets_SRCS}) add_library(KF5::KIOWidgets ALIAS KF5KIOWidgets) ecm_generate_export_header(KF5KIOWidgets BASE_NAME KIOWidgets GROUP_BASE_NAME KF VERSION ${KF5_VERSION} DEPRECATED_BASE_VERSION 0 DEPRECATION_VERSIONS 4.0 4.1 4.3 4.4 4.5 4.6 4.7 5.0 5.4 5.6 5.25 5.31 5.32 5.64 5.66 ) # TODO: add support for EXCLUDE_DEPRECATED_BEFORE_AND_AT to all KIO libs # needs fixing of undeprecated API being still implemented using own deprecated API target_include_directories(KF5KIOWidgets INTERFACE "$") target_link_libraries(KF5KIOWidgets PUBLIC KF5::KIOCore KF5::JobWidgets KF5::Service Qt5::Network # SSL KF5::Completion # KUrlCompletion uses KCompletion KF5::WidgetsAddons # keditlistwidget PRIVATE Qt5::Concurrent Qt5::DBus KF5::I18n KF5::IconThemes # KIconLoader KF5::WindowSystem # KStartupInfo KF5::ConfigWidgets # KColorScheme ) if(ACL_FOUND) target_link_libraries(KF5KIOWidgets PRIVATE ${ACL_LIBS}) endif() set_target_properties(KF5KIOWidgets PROPERTIES VERSION ${KIO_VERSION_STRING} SOVERSION ${KIO_SOVERSION} EXPORT_NAME KIOWidgets ) # Headers not prefixed with KIO/ ecm_generate_headers(KIOWidgets_HEADERS HEADER_NAMES KPropertiesDialog KUrlRequesterDialog KUrlComboBox KFileItemActions KFileItemDelegate KAutoMount KDesktopFileActions KOpenWithDialog KAbstractFileItemActionPlugin KOverlayIconPlugin KBuildSycocaProgressDialog KFile KUrlRequester KRun KUrlPixmapProvider KSslCertificateBox KSslInfoDialog KDirLister KDirModel KShellCompletion KUrlCompletion KUriFilter REQUIRED_HEADERS KIOWidgets_HEADERS ) # Headers prefixed with KIO/ ecm_generate_headers(KIOWidgets_CamelCase_HEADERS HEADER_NAMES AccessManager SslUi ThumbSequenceCreator ThumbCreator DropJob DndPopupMenuPlugin OpenFileManagerWindowJob PasteJob PreviewJob RenameDialog SkipDialog JobUiDelegate FileUndoManager Paste PixmapLoader KUriFilterSearchProviderActions # KF6: fix and move to non-KIO prefixed install folder RenameFileDialog PREFIX KIO REQUIRED_HEADERS KIO_namespaced_widgets_HEADERS ) install(FILES ${KIOWidgets_CamelCase_HEADERS} DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOWidgets/KIO COMPONENT Devel) install(TARGETS KF5KIOWidgets EXPORT KF5KIOTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}) install(FILES org.kde.kio.FileUndoManager.xml DESTINATION ${KDE_INSTALL_DBUSINTERFACEDIR} RENAME kf5_org.kde.kio.FileUndoManager.xml) install(FILES ${KIO_namespaced_widgets_HEADERS} DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOWidgets/kio COMPONENT Devel) install(FILES ${KIOWidgets_HEADERS} ${CMAKE_CURRENT_BINARY_DIR}/kiowidgets_export.h DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOWidgets COMPONENT Devel) install(FILES kfileitemactionplugin.desktop kpropertiesdialogplugin.desktop kurifilterplugin.desktop konqpopupmenuplugin.desktop kiodndpopupmenuplugin.desktop DESTINATION ${KDE_INSTALL_KSERVICETYPES5DIR} ) # make available to ecm_add_qch in parent folder set(KIOWidgets_QCH_SOURCES ${KIOWidgets_HEADERS} ${KIO_namespaced_widgets_HEADERS} PARENT_SCOPE) include(ECMGeneratePriFile) ecm_generate_pri_file(BASE_NAME KIOWidgets LIB_NAME KF5KIOWidgets DEPS "KIOCore KBookmarks KXmlGui Solid" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/KIOWidgets) install(FILES ${PRI_FILENAME} DESTINATION ${ECM_MKSPECS_INSTALL_DIR})