Warning, /frameworks/kio/src/kpac/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 0002 kde_enable_exceptions() 0003 0004 include(ConfigureChecks.cmake) 0005 0006 # needed for kpac notifications about problems 0007 find_package(KF5Notifications ${KF_DEP_VERSION}) 0008 set_package_properties(KF5Notifications PROPERTIES 0009 DESCRIPTION "Notifications library" 0010 TYPE OPTIONAL 0011 PURPOSE "Required to have error notification support in kpac") 0012 if (KF5Notifications_FOUND) 0013 add_definitions(-DHAVE_KF5NOTIFICATIONS) 0014 endif() 0015 0016 configure_file(config-kpac.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kpac.h) 0017 0018 ########### next target ############### 0019 0020 find_package(Qt${QT_MAJOR_VERSION}Qml ${REQUIRED_QT_VERSION}) 0021 0022 if (TARGET Qt${QT_MAJOR_VERSION}::Qml) 0023 kcoreaddons_add_plugin(kded_proxyscout 0024 INSTALL_NAMESPACE "kf${QT_MAJOR_VERSION}/kded" 0025 ) 0026 set_target_properties(kded_proxyscout PROPERTIES 0027 OUTPUT_NAME proxyscout 0028 ) 0029 0030 target_sources(kded_proxyscout PRIVATE 0031 proxyscout.cpp 0032 script.cpp 0033 downloader.cpp 0034 discovery.cpp 0035 ) 0036 0037 target_link_libraries(kded_proxyscout 0038 PRIVATE 0039 Qt${QT_MAJOR_VERSION}::Network 0040 Qt${QT_MAJOR_VERSION}::Qml 0041 ${KPAC_EXTRA_LIBS} 0042 KF5::KIOCore # KIO::get 0043 KF5::DBusAddons # KDEDModule 0044 KF5::I18n 0045 ) 0046 if (KF5Notifications_FOUND) 0047 target_link_libraries(kded_proxyscout PRIVATE KF5::Notifications) 0048 endif() 0049 0050 # this needs -lresolv e.g on Slackware, but not on FreeBSD 0051 if (HAVE_RESOLV_LIBRARY) 0052 target_link_libraries(kded_proxyscout PRIVATE resolv) 0053 endif () 0054 0055 if (TARGET Qt6::Core5Compat) 0056 target_link_libraries(kded_proxyscout PRIVATE Qt6::Core5Compat) # QTextCodec 0057 endif() 0058 endif() 0059 0060 set_package_properties(Qt${QT_MAJOR_VERSION}Qml PROPERTIES DESCRIPTION "QtQml, one of the Qt${QT_MAJOR_VERSION} modules" 0061 TYPE OPTIONAL 0062 PURPOSE "Required to build support for auto-configuration of network proxies" 0063 ) 0064 0065 ecm_qt_declare_logging_category(kded_proxyscout 0066 HEADER kio_kpac_debug.h 0067 IDENTIFIER KIO_KPAC 0068 CATEGORY_NAME kf.kio.kpac 0069 DESCRIPTION "KPAC ProxyScout (KIO)" 0070 EXPORT KIO 0071 ) 0072 ########### next target ############### 0073 0074 add_executable(kpac_dhcp_helper) 0075 ecm_mark_nongui_executable(kpac_dhcp_helper) 0076 0077 target_sources(kpac_dhcp_helper PRIVATE 0078 kpac_dhcp_helper.c 0079 ) 0080 0081 if (HAVE_NSL_LIBRARY) 0082 # Assume Solaris 0083 target_link_libraries(kpac_dhcp_helper nsl) 0084 endif () 0085 0086 if (HAVE_SOCKET_LIBRARY) 0087 target_link_libraries(kpac_dhcp_helper socket) 0088 endif () 0089 0090 install(TARGETS kpac_dhcp_helper DESTINATION ${KDE_INSTALL_LIBEXECDIR_KF} ) 0091 0092 ########### install files ############### 0093 0094 install( FILES proxyscout.notifyrc DESTINATION ${KDE_INSTALL_KNOTIFYRCDIR} )