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
|
|
|
|
# PREFIX ${CMAKE_CURRENT_BINARY_DIR}/lib/blurhash-qt
|
|
|
|
GIT_REPOSITORY https://github.com/HenkKalkwater/BlurhashQt.git
|
2021-01-14 16:43:42 +00:00
|
|
|
GIT_TAG 61ae7f0feca6ab67da1bfdbcb222bbd12e8f7e07
|
|
|
|
|
|
|
|
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
|
|
|
|
2020-10-25 18:58:02 +00:00
|
|
|
find_package(Qt5 COMPONENTS Gui Qml Quick)
|
|
|
|
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
|
2020-10-27 01:35:50 +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
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/components/IconListItem.qml
|
|
|
|
qml/components/LibraryItemDelegate.qml
|
|
|
|
qml/components/MoreSection.qml
|
|
|
|
qml/components/PlainLabel.qml
|
2021-02-14 17:40:46 +00:00
|
|
|
qml/components/PlaybackBar.qml
|
2021-02-20 22:20:39 +00:00
|
|
|
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
|
2020-10-26 21:29:07 +00:00
|
|
|
qml/components/VideoTrackSelector.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/cover/CoverPage.qml
|
|
|
|
qml/cover/PosterCover.qml
|
|
|
|
qml/cover/VideoCover.qml
|
|
|
|
qml/pages/LegalPage.qml
|
|
|
|
qml/pages/MainPage.qml
|
|
|
|
qml/pages/AboutPage.qml
|
|
|
|
qml/harbour-sailfin.qml
|
|
|
|
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
|
2021-01-14 19:35:24 +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-02-13 20:42:57 +00:00
|
|
|
qml/pages/settings/DebugPage.qml
|
2020-10-25 23:14:46 +00:00
|
|
|
qml/pages/setup/AddServerConnectingPage.qml
|
|
|
|
qml/pages/setup/LoginDialog.qml
|
|
|
|
qml/qmldir)
|
|
|
|
|
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
|
|
|
|
jellyfin-qt "-Wl,-rpath,${CMAKE_INSTALL_LIBDIR} -rdynamic -pie")
|
2021-02-20 22:20:39 +00:00
|
|
|
target_compile_definitions(harbour-sailfin
|
|
|
|
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/
|
|
|
|
DESTINATION share/harbour-sailfin/)
|
2020-10-25 18:58:02 +00:00
|
|
|
install(DIRECTORY qml
|
|
|
|
DESTINATION share/harbour-sailfin
|
|
|
|
)
|
|
|
|
install(DIRECTORY translations
|
|
|
|
DESTINATION share/harbour-sailfin
|
|
|
|
FILES_MATCHING PATTERN "*.qm"
|
|
|
|
)
|
|
|
|
install(FILES harbour-sailfin.desktop
|
|
|
|
DESTINATION share/applications
|
|
|
|
)
|
|
|
|
install(FILES icons/86x86/harbour-sailfin.png
|
|
|
|
DESTINATION share/icons/hicolor/86x86/apps
|
|
|
|
)
|
|
|
|
install(FILES icons/108x108/harbour-sailfin.png
|
|
|
|
DESTINATION share/icons/hicolor/108x108/apps
|
|
|
|
)
|
|
|
|
install(FILES icons/128x128/harbour-sailfin.png
|
|
|
|
DESTINATION share/icons/hicolor/128x128/apps
|
|
|
|
)
|
|
|
|
install(FILES icons/172x172/harbour-sailfin.png
|
|
|
|
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"
|
|
|
|
"${CMAKE_INSTALL_PREFIX}
|
2021-02-20 22:20:39 +00:00
|
|
|
${CMAKE_BINARY_DIR}/sailfish/harbour-sailfin:bin
|
2020-10-26 21:29:07 +00:00
|
|
|
")
|