Commit graph

260 commits

Author SHA1 Message Date
Paul Hindt 182410cf6c aja: Prepare plugins for new libajantv2 repo
Support building AJA plugins with either the new libajantv2 library, or
the deprecated ntv2 library.

Finder scripts updated to search for libajantv2 and fall back to ntv2 if
not found. This allows this PR to be merged without requiring a
corresponding update to the pre-built obs-deps packages.
2024-05-02 14:31:16 -04:00
PatTheMav 0af0de26eb libobs: Add changes for CMake build framework 3.0
New code path only taken if OBS_CMAKE_VERSION is set to 3.0.0 or
greater, old functionality remains unchanged.
2024-04-13 23:48:38 -04:00
tytan652 cebc828cb8 cmake: Add finder for uthash 2024-04-07 10:01:25 +10:00
Aleks Todorov 80ad63a6da cmake: Provide a clear error on version check fail
Currently, when git describe fails to get a git tag for the OBS Version,
a non-fatal message is printed, and the generator is left to continue,
usually ending up with a more cryptic error message down the line.

Instead, print the git output together with a short description of what
actually happened, and exit fatally so the problematic line of code is
clear. An added advantage is that the git output is printed in red
instead of (say) white on color-enabled terminals.
2024-04-04 15:13:43 -04:00
derrod 98ee9c987e cmake: Add HANDLE_VERSION_RANGE to FFnvcodec finders 2024-03-31 02:05:40 -07:00
Azamat H. Hackimov d9b3969bc5 Add CheckSymbolExists module for FindMbedTLS.cmake
FindMbedTLS.cmake uses `check_symbol_exists` macro which requires
`include(CheckSymbolExists)` before invocation (see
https://cmake.org/cmake/help/latest/module/CheckSymbolExists.html).

Signed-off-by: Azamat H. Hackimov <azamat.hackimov@gmail.com>
2024-01-29 16:57:15 -05:00
tytan652 7c2b39436b cmake: Skip PDB install for interface target 2024-01-28 11:00:01 +11:00
tytan652 cdca983733 cmake: Skip generate export header if interface in legacy path
It backports a behavior from CMake 3.0 to CMake 2.0
2024-01-28 11:00:01 +11:00
Kurt Kartaltepe 9b98686c31 cmake: Depend entirely on pkg-config if found for VPL
Released versions of VPL have a pkg-config that orders dependencies
before the main VPL library. This causes our library searching with
pkg-config hints to instead search for the first dependency of VPL.

Instead just import the pkg-config definition directly and use it. This
is a bit more correct as all the dependencies will be correctly linked.

Also install the library since the debian package doesnt seem to depend
on the library itself...

fixes #9573
2023-10-09 11:53:59 -04:00
PatTheMav b3949e6aef cmake: Update qrcodegen finder to match target names of CMake package
qrcodegen is built on obs-deps for macOS and Windows, with the
generated CMake package calling the dependency qrcodegen (not
libqrcoden) and associated target qrcodegen::qrcodegen.

This change updates the finder (required for Linux) to create the same
targets so consumers do not need to differentiate between different
variations of the same dependency on Linux.

Also updates obs-websocket to 5.3.1 to bring in associated CMake
changes.
2023-09-27 18:05:02 -04:00
Kurt Kartaltepe 368082d6c0 obs-qsv11: Use device enumeration for choosing DRM device
Trying to use the display server as the QSV device was found to be
generally wrong in beta, so instead lets save defaults from the earlier
device enumeration similar to obs-ffmpeg-vaapi which is known to work
well.
2023-08-26 16:40:46 -07:00
Kurt Kartaltepe b6b8f5b80a obs-qsv11: Fix VPL initialization on intel-mediaSDK
VPL does not have a consistent initialization process for the various
backends it dispatches to. So this resolves the new VPL dispatcher
failing to initialize the video session when it dispatches to
intel-mediaSDK backend. On the oneVPL-intel-gpu backend VA-API sessions
are correctly initialized so this wasnt noticed when tested on newer
hardware.
2023-08-16 15:40:02 -04:00
Gale dbbbcd8c57 obs-qsv11: Add VPL changes 2023-08-07 13:23:26 -04:00
pkv ce6a17e979 cmake: Copy libdatachannel DLL
Copy libdatachannel DLL whether it's compiled on MSVC (and named
datachannel.dll) or cross-compiled on MinGW (and named
libdatachannel.dll).

