1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-09-12 10:25:32 +02:00
Commit Graph

2813 Commits

Author SHA1 Message Date
Diego Biurrun
f54037da8a build: Make x86 assembler commandline-selectable 2017-03-07 08:32:37 +01:00
Diego Biurrun
51411eb7ff build: Special-case handling of SDL CFLAGS
SDL adds some "special" CFLAGS that interfere with building normal
binaries. Capture those CFLAGS separately and avoid adding them to
the general CFLAGS.
2017-03-07 08:32:37 +01:00
Diego Biurrun
003124ebf4 build: Fix logic of clock_gettime() check
We should only check for clock_gettime() if _POSIX_MONOTONIC_CLOCK is
available and do a full link check for clock_gettime() in all cases.
2017-03-07 08:32:37 +01:00
Diego Biurrun
808ef43597 build: Explicitly set 32-bit/64-bit object formats for nasm/yasm
Consistently use object format names with "32" suffix and set object format
to "win64" on Windows x86_64, which fixes assembling with nasm.
2017-03-05 14:38:56 +01:00
Diego Biurrun
5ff3b5cafc build: Add pthreads to list of avutil extralibs
libavutil uses pthreads in the buffer code (abstracted through a header).
2017-03-01 12:02:11 +01:00
Diego Biurrun
3c0efbd033 build: Allow generating dependencies as a side-effect of assembling 2017-03-01 10:18:15 +01:00
Diego Biurrun
39e208f4d4 build: Generalize yasm/nasm-related variable names
None of them are specific to the YASM assembler.
2017-03-01 10:18:15 +01:00
Diego Biurrun
58407b4d74 configure: Fix typo in objcc default setting
Also drop stray duplicate OBJCC config.mak entry.
2017-03-01 09:23:42 +01:00
Diego Biurrun
7cb1d9e2db build: Fine-grained link-time dependency settings
Previously, all link-time dependencies were added for all libraries,
resulting in bogus link-time dependencies since not all dependencies
are shared across libraries. Also, in some cases like libavutil, not
all dependencies were taken into account, resulting in some cases of
underlinking.

To address all this mess a machinery is added for tracking which
dependency belongs to which library component and then leveraged
to determine correct dependencies for all individual libraries.
2017-03-01 09:00:40 +01:00
Diego Biurrun
d154bdd3d0 configure: Simplify dlopen check 2017-03-01 09:00:40 +01:00
Diego Biurrun
21cca00dfe build: Explicitly disable external libraries when not explicitly enabled
Leaving those variables in an undefined state allows them getting implicitly
enabled when they are declared as weak dependencies of other components.
In that case, the library check is not run and required linker flags are not
added, resulting in a failing build.

Fixes linking when enabling libfreetype without libfontconfig.
2017-02-28 13:00:20 +01:00
Diego Biurrun
7208e5b5d6 configure: Restructure the way check_pkg_config() operates
Have check_pkg_config() enable variables and set cflags and extralibs
instead of relegating that task to require_pkg_config. This simplifies
require_pkg_config(), is consistent with what other helper functions
like check_lib() do and allows getting rid of some manual variable
setting in places where check_pkg_config() is used.
2017-02-20 20:16:05 +01:00
Diego Biurrun
54e39b102e configure: Explicitly spell out first require_pkg_config() parameter
This is less confusing than encountering "" in the argument list.
2017-02-20 20:16:05 +01:00
Diego Biurrun
d00a0d8e84 configure: Handle SDL version check through pkg-config 2017-02-16 09:28:33 +01:00
Diego Biurrun
871b4f3654 configure: Check for xcb as well as xcb-shape before enabling libxcb
Newer versions of libxcb have xcb-foo pkg-config files that do not declare
their xcb dependency so that required linker flags will not be generated.
2017-02-15 10:33:34 +01:00
Luca Barbato
0ee78020cd configure: Move up the avbuild directory creation
The early check for inconsistent in-source vs out-of-source build
cannot generate a config.log otherwise.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2017-02-11 15:47:43 +01:00
Diego Biurrun
c546147db0 configure: Correctly recurse in do_check_deps()
Fixes all sorts of configuration problems introducec by dad7a9c7c0
on non-Linux or non-vanilla configs. Also removes a line made redundant
in that commit.
2017-02-08 21:23:41 +01:00
Diego Biurrun
dad7a9c7c0 configure: Rework dependency handling for conflicting components
This makes the feature more visible and obvious.
2017-02-07 19:06:04 +01:00
Diego Biurrun
9127ac5ebc configure: Add name parameter to require_pkg_config() helper function
This allows distinguishing between the internal variable name for
external libraries and the pkg-config package name. Having both
names available avoids special-casing outside the helper function
when the two identifiers do not match.
2017-02-07 19:06:02 +01:00
Diego Biurrun
71a49fe25f configure: Use cppflags check helper functions where appropriate 2017-02-06 15:43:56 +01:00
Diego Biurrun
0ce3761c78 configure: Add stdlib.h #include to CPPFLAGS check helper functions
This ensures that added CPPFLAGS are validated against libc headers.
2017-02-06 15:43:56 +01:00
Diego Biurrun
bcaedef118 configure: Add require_cpp_condition() convenience function
Simplifies checking for conditions in external library headers and
aborting if said conditions are not met.
2017-02-02 17:49:51 +01:00
Diego Biurrun
aba7fdcc8b configure: Add require_header() convenience function
Simplifies checking for external library headers and aborting if
the external library support was requested, but is not available.
2017-02-02 17:49:51 +01:00
Diego Biurrun
a97563c889 configure: Simplify libxcb check 2017-02-02 17:38:50 +01:00
Diego Biurrun
acfa7a2178 configure: Drop weak dependencies on external libraries for webm muxer
Weak dependencies on external libraries do not obviate having to
explicitly enable these libraries, so the weak dependency does not
simplify the configure command line nor have any real effect.
2017-02-02 14:35:44 +01:00
Diego Biurrun
6698832079 configure: Add proper weak dependency of drawtext filter on libfontconfig 2017-02-02 14:35:44 +01:00
Diego Biurrun
24d5680bbc configure: Simplify inline asm check with appropriate helper function 2017-02-02 14:34:05 +01:00
Diego Biurrun
b3825723dc configure: Merge compiler/libc/os hacks sections 2017-02-02 14:34:05 +01:00
Anton Khirnov
fd9212f2ed Mark some arrays that never change as const. 2017-02-01 10:42:59 +01:00
Diego Biurrun
ab87af4163 configure: Add proper weak dependency of avformat on network 2017-01-31 15:50:20 +01:00
Mark Thompson
ca62236a89 vaapi_encode: Add VP8 support 2017-01-30 23:03:46 +00:00
Diego Biurrun
ba6a49e60b configure: Clean up temporary files on interrupt 2017-01-29 20:17:46 +01:00
Michał Górny
7848982207 configure: Place all temporary files in one separate directory
Place all temporary files within a single, quasi-atomically created
temporary directory rather than relying on unsafe 'mktemp -u'. This
prevents possible race conditions in case two parallel 'mktemp -u' calls
returned the same path. Additionally, it reduces TMPDIR pollution by
keeping all test files in a single subdirectory.

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2017-01-29 20:17:46 +01:00
Mark Thompson
ca6ae3b77a vaapi_encode: Add MPEG-2 support 2017-01-29 13:28:31 +00:00
Diego Biurrun
2bbb5abd87 build: Map -Wall compiler flag to -W3 for MSVC and -Wextra to -W4
These are more appropriate warning level equivalents.
2017-01-26 11:53:02 +01:00
Diego Biurrun
6151e9128c build: Detect blocks C language extension and add it as VDA dependency
Newer versions of OS X use the blocks extension in VDA-related headers.
Some compilers, like current gcc, do not support the blocks extension
and fail to compile code using those headers.
2017-01-26 11:53:02 +01:00
Martin Storsjö
f96d07f4ec configure: Add quotes around a variable which might be empty
If we only have a target compiler but no host compiler, the $type
variable will be empty once.

