Commit Graph

72 Commits (fddbbe259da6091086d457666241a13d3e9c3e23)

Author SHA1 Message Date
Colin Edwards 35088e0d9e libobs: Add sample unit tests leveraging cmocka 2020-06-25 15:21:58 -07:00
Jim 0d7b4e1ced
Merge pull request #3006 from mr-c/simde_20200529
libos: Freshen SIMDe code copy
2020-06-21 05:34:38 -07:00
Joel Bethke e10d3be804 cmake: Update minimum Windows SDK version 2020-06-03 17:06:31 -05:00
Michael R. Crusoe 3778086f04
cmake: SIMDe & GCC? then enable OpenMP 4 SIMD
There is no run time library required with -fopenmp-simd
2020-05-29 12:37:21 +02:00
jp9000 7993179466 cmake: Add cmake folders 2020-05-13 06:52:37 -07:00
Colin Edwards 55e2985026
Merge pull request #1944 from WizardCM/windows-rc-definition
CMake: Build Windows modules with file descriptors
2020-04-18 18:27:22 -05:00
jpark37 f3e6bfdc59 CMake: Disable incremental linking on Windows
Not compatible with /OPT:REF, and caused warnings.
2020-03-03 23:13:03 -08:00
jpark37 9abdf2eec7 CMake: Enable /OPT:REF for Windows 2020-03-03 20:18:43 -08:00
jp9000 cc5918fdb4 CMake: Add check for Win SDK 10.0.18362.0 or above
The graphics capture changes require Windows SDK version 10.0.18362.0 or
above to function, so check for that in CMake.
2020-02-22 21:02:33 -08:00
jp9000 039c08144a CMake: Rquire CMake 3.16
The recent graphics capture changes require CMake 3.16 or above to
function on Windows, so add a requirement check for 3.16 if on Windows.
2020-02-22 21:02:33 -08:00
jpark37 d6d27cfab1 libobs-winrt: Add module for WinRT functionality
Currently wraps Windows Graphics Capture API.
2020-02-22 21:02:33 -08:00
Jiaxun Yang 6366f6ab59 libobs: Build SIMDE on platforms without SSE2
SIMDE was introduced for aarch64 support, however, the library itself
supports non-SIMD fallback, which allows us provide support to other
platforms without code changes.