Signed-off-by: pkv <pkv@obsproject.com>
2023-07-20 10:28:11 -04:00
gxalpha 9d611a064f cmake: Remove Qt version selection and Qt 5 support 2023-07-19 11:56:54 -04:00
tytan652 d76de77abb cmake: Add finder for Libqrcodengencpp 2023-07-14 15:32:04 -04:00
Kurt Kartaltepe c6b470de9a obs-qsv11: Add a Linux implementation
This adds a CMake module for finding the QSV SDK (libmfx/onevpl) and an
the required platform components to initialize QSV with the VA-API
platform.
2023-07-14 12:19:33 -04:00
Sean DuBois 19a297f81a CI: Update deps to 2023-06-01 release
Notable changes:
 * deps.ffmpeg: Add libdatachannel
 * deps.macos: Add Syphon Framework

Library added to support WHIP (WebRTC) output.
2023-06-09 20:20:49 -05:00
Lain 106c7aa61f Update copyrights/names 2023-05-20 01:31:18 -07:00
tytan652 6e887f8158 obs-ffmpeg,cmake: Replace external folder by obs-deps headers 2023-05-13 17:06:39 -07:00
tytan652 12ad59f31f cmake: Enforce -Wmaybe-uninitialized to never turn into an error 2023-05-05 16:46:59 -04:00
derrod 90b8e3585e cmake: Set C11 for CMake < 3.21 2023-04-17 14:55:44 -04:00
derrod 35d42f77d6 cmake: Set C standard to ISO C17
- Sets CMAKE_C_STANDARD to 17
- Disables C extensions (e.g. gnu17) to force ISO C on macOS/Windows
- Fixes language properties in cmake 3.0 not being set correctly
- Sets Xcode attributes to c17
2023-04-08 19:30:12 -04:00
PatTheMav 349372b3b3 cmake: Add changes for CMake build framework 3.0
New code path only taken if OBS_CMAKE_VERSION is set to 3.0.0 or
greater, old functionality remains unchanged.
2023-03-26 18:20:38 -04:00
PatTheMav ae6e9c875b cmake: Add OBS CMake build framework 3.0
OBS CMake build framework 3.0 is a minor overhaul of version 2.0. Due
to close proximity of the 2.0 rework, the amount of actual changes to
project files are minimal and mostly concern application generation.

This commit contains the bootstrap elements only and requires
OS-specific implementations to be functional.
2023-03-26 18:20:38 -04:00
tytan652 8c11b0caad cmake: Add finders for Asio and WebSocket++
WebSocket++ does provide a CMake package, but version check is broken.
2023-03-20 19:00:24 -04:00
derrod 11f88af880 cmake: Add libuuid finder 2023-03-12 01:11:38 +01:00
derrod f06b2ccf55 cmake: Set PDBALTPATH manually 2023-03-07 18:13:24 -05:00
derrod d2f0dfa341 cmake: Set /Brepro compiler/linker options 2023-03-07 18:13:24 -05:00
tytan652 f4e90a5bd7 obs-ffmpeg,cmake: Add a finder for AMF headers 2023-03-07 14:55:03 -05:00
derrod b7f6ae7d7b cmake: Enable stricter MSVC compiler options 2023-03-01 20:39:53 +01:00
Ryan Foster 2b84155da4 cmake: Remove FindRSSDK
Follow-up to PR #7371 (commit a1a98f9cfd).