(Currently we fail to do a cross build if no host compiler is available
due to using the host compiler for processing option lists though.
But despite that, this comparison in configure needs quotes.)

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-01-26 12:41:53 +02:00
Diego Biurrun
9bf262f4c6 configure: Use proper compiler-specific speed flags for hostcc 2017-01-25 13:25:02 +01:00
Diego Biurrun
bf38959a30 configure: Move optflags checks to a more sensible place 2017-01-25 12:01:02 +01:00
Dave Yeo
7ff018c1cb OS/2: Try to commit memory above 1GB
Signed-off-by: Dave Yeo <dave.r.yeo@gmail.com>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2017-01-22 15:21:33 +01:00
Diego Biurrun
ee164727dd configure: Fix typo in incdir variable written to config.sh
This fixes includedir lines in pkg-config files broken after 92db508307.
2016-12-30 14:30:52 +01:00
Janne Grunau
35d1f726eb fate: Add --ignore-tests configure option for omitting specific FATE tests
This can be useful to filter out noise in known-broken scenarios like
miscompilation by legacy compilers and similar.

Originally based on a patch by Diego Biurrun.

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-12-28 18:10:32 +01:00
Diego Biurrun
8a34f36593 build: Add version numbers to "Requires" entries in pkg-config files
The (required) version numbers disappeared after edb4348732.
2016-12-28 17:41:54 +01:00
Diego Biurrun
92db508307 build: Generate pkg-config files from Make and not from configure
This moves work from the configure to the Make stage where it can
be parallelized and ensures that pkgconfig files are updated when
library versions change.

Bug-Id: 449
2016-12-22 12:30:54 +01:00
Diego Biurrun
edb4348732 build: Store library version numbers in .version files
This moves work from the configure to the Make stage where it can
be parallelized and ensures that shared libraries are built with
the right version number in the filename.
2016-12-22 12:17:37 +01:00
Diego Biurrun
11a9320de5 build: Move build-system-related helper files to a separate subdirectory
This unclutters the top-level directory and groups related files together.
2016-12-22 11:07:50 +01:00
Anton Khirnov
ea8b730d8e hevcdec: add a VAAPI hwaccel
Partially based on a patch by Timo Rothenpieler <timo@rothenpieler.org>.
Additional scaling list handling fix by Jun Zhao <mypopydev@gmail.com>.
2016-12-19 08:13:08 +01:00
Diego Biurrun
ee480790c7 build: Add name parameter to check_lib() helper function
This allows enabling or disabling the library-related variables from
within the function instead of doing it manually outside of it.
2016-12-16 13:39:22 +01:00
Diego Biurrun
1faffe7e8f configure: Disentangle vfw32 and user32 lib handling
Check for and link against user32 instead, which also fixes
the missing dependency of dxva2 on user32 with MSVC.
2016-12-16 13:37:33 +01:00
Steve Lhomme
f7174d7ed0 configure: fix linking with MSVC when using --disable-optimizations
Without any optimization flags, MSVC does no dead code elimination (DCE) at
all, even for the most trivial cases. DCE is a prerequisite for building libav
correctly, otherwise there are undefined references to functions for other
architectures and disabled components.

-O1 is the minimal optimization flag for MSVC that does include DCE.
2016-12-16 10:03:21 +01:00