CMakeLists.txt 875 Bytes
Newer Older
Nicolas Fella's avatar
Nicolas Fella committed
1 2
add_subdirectory(dateandtime)

3 4 5 6 7 8
set(ktrip_SRCS
    main.cpp
    querycontroller.cpp
    locationquerymodel.cpp
)

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

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

Nicolas Fella's avatar
Nicolas Fella committed
17
if (ANDROID)
Nicolas Fella's avatar
Nicolas Fella committed
18 19 20 21 22 23 24 25 26 27 28 29
    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
30
        search
Nicolas Fella's avatar
Nicolas Fella committed
31
    )
Nicolas Fella's avatar
Nicolas Fella committed
32
else()
Nicolas Fella's avatar
Nicolas Fella committed
33
    target_link_libraries(ktrip PRIVATE Qt5::Widgets)
Nicolas Fella's avatar
Nicolas Fella committed
34 35
endif()

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

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