There is another world beyond x86. So we can simply enable SIMDE for
processors without SSE2 support.

Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
2020-01-22 15:41:15 +08:00
pkubaj 03ab727495 CMake: Fix build on ppc64
ppc64le was fixed before, but ppc64 (big-endian) was still failing.
2020-01-04 02:19:38 -08:00
jpark37 45d95282df cmake: Use C++17 for compilation
WinRT language projection requires C++17 to compile, which will be used
to incorporate Windows 10 features like ScreenCapture.
2019-10-15 21:08:45 -07:00
Matt Gajownik 51be039cf8 CMake: Build Windows modules with file descriptors 2019-10-15 21:34:12 +11:00
Florian Zwoch 9799a99238 cmake: no -Werror-implicit-function-declaration for C++
This flag was ignored for C++. Starting with GCC-9 this
flag is complained about.
2019-09-14 10:23:34 +02:00
SCG82 596dd54c0b cmake: Fix typo 2019-07-21 19:49:41 -07:00
Michael Fabian 'Xaymar' Dirks 8b346ade64 cmake: Generate obs.rc out-of-tree
Fixes the `obs.rc` file appearing in the UI source tree and moves it
into the out-of-tree build directories provided by CMake. Projects
requiring this can use it by adding `${obs-studio_BINARY_DIR}/obs.rc`
to their source list.
2019-04-06 15:35:08 +02:00
Matt Gajownik 4b9d050b33 UI: Automatically generate Windows file description
This defines the main OBS Windows executable with a resource file,
including a version number accessible externally and a File
description which appears in Windows Task Manager.
2019-02-02 11:22:31 +11:00
Colin Edwards cac03e3d76
cmake: Use multiprocessor compilation on Windows (#1605) 2019-01-30 22:57:42 -06:00
J Lynn 36a6629e6b Add support for building on PPC64LE using x86 Intrinsic Compat Shim 2018-12-17 05:33:16 +11:00
jp9000 cb4d2ff7fa cmake: Find Qt first before going to subdirectories 2018-09-18 10:03:07 -07:00
jp9000 8b936a1575 cmake: Fix UI being dependent on browser plugin files
The UI currently is dependent on browser source files being present,
when in actuality the files may not have been fetched (i.e. not fetching
submodules).  This fixes that by using a macro to detect whether it's
available or not.

Closes obsproject/obs-studio#1490
2018-09-18 08:56:34 -07:00
Shaolin ddd145797c cmake: Add variable-length array checks
VLA are more complex thus generating much more code. Alternatives can
be used when VLA are needed.

See: https://outflux.net/slides/2018/lss/danger.pdf - Pages 6, 7 and 8
2018-09-03 17:39:22 -03:00
Jim 329efe4024
Merge pull request #1414 from admshao/remove-cmp0072-warning
cmake: Prevent policy CMP0072 warning
2018-08-17 15:05:06 -07:00
jp9000 e3c2202791 cmake: Add release candidate versions/cmake variables
Allows specifying a release candidate version, and outputs release
candidate version variables to libobs/obs-config.h.  Useful for using
cmake to specify a release candidate version.
2018-08-13 01:19:23 -07:00
Shaolin 3f23c1ca7b cmake: Prevent policy CMP0072 warning
This policy was introduced in CMake version 3.11.

The FindOpenGL module provides an OpenGL::GL target and an
OPENGL_LIBRARIES variable for projects to use for legacy GL interfaces.
When both a legacy GL library (e.g. libGL.so) and GLVND libraries for
OpenGL and GLX (e.g. libOpenGL.so and libGLX.so) are available, the
module must choose between them. It documents an OpenGL_GL_PREFERENCE
variable that can be used to specify an explicit preference. When no
such preference is set, the module must choose a default preference.

The default behavior is to default to legacy (OLD) and is deprecated.

https://cmake.org/cmake/help/v3.11/policy/CMP0072.html
https://github.com/NVIDIA/libglvnd
2018-08-07 20:22:00 -03:00
jp9000 4b54bde426 cmake, libobs, win-capture: Fix VS2017 warnings 2018-03-12 16:16:38 -07:00
jp9000 dce311cf1a deps/obs-scripting: Make ENABLE_SCRIPTING a user variable
Makes it so that the scripting cmake variable ENABLE_SCRIPTING is a user
variable rather than a global internal cmake variable, and defers the
internal global cmake variable to SCRIPTING_ENABLED instead.
2018-01-23 20:57:48 -08:00
jp9000 9eabfdbf1e deps/obs-scripting: Add scripting support
Allows Lua/Python scripting support.
2018-01-04 11:37:42 -08:00
jp9000 260fb571b8 UI: Set ENABLE_UI and DISABLE_UI as root CMake variables
Allows for projects other than UI to be able to reference these CMake
variables.
2018-01-03 17:04:03 -08:00
jp9000 5c2328cca2 cmake: Add _CRT_NONSTDC_NO_WARNINGS def to all projects 2017-06-27 09:55:51 -07:00
jp9000 4f7ea15f42 Add libcaption library
Manually merging/squashing from: https://github.com/szatmary/libcaption
2016-12-23 10:37:06 -08:00
jp9000 ca607f8b35 cmake: Add _CRT_SECURE_NO_WARNINGS to all projects
This prevents issues with using standard C functions, where microsoft
would otherwise spit out pointless warnings to encourage using
microsoft-specific functions instead.
2016-12-08 03:27:36 -08:00
CoDEmanX 2680321860 CMake: Warn if empty QTDIR/DepsPath vars on Windows
Closes jp9000/obs-studio#608
2016-10-09 19:32:58 -07:00
jp9000 01b274f1da UI: Rename 'obs' dir to 'UI'
This is to prevent confusion both when prefixing commits and when
reading the directory structure for the first time.
2016-08-27 20:19:45 -07:00
Timo Gurr 187e974375 cmake: Allow installing arch-independent data outside prefix
This allows installing the architecture independent data outside the
prefix, for example on a multiarch layout where the prefix is
/usr/{host-triplet}.

Closes jp9000/obs-studio#552
2016-06-27 18:20:57 -07:00
jp9000 a60189d429 cmake: Remove libobs-d3d9 2015-09-11 22:01:26 -07:00
Carl Fürstenberg ba02e065fe libobs: Add XDG config directory support
Adding XDG Base Directory Specification support for config dir

http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html

Closes jp9000/obs-studio#348
2015-07-08 09:10:53 -07:00
Palana a14d003955 Expose BUILD_TESTS as (advanced) CMake option
This makes it easier to set BUILD_TESTS (introduced in
87ea0392b4) from ccmake/cmake-gui
2015-05-22 00:24:48 +02:00
John Bradley 87ea0392b4 Only build tests if specified by BUILD_TESTS 2015-05-12 11:40:09 -05:00
jp9000 ee31962b85 Add CMake module to parse IDL files on Windows 2015-03-21 16:34:46 -07:00
jp9000 f9d4a957c1 Disable -Wmissing-braces
This warning is somewhat insignificant for most of what we do; just
warns about missing braces for sub-structures, but most of the time it
wrongly triggers on = {0}, which is a standard way of initializing a
structure to 0 in C.
2015-02-09 03:48:25 -08:00
martell c83a95983b cmake: set windows version to vista on mingw-w64
mingw-w64 defaults to xp, so when building we set it to vista because
function CancelIoEx is used in ipc-util/pipe-windows.c.

http://msdn.microsoft.com/en-us/library/windows/desktop/aa363792.aspx
2015-02-08 06:41:08 -08:00
Carl Fürstenberg 6095e7ef51 Add SOVERSION to libobs-opengl
Because libobs-opengl is a public library, it's customary to have SONAME
embedded in the library file.  Also remove the prefix override and
remove the prefixing "lib" from the output name.  This also requires us
to pass the library file name to dlopen invocations.
2015-01-13 17:51:38 -08:00
BtbN aeab5c35ef Disable safeseh on 32bit builds 2014-09-16 10:37:08 +02:00
jp9000 85701b0925 Allow copying of all dependencies (windows only)
If the cmake user variable COPY_DEPENDENCIES is set, this script will
make it so that a windows build will automatically copy all required
dependencies (FFmpeg, x264, and Qt5) to the respective
additional_install_files\exec(32|64) directory.  This makes it much
easier to set up a development environment on windows, and much easier
to make usable test builds.

It will also copy the appropriate Direct3D compiler DLL, along with
dependencies of dependencies (the icu*.dll and EGL/GLES files for Qt)
2014-07-18 22:41:22 -07:00
BtbN 415a698bac Add support for build time dependency copying 2014-07-19 01:38:42 +02:00
BtbN 973435cb52 Move config include path, so it works for the exported target 2014-07-17 21:32:31 +02:00
BtbN 1099f8e96f Don't build with install rpath on unix 2014-07-10 14:38:53 +02:00