From fb7c9e22ff3885c2dbd3ba03855999525c9d6560 Mon Sep 17 00:00:00 2001 From: Conn O'Griofa Date: Tue, 31 Jan 2023 02:29:44 +0000 Subject: [PATCH 1/4] CMake: Linux: update dependencies & use dynamic Boost (#864) --- CMakeLists.txt | 27 ++++++++++++------- docker/fedora-36.dockerfile | 1 - docker/fedora-37.dockerfile | 1 - docker/ubuntu-22.04.dockerfile | 2 +- docs/source/building/linux.rst | 6 ++--- .../linux/flatpak/dev.lizardbyte.sunshine.yml | 2 +- 6 files changed, 21 insertions(+), 18 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 62b72fcc2d9..e5312545e6b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -72,10 +72,8 @@ find_package(OpenSSL REQUIRED) find_package(PkgConfig REQUIRED) pkg_check_modules(CURL REQUIRED libcurl) -if(NOT APPLE) - set(Boost_USE_STATIC_LIBS ON) # cmake-lint: disable=C0103 -endif() if(WIN32) + set(Boost_USE_STATIC_LIBS ON) # cmake-lint: disable=C0103 # workaround to prevent link errors against icudata, icui18n set(Boost_NO_BOOST_CMAKE ON) # cmake-lint: disable=C0103 endif() @@ -380,6 +378,7 @@ ${CMAKE_BINARY_DIR}/generated-src/${filename}.h") third-party/glad/include/glad/egl.h) list(APPEND PLATFORM_LIBRARIES + Boost::dynamic_linking dl evdev numa @@ -795,25 +794,33 @@ elseif(UNIX) libcurl4, \ libdrm2, \ libevdev2, \ + libmfx1, \ + libnuma1, \ libopus0, \ libpulse0, \ - libxcb-shm0, \ - libxcb-xfixes0, \ - libxtst6, \ - openssl") + libva2, \ + libva-drm2, \ + libvdpau1, \ + libwayland-client0, \ + libx11-6, \ + openssl | libssl3") set(CPACK_RPM_PACKAGE_REQUIRES "\ boost-filesystem >= 1.67.0, \ boost-log >= 1.67.0, \ boost-program-options >= 1.67.0, \ boost-thread >= 1.67.0, \ + intel-mediasdk >= 22.3.0, \ libcap >= 2.22, \ libcurl >= 7.0, \ libdrm >= 2.4.97, \ libevdev >= 1.5.6, \ libopusenc >= 0.2.1, \ - libxcb >= 1.13, \ - libXtst >= 1.2.3, \ - openssl >= 1.1, \ + libva >= 2.14.0, \ + libvdpau >= 1.5, \ + libwayland-client >= 1.20.0, \ + libX11 >= 1.7.3.1, \ + numactl-libs >= 2.0.14, \ + openssl >= 3.0.2, \ pulseaudio-libs >= 10.0") # This should automatically figure out dependencies, doesn't work with the current config set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS OFF) diff --git a/docker/fedora-36.dockerfile b/docker/fedora-36.dockerfile index 30c215f89d5..3c1e728c8f9 100644 --- a/docker/fedora-36.dockerfile +++ b/docker/fedora-36.dockerfile @@ -20,7 +20,6 @@ dnf -y update dnf -y group install "Development Tools" dnf -y install \ boost-devel-1.76.0* \ - boost-static-1.76.0* \ cmake-3.22.2* \ gcc-12.0.1* \ gcc-c++-12.0.1* \ diff --git a/docker/fedora-37.dockerfile b/docker/fedora-37.dockerfile index f71837a1c24..547282b5a9d 100644 --- a/docker/fedora-37.dockerfile +++ b/docker/fedora-37.dockerfile @@ -20,7 +20,6 @@ dnf -y update dnf -y group install "Development Tools" dnf -y install \ boost-devel-1.78.0* \ - boost-static-1.78.0* \ cmake-3.24.1* \ gcc-12.2.1* \ gcc-c++-12.2.1* \ diff --git a/docker/ubuntu-22.04.dockerfile b/docker/ubuntu-22.04.dockerfile index d2a85be4d59..a5ef3fd2b6b 100644 --- a/docker/ubuntu-22.04.dockerfile +++ b/docker/ubuntu-22.04.dockerfile @@ -28,7 +28,7 @@ apt-get install -y --no-install-recommends \ libboost-thread-dev=1.74.0* \ libcap-dev=1:2.44* \ libcurl4-openssl-dev=7.81.0* \ - libdrm-dev=2.4.110* \ + libdrm-dev=2.4.113* \ libevdev-dev=1.12.1* \ libnuma-dev=2.0.14* \ libopus-dev=1.3.1* \ diff --git a/docs/source/building/linux.rst b/docs/source/building/linux.rst index 36f48d273a5..2cb4970e90e 100644 --- a/docs/source/building/linux.rst +++ b/docs/source/building/linux.rst @@ -54,10 +54,10 @@ Install Requirements sudo dnf group install "Development Tools" && \ sudo dnf install \ boost-devel \ - boost-static \ cmake \ gcc \ gcc-c++ \ + intel-mediasdk-devel \ # x86_64 only libcap-devel \ libcurl-devel \ libdrm-devel \ @@ -80,9 +80,7 @@ Install Requirements pulseaudio-libs-devel \ rpm-build \ # if you want to build an RPM binary package wget \ # necessary for cuda install with `run` file - which \ # necessary for cuda install with `run` file - # libmfx-devel is not listed for fedora, this is for x86_64 only - https://kojipkgs.fedoraproject.org//packages/libmfx/1.25/4.el8/x86_64/libmfx-devel-1.25-4.el8.x86_64.rpm + which # necessary for cuda install with `run` file Ubuntu 20.04 ^^^^^^^^^^^^ diff --git a/packaging/linux/flatpak/dev.lizardbyte.sunshine.yml b/packaging/linux/flatpak/dev.lizardbyte.sunshine.yml index 1ad23b3e8e7..d7789a7991e 100644 --- a/packaging/linux/flatpak/dev.lizardbyte.sunshine.yml +++ b/packaging/linux/flatpak/dev.lizardbyte.sunshine.yml @@ -34,7 +34,7 @@ modules: build-commands: - cd tools/build && bison -y -d -o src/engine/jamgram.cpp src/engine/jamgram.y - ./bootstrap.sh --prefix=$FLATPAK_DEST --with-libraries=system,thread,log,program_options || cat bootstrap.log - - ./b2 install variant=release link=static,shared runtime-link=shared cxxflags="$CXXFLAGS" linkflags="$LDFLAGS" + - ./b2 install variant=release link=shared runtime-link=shared cxxflags="$CXXFLAGS" linkflags="$LDFLAGS" -j $FLATPAK_BUILDER_N_JOBS sources: - type: archive From cdfcdf2dc7f6a8fdb965af4746beb4f3424d567e Mon Sep 17 00:00:00 2001 From: Conn O'Griofa Date: Tue, 31 Jan 2023 13:39:20 +0000 Subject: [PATCH 2/4] CMake: CPack: set Intel MediaSDK as arch-specfic depend (#868) --- CMakeLists.txt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e5312545e6b..b2252797c73 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -468,6 +468,8 @@ else() else() set(FFMPEG_PREPARED_BINARIES "${CMAKE_CURRENT_SOURCE_DIR}/third-party/ffmpeg-linux-x86_64") list(APPEND FFMPEG_PLATFORM_LIBRARIES mfx) + set(CPACK_DEB_PLATFORM_PACKAGE_DEPENDS "libmfx1,") + set(CPACK_RPM_PLATFORM_PACKAGE_REQUIRES "intel-mediasdk >= 22.3.0,") endif() endif() set(FFMPEG_INCLUDE_DIRS @@ -786,6 +788,7 @@ elseif(UNIX) # Dependencies set(CPACK_DEB_COMPONENT_INSTALL ON) set(CPACK_DEBIAN_PACKAGE_DEPENDS "\ + ${CPACK_DEB_PLATFORM_PACKAGE_DEPENDS} \ libboost-filesystem1.67.0 | libboost-filesystem1.71.0 | libboost-filesystem1.74.0, \ libboost-log1.67.0 | libboost-log1.71.0 | libboost-log1.74.0, \ libboost-program-options1.67.0 | libboost-program-options1.71.0 | libboost-program-options1.74.0, \ @@ -794,7 +797,6 @@ elseif(UNIX) libcurl4, \ libdrm2, \ libevdev2, \ - libmfx1, \ libnuma1, \ libopus0, \ libpulse0, \ @@ -805,11 +807,11 @@ elseif(UNIX) libx11-6, \ openssl | libssl3") set(CPACK_RPM_PACKAGE_REQUIRES "\ + ${CPACK_RPM_PLATFORM_PACKAGE_REQUIRES} \ boost-filesystem >= 1.67.0, \ boost-log >= 1.67.0, \ boost-program-options >= 1.67.0, \ boost-thread >= 1.67.0, \ - intel-mediasdk >= 22.3.0, \ libcap >= 2.22, \ libcurl >= 7.0, \ libdrm >= 2.4.97, \ From 08ac580bc627aba507e93908b0182c1243761038 Mon Sep 17 00:00:00 2001 From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com> Date: Tue, 31 Jan 2023 16:02:16 -0500 Subject: [PATCH 3/4] changelog: v0.18.1 (#873) --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9110aa67058..ace5c51d0d3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## [0.18.1] - 2023-01-31 +### Fixed +- (Linux) Fixed missing dependencies for deb and rpm packages +- (Linux) Use dynamic boost + ## [0.18.0] - 2023-01-29 Attention, this release contains critical security fixes. Please update as soon as possible. Additionally, we are encouraging users to change your Sunshine password, especially if you expose the web UI (i.e. port 47790 by default) @@ -301,3 +306,4 @@ settings. In v0.17.0, games now run under your user account without elevated pri [0.16.0]: https://github.com/LizardByte/Sunshine/releases/tag/v0.16.0 [0.17.0]: https://github.com/LizardByte/Sunshine/releases/tag/v0.17.0 [0.18.0]: https://github.com/LizardByte/Sunshine/releases/tag/v0.18.0 +[0.18.1]: https://github.com/LizardByte/Sunshine/releases/tag/v0.18.1 From 16e278919755b7020ca3192880e43691f423662a Mon Sep 17 00:00:00 2001 From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com> Date: Tue, 31 Jan 2023 16:43:38 -0500 Subject: [PATCH 4/4] cmake: v0.18.1 (#874) --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b2252797c73..1842c6743a3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.18) # `CMAKE_CUDA_ARCHITECTURES` requires 3.18 -project(Sunshine VERSION 0.18.0 +project(Sunshine VERSION 0.18.1 DESCRIPTION "Sunshine is a self-hosted game stream host for Moonlight." HOMEPAGE_URL "https://app.lizardbyte.dev")