Commit graph

248 commits

Author SHA1 Message Date
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
PatTheMav 6c2860a4ec cmake: Fix missing interface include directory on Framework export
For exported targets `INCLUDES DESTINATION` behaves in a specific way
when running `install`: It sets the `INTERFACE_INCLUDE_DIRECTORY` for
the target (relative to the `INSTALL_PREFIX` when a relative path is
given).

This is not implicitly done by CMake, which resulted in the exported
libobs Framework to miss the variable and as such targets linking to
libobs were not able to find the necessary headers anymore.
2022-08-20 22:02:41 +02:00
PatTheMav f31c1c124b cmake: Update Xcode project generation on macOS
* If a valid team id is provided, automatic code sign management is
  enabled
* Different deployment targets for x86_64 and arm64 are enabled for
  Xcode-based builds
* Codesign identity and code-sign style are set globally
2022-08-10 02:05:27 +02:00
PatTheMav 8e3f19722e cmake: Fix unwanted public header installation on macOS 2022-08-10 02:05:27 +02:00
PatTheMav c6ea39534f cmake: Remove workarounds for legacy obs-browser submodule 2022-08-10 02:05:27 +02:00
PatTheMav 2006092076 cmake: Fix missing header installation for libobs and obs-frontend-api 2022-08-10 02:05:27 +02:00
PatTheMav 61f862d826 cmake: Fix broken pthread detection on Windows with CMake 3.24
Workaround for CMake issue
https://gitlab.kitware.com/cmake/cmake/-/issues/23829
2022-08-08 15:50:42 -07:00
PatTheMav 8db359d060 cmake: Fix plugin RPATH entry on Linux 2022-08-07 04:06:54 +02:00
Ed Maste 39269a7ae9 cmake: fix default version if git describe fails
If the `git describe` command fails we want to fall back to a default
version.  _OBS_DEFAULT_VERSION is not in the same format as the string
returned by `git describe` though.  In the event that the command fails
just use _OBS_DEFAULT_VERSION directly rather than trying to parse it.

Fixes: cmake fails if git is not installed but .git/ exists #6940
2022-08-07 00:51:01 +02:00
Ryan Foster b4e056f39d CI: Use Qt6 by default when available 2022-07-31 13:45:57 -04:00
PatTheMav a70dd4d925 cmake: Remove prefix suppression for scripting plugins.
SWIG uses the prefix target property to prefix generated Python
libraries with an underscore (so that obspython.py is loaded first,
which acts as a shim for the actual _obspython.pyd library on Windows).

Usually the prefix is set to an empty string on Windows (to avoid the
automatic "lib" prefix used by CMake), but this also removed the
necessary underscore prefix required for the Python library.
2022-07-31 17:48:35 +02:00
PatTheMav 018f52bfab cmake: Switch file system used by CPack for disk image to APFS 2022-07-31 12:21:35 +02:00
PatTheMav c9859e5afc cmake: Add informal output of Qt version selected for current build 2022-07-30 18:04:15 +02:00