CMakeLists.txt 826 Bytes
Newer Older
1 2 3 4 5 6
set(ktrip_SRCS
    main.cpp
    querycontroller.cpp
    locationquerymodel.cpp
)

Nicolas Fella's avatar
Nicolas Fella committed
7 8 9 10
if (ANDROID)
    list(APPEND ktrip_SRCS androidutils.cpp)
endif()

Nicolas Fella's avatar
Nicolas Fella committed
11
qt5_add_resources(ktrip_SRCS resources.qrc)
12
add_executable(ktrip ${ktrip_SRCS})
Nicolas Fella's avatar
Nicolas Fella committed
13
target_link_libraries(ktrip PRIVATE Qt5::Qml Qt5::Gui KPublicTransport)
Nicolas Fella's avatar
Nicolas Fella committed
14

Nicolas Fella's avatar
Nicolas Fella committed
15
if (ANDROID)
Nicolas Fella's avatar
Nicolas Fella committed
16 17 18 19 20 21 22 23 24 25 26 27
    target_link_libraries(ktrip PRIVATE
        KF5::Kirigami2
        Qt5::Svg
        OpenSSL::SSL
        Qt5::AndroidExtras
    )

    kirigami_package_breeze_icons(ICONS
        go-down-symbolic
        go-next-symbolic
        go-up-symbolic
        view-refresh
Nicolas Fella's avatar
Nicolas Fella committed
28
        search
Nicolas Fella's avatar
Nicolas Fella committed
29
    )
Nicolas Fella's avatar
Nicolas Fella committed
30 31
else()
    target_link_libraries(ktrip Qt5::Widgets)
Nicolas Fella's avatar
Nicolas Fella committed
32 33
endif()

Nicolas Fella's avatar
Nicolas Fella committed
34 35 36 37 38
install(TARGETS ktrip ${INSTALL_TARGETS_DEFAULT_ARGS})

if (NOT ANDROID)
    install(PROGRAMS org.kde.ktrip.desktop DESTINATION ${KDE_INSTALL_APPDIR})
endif()