Warning, /frameworks/sonnet/src/plugins/hunspell/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 add_library(sonnet_hunspell MODULE
0002     hunspellclient.cpp
0003     hunspelldict.cpp
0004 )
0005 
0006 ecm_qt_declare_logging_category(sonnet_hunspell
0007     HEADER hunspelldebug.h
0008     IDENTIFIER SONNET_HUNSPELL
0009     CATEGORY_NAME kf.sonnet.clients.hunspell
0010     OLD_CATEGORY_NAMES sonnet.plugins.hunspell
0011     DESCRIPTION "Sonnet HUnspell plugin"
0012     EXPORT SONNET
0013 )
0014 
0015 # see: https://phabricator.kde.org/R246:0a96acf251baa5c9dd042d093ab2bf8fcee10502
0016 set(USE_OLD_HUNSPELL_API TRUE)
0017 if (PKG_HUNSPELL_VERSION GREATER "1.5.0")
0018     set(USE_OLD_HUNSPELL_API FALSE) # new API introduced in v1.5.1 (cf. https://github.com/hunspell/hunspell/commit/8006703dafeebce19f2144c5cf180812eb99693a)
0019 endif()
0020 message(STATUS "Using old hunspell API: ${USE_OLD_HUNSPELL_API}")
0021 
0022 configure_file(config-hunspell.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-hunspell.h)
0023 
0024 target_include_directories(sonnet_hunspell SYSTEM PUBLIC ${HUNSPELL_INCLUDE_DIRS})
0025 target_link_libraries(sonnet_hunspell PRIVATE KF6::SonnetCore ${HUNSPELL_LIBRARIES})
0026 
0027 target_compile_definitions(sonnet_hunspell PRIVATE DEFINITIONS SONNET_INSTALL_PREFIX="${CMAKE_INSTALL_PREFIX}")
0028 
0029 install(TARGETS sonnet_hunspell  DESTINATION ${KDE_INSTALL_PLUGINDIR}/kf6/sonnet/)