Update Portfile and...

- Upload Portfile as artifact during builds and releases
- Update assets for cpack packages
This commit is contained in:
ReenigneArcher 2022-05-05 21:05:57 -04:00
parent e6d6d47be1
commit 5135c16bda
4 changed files with 35 additions and 15 deletions

View File

@ -254,6 +254,7 @@ jobs:
# move
mv Sunshine.dmg ../artifacts/sunshine-macos.dmg
mv Sunshine.zip ../artifacts/sunshine-macos.zip
mv Portfile ../artifacts/Portfile
- name: Upload Artifacts
if: ${{ github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' }}

View File

@ -312,7 +312,6 @@ else()
if(NOT DEFINED SUNSHINE_EXECUTABLE_PATH)
set(SUNSHINE_EXECUTABLE_PATH "sunshine")
endif()
configure_file(sunshine.desktop.in sunshine.desktop @ONLY)
configure_file(sunshine.service.in sunshine.service @ONLY)
endif()
@ -448,7 +447,7 @@ endforeach()
target_compile_options(sunshine PRIVATE $<$<COMPILE_LANGUAGE:CXX>:${SUNSHINE_COMPILE_OPTIONS}>;$<$<COMPILE_LANGUAGE:CUDA>:${SUNSHINE_COMPILE_OPTIONS_CUDA};-std=c++17>)
#############
# CPACK
# CPACK / Packaging
####
# Common options
@ -474,6 +473,8 @@ if(WIN32) # see options at: https://cmake.org/cmake/help/latest/cpack_gen/nsis.h
install(DIRECTORY "${SUNSHINE_ASSETS_DIR}/web" DESTINATION "${SUNSHINE_CONFIG_DIR}" COMPONENT web)
install(FILES "${SUNSHINE_ASSETS_DIR}/apps_windows.json" DESTINATION "${SUNSHINE_CONFIG_DIR}" COMPONENT assets)
install(FILES "${SUNSHINE_ASSETS_DIR}/box.png" DESTINATION "${SUNSHINE_CONFIG_DIR}" COMPONENT assets)
install(FILES "${SUNSHINE_ASSETS_DIR}/steam.png" DESTINATION "${SUNSHINE_CONFIG_DIR}" COMPONENT assets)
install(FILES "${SUNSHINE_ASSETS_DIR}/sunshine.conf" DESTINATION "${SUNSHINE_CONFIG_DIR}" COMPONENT assets)
install(DIRECTORY "${SUNSHINE_ASSETS_DIR}/shaders/directx" DESTINATION "${SUNSHINE_CONFIG_DIR}/shaders" COMPONENT assets)
@ -524,6 +525,8 @@ if(APPLE) # TODO: test
set(INSTALL_RUNTIME_DIR "${prefix}/MacOS")
install(DIRECTORY "${SUNSHINE_ASSETS_DIR}/web" DESTINATION "${INSTALL_RUNTIME_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/apps_mac.json" DESTINATION "${INSTALL_RUNTIME_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/box.png" DESTINATION "${INSTALL_RUNTIME_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/sunshine.conf" DESTINATION "${INSTALL_RUNTIME_DIR}")
install(TARGETS sunshine
@ -534,13 +537,18 @@ if(APPLE) # TODO: test
set(CPACK_BUNDLE_NAME "${CMAKE_PROJECT_NAME}")
set(CPACK_BUNDLE_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/assets/Info.plist")
set(CPACK_BUNDLE_ICON "${PROJECT_SOURCE_DIR}/sunshine.icns")
# Portfile
configure_file(Portfile.in Portfile @ONLY)
endif()
if(UNIX AND NOT APPLE)
install(DIRECTORY "${SUNSHINE_ASSETS_DIR}/web" DESTINATION "${SUNSHINE_CONFIG_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/85-sunshine-rules.rules" DESTINATION "/etc/udev/rules.d")
install(FILES "${SUNSHINE_ASSETS_DIR}/apps_linux.json" DESTINATION "${SUNSHINE_CONFIG_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/box.png" DESTINATION "${SUNSHINE_CONFIG_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/steam.png" DESTINATION "${SUNSHINE_CONFIG_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/sunshine.conf" DESTINATION "${SUNSHINE_CONFIG_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/apps_linux.json" DESTINATION "${SUNSHINE_CONFIG_DIR}")
install(FILES "${SUNSHINE_ASSETS_DIR}/85-sunshine-rules.rules" DESTINATION "/etc/udev/rules.d")
install(TARGETS sunshine RUNTIME DESTINATION "/usr/bin")
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/sunshine.service" DESTINATION "/usr/lib/systemd/user")
install(DIRECTORY "${SUNSHINE_ASSETS_DIR}/shaders/opengl" DESTINATION "${SUNSHINE_CONFIG_DIR}/shaders")
@ -560,6 +568,9 @@ if(UNIX AND NOT APPLE)
# Installation destination dir
set(CPACK_SET_DESTDIR true)
set(CMAKE_INSTALL_PREFIX "/etc/sunshine")
# AppImage desktop file
configure_file(sunshine.desktop.in sunshine.desktop @ONLY)
endif()
include(CPack)
include(CPack)

View File

@ -5,25 +5,27 @@ PortGroup cmake 1.1
PortGroup github 1.0
PortGroup boost 1.0
github.setup abusse sunshine macos-dev
version 20220224
github.setup sunshinestream sunshine master
version @PROJECT_VERSION@
revision 1
categories multimedia
license GPL-3
maintainers {sunshinestream @SunshineStream} {outlook.com:anselm.busse}
platforms darwin
license GPL-2
maintainers {outlook.com:anselm.busse}
fetch.type git
post-fetch {
system -W ${worksrcpath} "${git.cmd} submodule update --init --recursive"
}
description Sunshine is a Gamestream host for Moonlight
long_description Sunshine is a Gamestream host for Moonlight
description Sunshine is a Gamestream host for Moonlight.
long_description {*}${description}
homepage https://github.com/SunshineStream/Sunshine
depends_lib port:avahi port:ffmpeg port:libopus
depends_lib port:avahi \
port:ffmpeg \
port:libopus
boost.version 1.76

View File

@ -81,13 +81,19 @@ MacOS
Disk Image File option:
#. Download and install ``sunshine.dmg``
.. Warning:: The Disk Image File is experimental. Limited support will be provided.
Portfile option:
#. Install `MacPorts <https://www.macports.org>`_
#. Download the `Portfile <https://github.com/SunshineStream/Sunshine/blob/master/Portfile>`_ from this repository
to ``/tmp``
#. Download the ``Portfile`` to ``/tmp``
#. In a terminal run ``cd /tmp && sudo port install``
#. The first time you start Sunshine, you will be asked to grant access to screen recording and your microphone.
Standalone option:
#. Download and extract ``sunshine-macos.zip``
.. Warning:: The Standalone package is experimental. Limited support will be provided.
Windows
-------
.. image:: https://img.shields.io/github/issues/sunshinestream/sunshine/os:windows:10?logo=github&style=for-the-badge