2020-10-25 18:58:02 +00:00
|
|
|
project(harbour-sailfin-sailfish)
|
|
|
|
|
|
|
|
# find_library(SAILFISH sailfishapp 1.0 REQUIRED)
|
2020-10-27 15:31:34 +00:00
|
|
|
include(ExternalProject)
|
|
|
|
# FIXME: don't hardcode /home/deploy/installroot/
|
|
|
|
set(DEPLOY_ROOT /home/deploy/installroot/)
|
|
|
|
ExternalProject_Add(BlurhashQt
|
2021-09-04 20:23:54 +00:00
|
|
|
# PREFIX ${CMAKE_CURRENT_BINARY_DIR}/lib/blurhash-qt
|
|
|
|
GIT_REPOSITORY https://github.com/HenkKalkwater/BlurhashQt.git
|
|
|
|
GIT_TAG 61ae7f0feca6ab67da1bfdbcb222bbd12e8f7e07
|
2021-01-14 16:43:42 +00:00
|
|
|
|
2021-09-04 20:23:54 +00:00
|
|
|
CMAKE_ARGS -DBUILD_SHARED_LIBS:BOOL=ON -DENABLE_EXPORT=OFF -DQML_PLUGIN_PATH=${PROJECT_BINARY_DIR}/plugins/)
|
2020-10-27 15:31:34 +00:00
|
|
|
|
2023-12-23 14:06:36 +00:00
|
|
|
find_package(Qt5 COMPONENTS Gui Qml Quick LinguistTools)
|
2020-10-25 18:58:02 +00:00
|
|
|
find_package(SailfishApp 1.0 REQUIRED)
|
|
|
|
|
|
|
|
set(harbour-sailfin_SOURCES
|
|
|
|
src/harbour-sailfin.cpp)
|
|
|
|
|
2020-10-25 23:14:46 +00:00
|
|
|
set(sailfin_QML_SOURCES
|
|
|
|
qml/Constants.qml
|
|
|
|
qml/Utils.js
|
2021-07-31 13:06:17 +00:00
|
|
|
qml/components/music/NarrowAlbumCover.qml
|
|
|
|
qml/components/music/WideAlbumCover.qml
|
|
|
|
qml/components/music/SongDelegate.qml
|
|
|
|
qml/components/videoplayer/VideoError.qml
|
|
|
|
qml/components/videoplayer/VideoHud.qml
|
2024-01-02 18:51:27 +00:00
|
|
|
qml/components/ContributorsSection.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/components/IconListItem.qml
|
2022-12-28 20:20:04 +00:00
|
|
|
qml/components/ItemChildrenShowcase.qml
|
2021-09-04 20:23:54 +00:00
|
|
|
qml/components/JItem.qml
|
|
|
|
qml/components/LibraryItemDelegate.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/components/MoreSection.qml
|
|
|
|
qml/components/PlainLabel.qml
|
2021-07-31 13:06:17 +00:00
|
|
|
qml/components/PlaybackBar.qml
|
|
|
|
qml/components/PlayQueue.qml
|
|
|
|
qml/components/PlayToolbar.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/components/RemoteImage.qml
|
|
|
|
qml/components/Shim.qml
|
|
|
|
qml/components/UserGridDelegate.qml
|
|
|
|
qml/components/VideoPlayer.qml
|
2021-07-31 13:06:17 +00:00
|
|
|
qml/components/VideoTrackSelector.qml
|
2022-12-28 20:20:04 +00:00
|
|
|
qml/cover/CollectionPage.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/cover/PosterCover.qml
|
2022-12-28 20:20:04 +00:00
|
|
|
qml/cover/NowPlayingCover.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/pages/LegalPage.qml
|
|
|
|
qml/pages/MainPage.qml
|
|
|
|
qml/pages/AboutPage.qml
|
2022-12-28 20:20:04 +00:00
|
|
|
qml/harbour-sailfin.qml
|
|
|
|
qml/pages/ConnectingPage.qml
|
|
|
|
qml/pages/ControllableDevicesPage.qml
|
2024-01-02 18:51:27 +00:00
|
|
|
qml/pages/QuickConnectDialog.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/pages/SettingsPage.qml
|
|
|
|
qml/pages/VideoPage.qml
|
|
|
|
qml/pages/itemdetails/BaseDetailPage.qml
|
|
|
|
qml/pages/itemdetails/CollectionPage.qml
|
|
|
|
qml/pages/itemdetails/EpisodePage.qml
|
|
|
|
qml/pages/itemdetails/FilmPage.qml
|
|
|
|
qml/pages/itemdetails/MusicAlbumPage.qml
|
2022-12-28 20:20:04 +00:00
|
|
|
qml/pages/itemdetails/MusicArtistPage.qml
|
|
|
|
qml/pages/itemdetails/MusicLibraryPage.qml
|
2021-07-31 13:06:17 +00:00
|
|
|
qml/pages/itemdetails/PhotoPage.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/pages/itemdetails/SeasonPage.qml
|
|
|
|
qml/pages/itemdetails/SeriesPage.qml
|
|
|
|
qml/pages/itemdetails/UnsupportedPage.qml
|
|
|
|
qml/pages/itemdetails/VideoPage.qml
|
2021-07-31 13:06:17 +00:00
|
|
|
qml/pages/settings/DebugPage.qml
|
2021-09-04 20:23:54 +00:00
|
|
|
qml/pages/settings/StreamingPage.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/pages/setup/AddServerConnectingPage.qml
|
2021-09-04 20:23:54 +00:00
|
|
|
qml/pages/setup/AddServerPage.qml
|
|
|
|
qml/pages/setup/LoginDialog.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/qmldir)
|
|
|
|
|
2023-12-23 14:06:36 +00:00
|
|
|
set(TRANSLATION_SOURCE_FILES
|
|
|
|
${harbour-sailfin_SOURCES}
|
|
|
|
${sailfin_QML_SOURCES}
|
|
|
|
)
|
|
|
|
|
|
|
|
set(TRANSLATION_TS_FILES
|
|
|
|
translations/harbour-sailfin.ts
|
|
|
|
translations/harbour-sailfin-de.ts
|
|
|
|
translations/harbour-sailfin-ru.ts
|
|
|
|
)
|
|
|
|
|
|
|
|
qt5_create_translation(TRANSLATION_QM_FILES
|
|
|
|
${TRANSLATION_SOURCE_FILES}
|
|
|
|
${TRANSLATION_TS_FILES})
|
|
|
|
add_custom_target(translations ALL DEPENDS ${TRANSLATION_QM_FILES})
|
|
|
|
|
2020-10-26 21:29:07 +00:00
|
|
|
add_executable(harbour-sailfin ${harbour-sailfin_SOURCES} ${sailfin_QML_SOURCES})
|
2020-10-25 23:14:46 +00:00
|
|
|
target_link_libraries(harbour-sailfin PRIVATE Qt5::Gui Qt5::Qml Qt5::Quick SailfishApp::SailfishApp
|
|
|
|
# Note: this may break when the compiler changes. -rdynamic and -pie seem to be needed for the
|
|
|
|
# invoker/booster to work
|
2021-07-31 13:06:17 +00:00
|
|
|
JellyfinQt "-Wl,-rpath,${CMAKE_INSTALL_LIBDIR} -rdynamic -pie")
|
2021-02-20 22:20:39 +00:00
|
|
|
target_compile_definitions(harbour-sailfin
|
2021-09-04 20:23:54 +00:00
|
|
|
PRIVATE $<$<OR:$<CONFIG:Debug>,$<CONFIG:RelWithDebInfo>>:QT_QML_DEBUG>)
|
2020-10-25 23:14:46 +00:00
|
|
|
|
2020-10-25 18:58:02 +00:00
|
|
|
install(TARGETS harbour-sailfin
|
|
|
|
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
|
|
|
|
2021-01-14 16:43:42 +00:00
|
|
|
install(DIRECTORY ${PROJECT_BINARY_DIR}/plugins/
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/harbour-sailfin/)
|
2020-10-25 18:58:02 +00:00
|
|
|
install(DIRECTORY qml
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/harbour-sailfin
|
2020-10-25 18:58:02 +00:00
|
|
|
)
|
2023-12-23 14:06:36 +00:00
|
|
|
install(FILES ${TRANSLATION_QM_FILES}
|
|
|
|
DESTINATION share/harbour-sailfin/translations
|
2020-10-25 18:58:02 +00:00
|
|
|
)
|
|
|
|
install(FILES harbour-sailfin.desktop
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/applications
|
2020-10-25 18:58:02 +00:00
|
|
|
)
|
|
|
|
install(FILES icons/86x86/harbour-sailfin.png
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/icons/hicolor/86x86/apps
|
2020-10-25 18:58:02 +00:00
|
|
|
)
|
|
|
|
install(FILES icons/108x108/harbour-sailfin.png
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/icons/hicolor/108x108/apps )
|
2020-10-25 18:58:02 +00:00
|
|
|
install(FILES icons/128x128/harbour-sailfin.png
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/icons/hicolor/128x128/apps
|
2020-10-25 18:58:02 +00:00
|
|
|
)
|
|
|
|
install(FILES icons/172x172/harbour-sailfin.png
|
2021-09-04 20:23:54 +00:00
|
|
|
DESTINATION share/icons/hicolor/172x172/apps )
|
2020-10-26 21:29:07 +00:00
|
|
|
|
|
|
|
# Tell Qt Creator where the application executable(s) would be located on the
|
|
|
|
# device.
|
|
|
|
#
|
|
|
|
# It is not necessary to list other deployables than executables (runtime
|
|
|
|
# targets) here. The deployment process of Sailfish OS projects is opaque to
|
|
|
|
# Qt Creator and the information contained in QtCreatorDeployment.txt is only
|
|
|
|
# used to locate the executable associated with the active run configuration
|
|
|
|
# on the device in order to run it.
|
|
|
|
#
|
|
|
|
# Search the Qt Creator Manual to learn about the QtCreatorDeployment.txt file
|
|
|
|
# format.
|
|
|
|
file(WRITE "${CMAKE_BINARY_DIR}/QtCreatorDeployment.txt"
|
2022-04-26 17:53:12 +00:00
|
|
|
"${CMAKE_INSTALL_PREFIX}\n${CMAKE_BINARY_DIR}/sailfish/harbour-sailfin:bin")
|