We forgot to remove the Finder that was only used for that plugin. Let's
remove it now.
2023-03-01 18:16:34 +01:00
derrod 77e4c1c305 cmake: Check if Sparkle options are non-empty 2023-02-27 13:06:26 -05:00
derrod 9d71d2f7fd cmake: Remove ENABLE_SPARKLE_UPDATER option
Since public key and appcast are now options we simply rely on those to
decide whether or not to enable Sparkle.
2023-02-19 01:35:56 +01:00
derrod 634fd3231c CI/cmake: Update Sparkle to 2.3.2 2023-02-19 01:35:56 +01:00
tytan652 d7fade2c44 cmake: Allow disabling deprecation errors on GCC/Clang 2023-01-28 23:20:41 -08:00
tytan652 ee144377dc cmake,obs-ffmpeg: Refactor Libva finder
This refactor adds Libva DRM, required for obs-ffmpeg
2023-01-25 13:14:41 -05:00
tytan652 aa97b7f1f1 cmake: Add workaround for GCC 12.1.0
Freedesktop Flatpaks 22.08 provide this version of GCC.
2023-01-19 13:08:46 -05:00
tytan652 541b3292e9 cmake: Add workaround for GCC on aarch64
GCC on aarch64 seems to found type-limits issue in the code where GCC
x86_64 does not.
2023-01-19 13:08:46 -05:00
tytan652 189c6939d1 cmake: Treat warnings as errors on Clang and GCC
-Wformat-security is enabled, some Linux packages build system have it
enabled.
https://github.com/obsproject/obs-studio/pull/5766

-Wunused-parameter is enabled too.

Also ensure that null conversion (C++ only for GCC) is enabled because its
enablement by default can depend on the CMake generator.

-Wswitch is enabled but it is kept as a warning. It was already enabled
with Clang.

If Clang has -Wshorten-64-to-32 enabled, keep it as warnings.
2023-01-19 13:08:46 -05:00
Timo Gurr ad034bac0e cmake: Fix FindGio.cmake to find libgio
Find actual libgio-2.0.so instead of libgobject-2.0.so.
2022-12-05 14:22:14 -05:00
derrod cdc9313829 cmake/libobs: Set OBS_COMMIT based on git describe 2022-11-22 02:54:07 +01:00
Richard Stanway 510f0116a6 cmake: Specify utf-8 for MSVC builds
If there is no BOM, MSVC defaults to the user's code page which can
result in errors if UTF-8 characters are present in the source files.
2022-11-20 17:38:23 -05:00
tytan652 74b245431c obs-ffmpeg: Use Libva in FFmpeg VA-API
Libva is directly used to check if DRI devices support H264 encoding.
2022-11-20 11:30:40 +11:00
PatTheMav 358d706e38 cmake: Fix debian packages loosing all debug symbols
The correct way to build debian package and also provide debug symbols
is to use additional `ddeb` packages served with the original `deb`
package.

This will implicitly still strip the binaries contained in the `deb`
package (per convention) but also create a `.ddeb` package with the
stripped symbols.
2022-11-12 18:20:50 -05:00
PatTheMav 2c8a55f82b cmake: Fix rundir installation accepting DESTDIR environment variable
The environment variable DESTDIR is commonly used to specify an install-
time prefix for installation of build artifacts (e.g. for staging an
installation in a temporary directory while keeping the overall prefixes
intact).

This variable should be ignored by all targets but the install target,
which requires us to set it to an empty string/path when we use
`install` to set up our rundir.
2022-09-17 16:15:56 -07:00
PatTheMav e64b1117fc cmake: Fix CMake package files not being installed on FreeBSD
By default libraries and their CMake package files should be installed
on Linux and FreeBSD and omitted on Windows. This explicitly adds
FreeBSD.
2022-09-17 16:12:01 -07:00
derrod db766273b6 cmake: Fix Sparkle framework permissions 2022-09-06 01:49:46 +02:00
PatTheMav b81ab5a32b UI: Fix small font size on macOS and fallback font
Qt uses a default font size of 13pt for QWidgets on macOS. By setting
the default font size to 10pt, text becomes too small for comfortable
use on macOS.

This PR patches the font files copied into the macOS bundle to use a
larger font-size of 12pt. It also sets the fallback font to the more
modern SF Display-based `.AppleSystemUIFont` used by default in macOS
if Open Sans is not found.
2022-08-25 18:02:22 +02:00
derrod d1a1a2c060 cmake: Set RELEASE_CANDIDATE/BETA based on git describe 2022-08-22 14:55:27 +02:00