CMake: Linux: update dependencies & use dynamic Boost (#864)

This commit is contained in:
Conn O'Griofa 2023-01-31 02:29:44 +00:00 committed by GitHub
parent 98d61b16f6
commit fb7c9e22ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 21 additions and 18 deletions

View File

@ -72,10 +72,8 @@ find_package(OpenSSL REQUIRED)
find_package(PkgConfig REQUIRED) find_package(PkgConfig REQUIRED)
pkg_check_modules(CURL REQUIRED libcurl) pkg_check_modules(CURL REQUIRED libcurl)
if(NOT APPLE)
set(Boost_USE_STATIC_LIBS ON) # cmake-lint: disable=C0103
endif()
if(WIN32) if(WIN32)
set(Boost_USE_STATIC_LIBS ON) # cmake-lint: disable=C0103
# workaround to prevent link errors against icudata, icui18n # workaround to prevent link errors against icudata, icui18n
set(Boost_NO_BOOST_CMAKE ON) # cmake-lint: disable=C0103 set(Boost_NO_BOOST_CMAKE ON) # cmake-lint: disable=C0103
endif() endif()
@ -380,6 +378,7 @@ ${CMAKE_BINARY_DIR}/generated-src/${filename}.h")
third-party/glad/include/glad/egl.h) third-party/glad/include/glad/egl.h)
list(APPEND PLATFORM_LIBRARIES list(APPEND PLATFORM_LIBRARIES
Boost::dynamic_linking
dl dl
evdev evdev
numa numa
@ -795,25 +794,33 @@ elseif(UNIX)
libcurl4, \ libcurl4, \
libdrm2, \ libdrm2, \
libevdev2, \ libevdev2, \
libmfx1, \
libnuma1, \
libopus0, \ libopus0, \
libpulse0, \ libpulse0, \
libxcb-shm0, \ libva2, \
libxcb-xfixes0, \ libva-drm2, \
libxtst6, \ libvdpau1, \
openssl") libwayland-client0, \
libx11-6, \
openssl | libssl3")
set(CPACK_RPM_PACKAGE_REQUIRES "\ set(CPACK_RPM_PACKAGE_REQUIRES "\
boost-filesystem >= 1.67.0, \ boost-filesystem >= 1.67.0, \
boost-log >= 1.67.0, \ boost-log >= 1.67.0, \
boost-program-options >= 1.67.0, \ boost-program-options >= 1.67.0, \
boost-thread >= 1.67.0, \ boost-thread >= 1.67.0, \
intel-mediasdk >= 22.3.0, \
libcap >= 2.22, \ libcap >= 2.22, \
libcurl >= 7.0, \ libcurl >= 7.0, \
libdrm >= 2.4.97, \ libdrm >= 2.4.97, \
libevdev >= 1.5.6, \ libevdev >= 1.5.6, \
libopusenc >= 0.2.1, \ libopusenc >= 0.2.1, \
libxcb >= 1.13, \ libva >= 2.14.0, \
libXtst >= 1.2.3, \ libvdpau >= 1.5, \
openssl >= 1.1, \ libwayland-client >= 1.20.0, \
libX11 >= 1.7.3.1, \
numactl-libs >= 2.0.14, \
openssl >= 3.0.2, \
pulseaudio-libs >= 10.0") pulseaudio-libs >= 10.0")
# This should automatically figure out dependencies, doesn't work with the current config # This should automatically figure out dependencies, doesn't work with the current config
set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS OFF) set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS OFF)

View File

@ -20,7 +20,6 @@ dnf -y update
dnf -y group install "Development Tools" dnf -y group install "Development Tools"
dnf -y install \ dnf -y install \
boost-devel-1.76.0* \ boost-devel-1.76.0* \
boost-static-1.76.0* \
cmake-3.22.2* \ cmake-3.22.2* \
gcc-12.0.1* \ gcc-12.0.1* \
gcc-c++-12.0.1* \ gcc-c++-12.0.1* \

View File

@ -20,7 +20,6 @@ dnf -y update
dnf -y group install "Development Tools" dnf -y group install "Development Tools"
dnf -y install \ dnf -y install \
boost-devel-1.78.0* \ boost-devel-1.78.0* \
boost-static-1.78.0* \
cmake-3.24.1* \ cmake-3.24.1* \
gcc-12.2.1* \ gcc-12.2.1* \
gcc-c++-12.2.1* \ gcc-c++-12.2.1* \

View File

@ -28,7 +28,7 @@ apt-get install -y --no-install-recommends \
libboost-thread-dev=1.74.0* \ libboost-thread-dev=1.74.0* \
libcap-dev=1:2.44* \ libcap-dev=1:2.44* \
libcurl4-openssl-dev=7.81.0* \ libcurl4-openssl-dev=7.81.0* \
libdrm-dev=2.4.110* \ libdrm-dev=2.4.113* \
libevdev-dev=1.12.1* \ libevdev-dev=1.12.1* \
libnuma-dev=2.0.14* \ libnuma-dev=2.0.14* \
libopus-dev=1.3.1* \ libopus-dev=1.3.1* \

View File

@ -54,10 +54,10 @@ Install Requirements
sudo dnf group install "Development Tools" && \ sudo dnf group install "Development Tools" && \
sudo dnf install \ sudo dnf install \
boost-devel \ boost-devel \
boost-static \
cmake \ cmake \
gcc \ gcc \
gcc-c++ \ gcc-c++ \
intel-mediasdk-devel \ # x86_64 only
libcap-devel \ libcap-devel \
libcurl-devel \ libcurl-devel \
libdrm-devel \ libdrm-devel \
@ -80,9 +80,7 @@ Install Requirements
pulseaudio-libs-devel \ pulseaudio-libs-devel \
rpm-build \ # if you want to build an RPM binary package rpm-build \ # if you want to build an RPM binary package
wget \ # necessary for cuda install with `run` file wget \ # necessary for cuda install with `run` file
which \ # 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
Ubuntu 20.04 Ubuntu 20.04
^^^^^^^^^^^^ ^^^^^^^^^^^^

View File

@ -34,7 +34,7 @@ modules:
build-commands: build-commands:
- cd tools/build && bison -y -d -o src/engine/jamgram.cpp src/engine/jamgram.y - 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 - ./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 -j $FLATPAK_BUILDER_N_JOBS
sources: sources:
- type: archive - type: archive