Changeset View
Changeset View
Standalone View
Standalone View
fish/CMakeLists.txt
1 | add_definitions(-DTRANSLATION_DOMAIN=\"kio5_fish\") | 1 | add_definitions(-DTRANSLATION_DOMAIN=\"kio5_fish\") | ||
---|---|---|---|---|---|
2 | 2 | | |||
3 | include(CheckIncludeFiles) | 3 | include(CheckIncludeFiles) | ||
4 | include(CheckFunctionExists) | 4 | include(CheckFunctionExists) | ||
5 | include(ECMQtDeclareLoggingCategory) | ||||
5 | 6 | | |||
6 | check_include_files(termios.h HAVE_TERMIOS_H) | 7 | check_include_files(termios.h HAVE_TERMIOS_H) | ||
7 | check_include_files(util.h HAVE_UTIL_H) | 8 | check_include_files(util.h HAVE_UTIL_H) | ||
8 | check_include_files(sys/ioctl.h HAVE_SYS_IOCTL_H) | 9 | check_include_files(sys/ioctl.h HAVE_SYS_IOCTL_H) | ||
9 | check_include_files(pty.h HAVE_PTY_H) | 10 | check_include_files(pty.h HAVE_PTY_H) | ||
10 | check_include_files("sys/types.h;libutil.h" HAVE_LIBUTIL_H) | 11 | check_include_files("sys/types.h;libutil.h" HAVE_LIBUTIL_H) | ||
11 | check_function_exists(getpt HAVE_GETPT) | 12 | check_function_exists(getpt HAVE_GETPT) | ||
12 | check_function_exists(grantpt HAVE_GRANTPT) | 13 | check_function_exists(grantpt HAVE_GRANTPT) | ||
Show All 25 Lines | 27 | if (MD5SUM_EXECUTABLE) | |||
38 | endif () | 39 | endif () | ||
39 | add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/fishcode.h | 40 | add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/fishcode.h | ||
40 | COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${FISH_GENERATOR} ARGS ${CMAKE_CURRENT_SOURCE_DIR}/fish.pl ${MD5SUM_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/fishcode.h "${CUT_ARG}" | 41 | COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${FISH_GENERATOR} ARGS ${CMAKE_CURRENT_SOURCE_DIR}/fish.pl ${MD5SUM_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/fishcode.h "${CUT_ARG}" | ||
41 | DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/fish.pl | 42 | DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/fish.pl | ||
42 | WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ) | 43 | WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ) | ||
43 | 44 | | |||
44 | set(kio_fish_PART_SRCS fish.cpp ${CMAKE_CURRENT_BINARY_DIR}/fishcode.h) | 45 | set(kio_fish_PART_SRCS fish.cpp ${CMAKE_CURRENT_BINARY_DIR}/fishcode.h) | ||
45 | 46 | | |||
47 | ecm_qt_declare_logging_category(kio_fish_PART_SRCS | ||||
48 | HEADER loggingcategory.h | ||||
49 | IDENTIFIER KIO_FISH_DEBUG | ||||
50 | CATEGORY_NAME kio_fish | ||||
51 | DEFAULT_SEVERITY Debug) | ||||
52 | | ||||
46 | add_library(kio_fish MODULE ${kio_fish_PART_SRCS}) | 53 | add_library(kio_fish MODULE ${kio_fish_PART_SRCS}) | ||
47 | 54 | | |||
48 | target_link_libraries(kio_fish KF5::KIOCore KF5::KDELibs4Support) | 55 | target_link_libraries(kio_fish KF5::KIOCore KF5::WidgetsAddons KF5::I18n) | ||
49 | 56 | | |||
50 | set_target_properties(kio_fish PROPERTIES OUTPUT_NAME "fish") | 57 | set_target_properties(kio_fish PROPERTIES OUTPUT_NAME "fish") | ||
51 | 58 | | |||
52 | if (UTIL_LIBRARIES) | 59 | if (UTIL_LIBRARIES) | ||
53 | target_link_libraries(kio_fish ${UTIL_LIBRARIES}) | 60 | target_link_libraries(kio_fish ${UTIL_LIBRARIES}) | ||
54 | endif () | 61 | endif () | ||
55 | 62 | | |||
56 | install(TARGETS kio_fish DESTINATION ${PLUGIN_INSTALL_DIR}/kf5/kio ) | 63 | install(TARGETS kio_fish DESTINATION ${PLUGIN_INSTALL_DIR}/kf5/kio ) | ||
57 | 64 | | |||
58 | 65 | | |||
59 | ########### install files ############### | 66 | ########### install files ############### | ||
60 | 67 | | |||
61 | install( FILES fish.protocol DESTINATION ${SERVICES_INSTALL_DIR} ) | 68 | install( FILES fish.protocol DESTINATION ${SERVICES_INSTALL_DIR} ) | ||
62 | 69 | | |||
63 | endif () | 70 | endif () |