Commit Graph

2436 Commits

Author SHA1 Message Date
Diego Biurrun 8267f93635 configure: Set default HOSTCFLAGS/HOSTCPPFLAGS after compiler detection
This prevents the default HOSTCFLAGS from getting clobbered by flags
passed to configure on the command line.
2014-01-22 10:33:04 +01:00
Diego Biurrun dc4d726bab build: Add separate hidden config option for the intrax8 code
This allows for slightly cleaner dependency specification.
2014-01-15 15:23:46 +01:00
Janne Grunau b7b17ed66e aarch64: add cpuflags support for NEON and VFP
NEON and VFP are currently mandatory for all ARMv8 profiles. Both are
handled as extensions as far as cpuflags are concerned. This is
consistent with handling x86_64 which always has SSE2, but still
handles it as an extension.
2014-01-15 12:05:09 +01:00
Janne Grunau 032d4da8af aarch64: configure: set arch dependent features
Stack is always 16 byte aligned and clz, 64bit operations and unaligned
memory access are fast in aarch64 mode on ARMv8.

Signed-off-by: Janne Grunau <janne-libav@jannau.net>
2014-01-14 22:19:27 +01:00
Robert Krüger d8e763fda7 vf_yadif: Relicense from GPL to LGPL
All copyright holders have agreed to the relicensing.
2014-01-14 00:04:59 +01:00
Martin Storsjö 99e2012523 x86/arm: Add clobber tests to libavresample
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-01-13 14:13:27 +02:00
Martin Storsjö 44a0a98f92 arm: Add an option for making sure NEON registers aren't clobbered
This is pretty much based on the same test for XMM registers.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-01-11 00:03:00 +02:00
Maxim Polijakowski e6f0bb6527 ATRAC3+ decoder
Cleanup by Diego Biurrun.

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
2014-01-09 19:33:07 +01:00
Martin Storsjö 9409c9bdbf configure: Disable networking if winsock2.h is available but winsock functions aren't
Previously, if neither of the checks for the closesocket function
succeeded, we still kept winsock2.h and networking in general
enabled.

When targeting the WinRT API subset, the winsock2.h header is
available (making the check for it succeed, giving the impression
that winsock is available), but tests that actually try to use
such a function will fail. In this case, disable the winsock2.h
feature and networking in general, as if the winsock2.h header
test would have failed in the first place.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-01-06 18:55:04 +02:00
Luca Barbato e61b8fa560 configure: Update freetype check to follow upstream
The freetype tutorial suggests to use #include FT_FREETYPE_H.

Bug-Id: 616
2014-01-06 11:44:10 +01:00
Diego Biurrun 52ccc4a0ec configure: Support preprocessor macros as header names
New versions of FreeType have moved the location of their API
header(s) and hide the location behind a macro.

Since the location changes between versions and no other way
to know the location exists, this workaround becomes necessary.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-01-05 11:48:13 +01:00
Diego Biurrun bd0fba8797 configure: Explicitly disable w32threads if the test for it fails
This avoids false positive enabling of w32threads if explicitly
requested on the command line, but dependencies are missing.
2013-12-25 13:00:49 +01:00
Justin Ruggles be7c323176 Add a libwebp encoder 2013-12-21 17:01:42 -05:00
Diego Biurrun 8558595a59 configure: Express atomics/thread deps through the dependency system 2013-12-19 20:53:56 +01:00
Diego Biurrun 11bb5e10c3 build: Define __printf__ to __gnu_printf__ on MinGW*/gcc
This is necessary to avoid GCC assuming MS style printf arguments.
2013-12-16 15:21:42 +01:00
Diego Biurrun 5db4e88ecd configure: Detect Solaris libc in an OpenIndiana/illumos compatible way 2013-12-14 14:09:40 +01:00
Luca Barbato a5a3b398fd configure: Reorder pthreads checks
Some pthreads symbols might be present in libc (as shown on various *BSD)
but not all of them, leading to false positives.

Check for the most common compiler flags before the plain symbol check
to avoid known pitfalls.
2013-12-13 23:53:30 +01:00
Luca Barbato 7cbe1ea9df configure: Move the bz2 and zlib checks below phtreads
There are alternate implementations of those libraries that use pthreads.
2013-12-13 23:53:30 +01:00
Diego Biurrun 7c3388711b configure: Add -D__USE_MINGW_ANSI_STDIO=1 to CPPFLAGS on MinGW32
This enables a more C99-compliant implementation of printf et al.
2013-12-13 16:47:49 +01:00
Diego Biurrun bdc111a162 configure: Detect newer (>=4.1) versions of MinGW32
The MinGW32 project is deprecating its old version macros.
2013-12-13 16:47:49 +01:00
Diego Biurrun a1d7d55247 build: Do not add -g to HOSTCFLAGS
The flag is not unconditionally added to CFLAGS either and the
programs built on the host do not get habitually fed to a debugger.
2013-12-13 16:47:49 +01:00
Diego Biurrun 3bb91a1b5c configure: Add -D__USE_MINGW_ANSI_STDIO=1 to CPPFLAGS on MinGW64
This enables a more POSIX-compliant printf implementation, that
allows using length modifiers like 'z'.
2013-12-11 20:25:28 +01:00
Diego Biurrun 1a5fdf9519 configure: Move log2 dependency declaration to a place it takes effect
It was incorrectly moved in c869fcdeac.
2013-12-10 10:25:12 +01:00
Diego Biurrun 2756516466 configure: Split host and target libc detection 2013-12-09 18:41:37 +01:00
Diego Biurrun c869fcdeac configure: Move toolchain dependency declarations to a more appropriate place 2013-12-09 18:41:13 +01:00
Diego Biurrun d64341e498 configure: Prefix libc-related variables with "libc_"
Simplifies host/target libc detection splitting.
2013-12-09 11:47:43 +01:00
Sean McGovern 61b203ffe6 configure: detect Solaris libc
Add preprocessor flags for API availability as necessary.

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2013-12-09 11:46:44 +01:00
d s f0b234ab9e avformat: AviSynth demuxer rewrite
Directly loads AviSynth through LoadLibrary instead of relying on
Video for Windows, and supports using AvxSynth (via dlopen) to
open scripts on Linux and OS X.

Error messages from AviSynth/AvxSynth are now reported through
av_log and exit, rather than the traditional behavior of generating
an error video that the user would need to watch to diagnose.

The main rewrite was authored by d s <avxsynth.testing@gmail.com>
from the AvxSynth team, with additional contributions by

Oka Motofumi <chikuzen.mo@gmail.com>
Stephen Hutchinson <qyot27@gmail.com>
Diego Biurrun <diego@biurrun.de>
Anton Khirnov <anton@khirnov.net>

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-12-08 21:54:50 +01:00
Diego Biurrun 19c20a0a1a configure: Move adding of compat objects out of libc detection 2013-12-08 21:09:02 +01:00
Diego Biurrun 120797e2ef configure: Separate MinGW32 and MinGW64 libc handling 2013-12-08 01:00:36 +01:00
Diego Biurrun bd8b6185f6 configure: Detect msvcrt libc with a CPP check instead of a link check
Simplifies host/target libc detection splitting.
2013-12-04 11:50:59 -05:00
Diego Biurrun 5ec4673281 configure: Add detected C library and host compiler to informative output 2013-12-04 09:53:58 -05:00
Luca Barbato f058f384a0 configure: Do not use pthread_create to check for pthread
Certain instrumentation addons leads to a false positive in configure
and link failures at the end of the build phase.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-11-30 13:01:35 +01:00
Vittorio Giovara 0673ede985 configure: add strip flags checks
This will check if -wN '..@*' is available and fall back on -x if not;
when none are available, do not run strip at all to prevent removing
functions that might be actually needed.
2013-11-28 15:37:10 +01:00
Andreas Unterweger 10421bcf0a Add an audio transcoding example.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-11-27 09:20:05 +01:00
Diego Biurrun 92f0abb27f build: Check for pod2man instead of perl for manual page generation
Some systems provide Perl without pod2man.
2013-11-26 13:49:06 -08:00
Diego Biurrun 4da3f410d1 configure: Restore doc option to disable building the documentation
Also add appropriate dependency declarations for perl and texi2html.
2013-11-26 13:49:06 -08:00
Diego Biurrun ab81f24ad4 build: Integrate multilibrary examples into the build system
This includes moving libavformat/output-example to doc/examples/output.
2013-11-25 11:57:29 -08:00
Derek Buitenhuis dedfa00107 build: Import makedef script from c99-to-c89
This allows MSVC 2013 and ICL to build with no external
dependencies.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-11-24 19:36:09 +00:00
Diego Biurrun f187557ab4 build: more fine-grained dependencies for documentation build tools
Perl is needed to build the manual pages, texi2html for the HTML pages.
2013-11-23 09:45:06 -08:00
Anton Khirnov 7671dd7cd7 avconv: add support for VDPAU decoding 2013-11-23 11:55:53 +01:00
Martin Storsjö ea9f7173ae configure: Avoid requiring c99wrap for working around msys path issues
Msys is unable to convert unix style absolute paths to windows style
paths when combined with certain multichar MSVC options such as
-Fo<file>. We used to work around this issue by passing them as two
separate parameters separated by a space to c99wrap, which then mapped
them back to the actual parameter format that MSVC uses.

The only paths that actually are an issue are absolute unix style
paths, and the only place such absolute paths are used with the output
arguments (-Fo, -Fe, -Fi, -out:) are for the temp files within configure.

By setting TMPDIR to . for msvc/icl builds, we never need to use
absolute unix style paths for the file output, and we can use the
actual proper form of the file output parameters. This avoids requiring
the c99wrap wrapper for remapping the parameters for cases where the
c99 converter isn't invoked at all (MSVC2013 and ICL).

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-11-21 12:35:24 +02:00
Derek Buitenhuis 03f6d4e0f1 win{32,64}: Hard disable symbol versioning
ICL doesn't return an error on unknown parameters, and will
always pass the symver_gnu_asm test, and since Windows
never has symbol versioning, just always disable it.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-11-19 21:30:13 +00:00
Martin Storsjö fa48be9b95 configure: Don't use symlinks for creating the out of tree makefile
On some platforms (such as msys), symlinks are (poorly) emulated
by simply creating a copy of the file.

This means that when building out of tree, the build tree gets
a copy of the original makefile, which can lead to unintuitive
build errors when the original makefile gets updated later.

Instead simply create a stub makefile which includes the real
one.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-11-19 10:12:58 +02:00
Ronald S. Bultje 72ca830f51 lavc: VP9 decoder
Originally written by Ronald S. Bultje <rsbultje@gmail.com> and
Clément Bœsch <u@pkh.me>

Further contributions by:
Anton Khirnov <anton@khirnov.net>
Diego Biurrun <diego@biurrun.de>
Luca Barbato <lu_zero@gentoo.org>
Martin Storsjö <martin@martin.st>

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-11-15 10:16:28 +01:00
Martin Storsjö 16381923fb configure: Check whether MSVC requires using the C89-to-C99 converter
MSVC does support enough of C99 to work without the converter since
the 2013 version. Try to detect which version of the compiler in
the path needs to run the C99 converter or not. When the converter
is omitted, compilation time is reduced quite drastically.

Prior to this, users could still use --cc="c99conv -noconv cl"
when running MSVC 2013 to achieve the same.

This checks the version number instead of doing a normal compile
test, since this check needs to be done earlier in configure, before
the normal compile test helpers are usable.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-11-13 20:55:11 +02:00
Diego Biurrun 0338c39698 dsputil: Split off H.263 bits into their own H263DSPContext 2013-11-08 12:40:47 +01:00
Diego Biurrun 92352a94c1 configure: Move -Wno-maybe-uninitialized check into gcc section
As another example of bizarre compiler behavior clang groks the
-Wmaybe-uninitialized option, but not -Wno-maybe-uninitialized
and spews a warning for every file that gets compiled.
2013-11-05 12:22:48 +01:00
Martin Storsjö 435214a757 Add an HDS live fragmenting muxer
HDS fragments basically are FLV fragments wrapped in an ISO
media mdat atom.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-11-02 10:51:00 +02:00
Diego Biurrun 056fd4fe65 configure: Properly check for availability of -Wno-foo warning flags
For some weird reason gcc does not check if the -Wno disabling variants
of warning flags match existing warning flags. Instead it swallows them
silently. That is, unless other warning or error messages are generated,
because then - for some even more bizarre reason - a complaint about the
unknown disable warning flag is issued along with the error or warning
message.

Thus to check for the availability of a warning disabling option, one
needs to check for the enabling variant instead and then add the
disabling variant to CFLAGS.
2013-11-01 22:05:20 +01:00
Diego Biurrun 23157d72b5 configure: Split test_cflags function off from check_cflags
This is useful to test flags without directly adding them to CFLAGS.
2013-11-01 22:05:20 +01:00
Guillaume Martres 064698d381 Add HEVC decoder
Initially written by Guillaume Martres <smarter@ubuntu.com> as a GSoC
project. Further contributions by the OpenHEVC project and other
developers, namely:

Mickaël Raulet <mraulet@insa-rennes.fr>
Seppo Tomperi <seppo.tomperi@vtt.fi>
Gildas Cocherel <gildas.cocherel@laposte.net>
Khaled Jerbi <khaled_jerbi@yahoo.fr>
Wassim Hamidouche <wassim.hamidouche@insa-rennes.fr>
Vittorio Giovara <vittorio.giovara@gmail.com>
Jan Ekström <jeebjp@gmail.com>
Anton Khirnov <anton@khirnov.net>
Martin Storsjö <martin@martin.st>
Luca Barbato <lu_zero@gentoo.org>
Yusuke Nakamura <muken.the.vfrmaniac@gmail.com>
Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Diego Biurrun <diego@biurrun.de>

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-10-31 20:19:59 +01:00
Luca Barbato e789130522 configure: Provide an hardened toolchain option 2013-10-29 11:36:00 +01:00
Luca Barbato dcd3eda6cb configure: Move gcc-only -W option where it belongs 2013-10-29 11:36:00 +01:00
Luca Barbato de6061203e configure: Disable -Wmaybe-uninitialized by default
It is by definition unreliable and causes pointless noise on valid
code.
2013-10-28 00:04:49 +01:00
Kieran Kunhya 4d6ee07255 libavutil: x86: Add AVX2 capable CPU detection.
Patch based on x264's AVX2 detection

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-10-25 19:36:55 +01:00
Clément Bœsch e01fba5562 movenc: Add an F4V muxer
F4V is Adobe's mp4/iso media variant, with the most significant
addition/change being supporting other flash codecs than just
aac/h264.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-10-23 11:17:03 +03:00
Derek Buitenhuis 9e3946aada build: Require yasm 0.8.0 or higher
This is in preparation for removing a .rodata kludge
which was only required for older YASM versions.

The movbe instruction was introduced in 0.8.0, which already
had AVX, which was introduced in 0.7.0, and NASM introduced
movbe in 2.0.3, which is the same version which introduced
AVX support.

Also, make the failure message more accurate.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-10-09 07:44:19 -04:00
Loren Merritt e52567c295 build: Strip spurious labels
The implementation of 25cb0c1a involves lots of spurious labels.

The effect of keeping those labels around is making debugging harder.
Those labels are meaningless, and complicate the disassembly. Also,
gdb can't tell the difference between them and function entry points.

This new strip command is irrelevant to any usage of Libav that would
have used the old fully stripped version, because the old one was for
non-debug use.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-10-07 06:20:15 -04:00
Alex Smith d6d27f3e58 configure: Enable -Qansi-alias for icl 14+
Qansi-alias worked on 12.x, then caused miscompilation on 13.x, but now
works again passing all FATE tests for icl version 14.

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2013-09-24 11:29:00 +02:00
Alex Smith 09f2581dc5 msvc/icl: Use __declspec(deprecated)
Prior to this on msvc/icl there was no handling of deprecated functions
and the deprecated warning was disabled.

After enabling there are a number of warnings relating to the CRT and
the use of the non-secure versions of several functions.  Defining
_CRT_SECURE_NO_WARNINGS silences these warnings.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-09-20 14:40:06 +03:00
Luca Barbato e5d45e028c build: Support cparser 2013-09-19 21:53:21 +02:00
Justin Ruggles c4bfa09807 Add a WebP decoder
Container and lossy decoding by Aneesh Dogra <aneesh@sugarlabs.org>
Lossless decoding by Justin Ruggles <justin.ruggles@gmail.com>
2013-09-18 14:10:05 -04:00
Vittorio Giovara 187105ff8a Fix references to deleted avcodec_encode_video() function 2013-09-16 13:59:19 +02:00
Diego Biurrun e2cd766ca1 configure: Mention that icl does not build both static and shared libs 2013-09-12 13:00:22 +02:00
Diego Biurrun 5045f6bdfa configure: Fix wrong reference to user support mailing list 2013-09-11 14:49:56 +02:00
Luca Barbato 7f9e893f56 build: Report an error message when a pc file is not found
Ease tracking path problems.
2013-09-04 09:47:06 +02:00
Vittorio Giovara f4ca970dba configure: Add docdir configuration option
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-08-31 16:16:38 +02:00
Diego Biurrun 84146963d2 configure: x86: Fix handling of i686 and cpunop features
The i686 feature really is a CPU feature and should be handled as such.
The cpunop dependency on i686 should be expressed with a standard _deps
declaration instead of a manual test.
2013-08-28 17:03:05 +02:00
Martin Storsjö 4f2b469da5 Add a libfdk-aac decoder
This can be useful for decoding AAC object types that are not supported
by the native AAC decoder, e.g. AAC-LD and AAC-ELD.
2013-08-20 14:27:27 -04:00
Martin Storsjö c9031c7c14 hlsenc: Add a proper dependency on the mpegts muxer
The hls muxer itself doesn't have any direct (object file level)
dependencies on mpegtsenc.o, and including that object file
directly doesn't ensure that it is registered so that the muxer
actually is accessible.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-08-15 22:41:11 +03:00
Kostya Shishkov 3e5898782d Voxware MetaSound decoder 2013-08-08 10:52:44 +02:00
Diego Biurrun 6fb65973c9 configure: Properly split dv1394 indev dependencies 2013-08-06 11:23:00 +02:00
Diego Biurrun 61c31e4ee7 configure: Properly set zlib dependencies for all components 2013-08-06 11:23:00 +02:00
Diego Biurrun a7d45e06e9 configure: The W64 demuxer should select the WAV demuxer, not depend on it 2013-08-06 11:23:00 +02:00
Diego Biurrun 406e6c0ba5 configure: Properly split avserver component and system dependencies 2013-08-06 11:23:00 +02:00
Diego Biurrun 255d9c570e riff: Move demuxing code to a separate file. 2013-08-06 11:02:36 +02:00
Diego Biurrun 3dd5c95dee riff: Move muxing code to a separate file 2013-08-06 11:02:35 +02:00
Luca Barbato 605387582b lavf: Support unix sockets 2013-08-05 16:13:35 +02:00
Rémi Denis-Courmont 578ea75a9e vdpau: remove old-style decoders
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-08-05 11:15:49 +02:00
Diego Biurrun 6da5b57da1 configure: Check for GCC diagnostic pragma support inside of functions
The actual usage of the pragma is within functions and older versions
of gcc only support the pragma outside of functions.
2013-08-02 22:34:03 +02:00
Diego Biurrun 3a7050ffed build: Add _Pragma macro to disable deprecated declaration warnings 2013-08-02 19:19:02 +02:00
Diego Biurrun 4822ee3ca6 configure: Detect AIX ar command instead of hardcoding it in the OS section 2013-07-29 19:43:37 +02:00
Michael Kostylev 80ade7985c AIX: add support for shared builds
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2013-07-26 21:12:36 +02:00
Diego Biurrun 03039f4c8c miscellaneous typo fixes 2013-07-25 19:43:32 +02:00
Hendrik Leppkes 7ef760d95c configure: generate full msvc debug symbols when linking in debug mode
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-07-21 19:59:15 +03:00
Martin Storsjö d010e95f86 avserver: Remove unused loadable module support
There is no record of this ever being used at all, anywhere,
since the feature was added in 2effd27446.

This gets rid of extra linker tricks just to support a feature
that isn't used, simplifying portability to other platforms.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-07-18 17:25:49 +03:00
Martin Storsjö ef5b70affc configure: Check for support for labels in the inline assembly
Use this for enabling the ppc timer.h implementation only on
assemblers that support labels in the inline assembly.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-07-11 18:53:02 +03:00
Luca Barbato d3635f3ab0 compat: wrap math.h to avoid AIX-specific clashes
AIX defines a class() function in its math.h header without any
guard.
2013-07-04 21:54:32 +02:00
Alex Smith 4f6b192e2e configure: Do not omit frame pointers for msvc/icl debug builds
Because O1 or O2 are required to build libav with msvc/icl, this must be
explicitly set instead of just omitting Oy.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-06-24 18:51:30 -04:00
Alex Smith 9f4a16c52e configure: Do not explicitly set Oy for msvc/icl
It is implied by O1 or O2, both of which are required to build libav
with msvc/icl.  Silences warnings when targeting x64 with icl.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-06-24 18:51:20 -04:00
Diego Biurrun ace87c19ed configure: whitespace cosmetics 2013-06-23 12:24:31 +02:00
Diego Biurrun 6dc6598692 configure: Simplify an expression with enabled_all. 2013-06-23 12:00:08 +02:00
Alex Smith f11e4045b9 configure: More msvc/icl combining
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-06-22 17:00:57 -04:00
Alex Smith e0d6e2fc67 configure: Remove unneeded icl inline compatibility definition
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-06-19 10:53:27 +03:00
Anton Khirnov 84d3ff50cd lavc: add a libwavpack encoder wrapper 2013-06-10 21:33:48 +02:00
Martin Storsjö 3965d404cc configure: Don't add -fPIC on windows targets
This avoids warnings about this option not having any effect on
this platform.

We still want to enable the pic configure item for these platforms
(if detected via the compiler builtin define __PIC__) to get proper
inline assembly workarounds.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-06-10 14:32:13 +03:00
Martin Storsjö 3fd0d166aa configure: Don't explicitly disable PIC for windows targets
This reverts e08c946c6 and 05165c2f7a. The actual intention of
e08c946c6 was to fix shared library builds for arm/win32, which
can also be accomplished in other ways.

Disabling pic on those platforms broke inline assembly on cygwin/64
(since some inline assembly requires knowing whether we are building
as PIC or not), and might also break inline assembly on other
compilers on windows.

As a side-effect, this unfortunately brings back all the warnings
about PIC not having any effect on that platform.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-06-10 14:32:10 +03:00
Martin Storsjö 2aa3325454 configure: arm: Don't try to enable pic for shared libraries on win32
The object file format doesn't support PIC loads in ARM assembly,
there are no relocation types in PE/COFF that correspond to
BFD_RELOC_32_PCREL (R_ARM_REL32 in ELF).

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-06-10 14:32:06 +03:00
Kostya Shishkov 2d66a58ccd Go2Webinar decoder 2013-06-03 09:24:55 +02:00
Alex Smith 60f09c04d8 configure: icl: Merge -Qdiag-error parameters
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-05-31 14:39:30 -04:00
Alex Smith 14fb9d3d8c configure: Separate commonalities in msvc and icl flags
Allows for easier handling of flags that may be specific to icl or msvc.
Furthermore, simplify the handling of warnings and remarks thanks to
icl's support of -Wall on Windows.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2013-05-31 14:39:14 -04:00
Martin Storsjö 9f30fb5a77 configure: Don't pass -mthumb or -march= to MSVC
The modern MSVC for ARM always builds for thumb, and it can't be
disabled.

Also just use the default arch instead of trying to map the -march
parameter to MSVC's -arch parameter (which only takes the values
ARMv7VE and VFPv4).

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-29 00:53:11 +03:00
Luca Barbato 0ba49d28a1 configure: support gcc-4.8 instrumentation
Since version 4.8 gcc sports asan and tsan integration that can
be leveraged when hunting bugs.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-05-28 17:22:16 +02:00
Martin Storsjö ba13606ca6 fate: Add a --target-samples path parameter
This allows having the samples accessible via different paths
on the target and on the host.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-28 17:16:54 +03:00
Anton Khirnov a3fc62e89e configure: make jack depend on pthreads 2013-05-27 21:56:14 +02:00
Alex Smith 322e4194dd msvc/icl: Intel Compiler support on Windows
Initial support for the ICL compiler on windows. Requires a new
c99wrap with ICL support (1.0.2+).

Currently not much different speed wise compared to msvc. In the
future with a few changes it can be made to support the inline asm.
This would be the primary reason for using it.

Passed all fate tests, versions tested:
    13.1.1.171 (2013 Update 3) x86 and x64
    12.1.5.344 (2011 Update 11) x86 and x64

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-05-25 17:52:44 +02:00
Laurent 9495cd170b configure: Fix check_exec_crash for ICL support
Change the check_exec_crash test to use a function pointer instead of
simply calling the function. The EBP availability test will crash when
compiled with ICL likely due to compiler optimization shenanigans.

Originally the check_exec_crash code was moved out of main to fix a
problem with gcc's treatment of non-leaf main on x86_32. Libav already
moved the code out of main but the addition of the function pointer will
prevent any inlining which fixes the remaining problem.

A function pointer is used since it is compiler agnostic (as opposed to
say __attribute__ ((noinline)) which would only work with gcc compatible
compilers).

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-05-25 12:07:56 +02:00
Martin Storsjö 5b2b0b912d configure: Enable the strtod workaround when building for bionic
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-21 19:37:07 +03:00
Martin Storsjö 0b6899f154 configure: msvc: Set the target windows version to XP if no target is set
MSVC 2010 (or more precisely, Windows SDK 7.0 which comes with MSVC
2010) sets _WIN32_WINNT to the constant for Windows 7 if nothing is
set. This could lead to the libav configure script detecting and
using functions only present in Windows 7 or newer, which in most
cases isn't desired. If the caller explicitly wants this, the caller
can add the _WIN32_WINNT define via --extra-cflags, setting the desired
version.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-19 18:22:32 +03:00
Luca Barbato edfe609fc9 configure: Add basic valgrind-massif support
With the parameter --toolchain valgrind-massif, the configure
script sets reasonable defaults that can be overridden as explained
in the documentation.
2013-05-18 21:29:17 +02:00
Kostya Shishkov 1232a1647a Apple Intermediate Codec decoder 2013-05-17 06:31:05 +02:00
Alex Smith 225a5f91cc configure: Use linker hardening flags on mingw
This makes it consistent with the msvc builds which automatically set
the DEP and ASLR flags by default.  There really is no good reason why
they shouldn't be set.

The fact that binutils does not set them on by default boggles the mind.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-15 14:42:08 +03:00
Martin Storsjö 05165c2f7a configure: Disable PIC for cygwin just as for win32/mingw
If this is explicitly disabled for win32/mingw, it should also
be disabled for cygwin, for consistency and for the same reasons
as for win32/mingw.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-13 20:20:55 +03:00
Diego Biurrun 2c2c48a9bd configure: x86: Only enable cpunop on i686
The assembler may insert nopl instructions for cpunop, which are not
(universally) supported on i586 CPUs.
2013-05-12 21:23:38 +02:00
Diego Biurrun f54b55058a configure: Rename cmov processor capability to i686
The goal is to make the capapility slightly more general and have it
cover the availability of the nopl instruction in addition to cmov.
2013-05-12 21:23:38 +02:00
Martin Storsjö e08c946c68 configure: Explicitly disable PIC when targeting win32/mingw
These platforms do not have any notion of PIC. On some compilers,
enabling pic produces a number of warnings.

This avoids trying to produce PIC loads in the ARM assembly - there
are no relocation types in PE/COFF that correspond to
BFD_RELOC_32_PCREL (R_ARM_REL32 in ELF).

As a side-effect, this avoids enabling PIC on mingw64, getting rid
of the warnings about PIC not having any effect on that platform.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-12 19:45:33 +03:00
Martin Storsjö b1803c79dc configure: Use enable_weak when enabling pic
This allows it to be overridden, either by the user on the command
line, or by other sections of the configure script.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-12 19:45:26 +03:00
Martin Storsjö 06122c2533 msvc: Move linker pragma from config.h to libavutil/internal.h
This makes linking succeed for tools that include config.h but
don't link to libavutil.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-08 01:28:25 +03:00
Anton Khirnov 9779f93066 configure: add dependencies to lavfi .pc file
The scale filter depends on sws, resample on lavr, and movie on lavf and
lavc.

Fixes Bug 502.
2013-05-07 12:32:14 +02:00
Anton Khirnov bce70f8170 configure: make avconv select (a)trim filters
They are now used for -ss/-t
2013-05-07 12:32:03 +02:00
Martin Storsjö 2cca96e670 configure: Check for getenv
When targeting the "windows store application" (metro) API subset
(or the windows phone API subset), the getenv function isn't
available. If it is unavailable, just define getenv to NULL.

The check uses check_func_headers, since the function actually
might exist in the libraries, but is hidden in the headers.

The fallback is in config.h since msvc can't do -D defines with
parameters on the command line, and it's used both within the
libraries and the frontend applications (so a libavutil internal
header wouldn't be enough).

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-04 23:58:59 +03:00
Reinhard Tartler b1ee8eec84 configure: Add basic valgrind-memcheck support
With the parameter --valgrind-memcheck, the configure script sets
reasonable defaults that can be overridden as explained in the
documentation.

The idea of using set_defaults is from Luca Barbato.
2013-05-04 12:17:51 +02:00
Martin Storsjö 769d921f3e compat: msvc: Make sure the object files are included when linking statically
If building libav with -MD in the cflags (for making the MSVC compiler
generate code for using a dynamically linked libc), the system headers
that declare strtod, snprintf and vsnprintf declare the functions as
imported from a DLL. To hook up wrappers of our own for these functions,
the function names are defined to avpriv_*, so that the calling code
within libav calls the wrappers instead. Since these functions
are declared to be imported from DLLs, the calling code expects to
load them from DLL import function pointers (creating references to
_imp__avpriv_strtod instead of directly to avpriv_strtod). If the
libav libraries are not built as DLLs, no such function pointers (as
the calling code expects) are created.

The linker can fix this up automatically in some cases (producing
warnings LNK4217 and LNK4049), if the object files are already
included. By telling the linker to try to include those symbols
(without the _imp prefix as the calling code ends up using),
we get the object files included, so that the linker can do the
automatic fixup. This is done via config.h, so that all (or at least
most) of the object files in our libraries force including the compat
files, to make sure they are included regardless of what files from our
static libraries actually are included.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-03 13:34:34 +03:00
Martin Storsjö ffb068ce8e configure: Don't do enable_deep_weak on disabled variables
This avoids cases where configure tries to weakly enable an item
which actually is disabled, ending up still enabling dependencies
of the item which itself is only enabled weakly.

More concretely, the h264 decoder suggests error resilience, which
is then enabled weakly (unless manually disabled). Previously,
dsputil, which is a dependency of error resilience, was enabled
even if error resilience wasn't enabled in the end.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-02 22:31:57 +03:00
Martin Storsjö 4d810ad2e9 configure: Use a different variable name in push/popvar
The variable name 'var' is commonly used to iterate through arguments
in other functions. When the pushvar function internally uses the
variable 'var', it makes pushing/popping the variable 'var' not
work as intended.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-05-02 22:31:55 +03:00
Ronald S. Bultje 28bc406c84 mjpeg: Use hpeldsp instead of dsputil for half-pel functions
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:38 +03:00
Ronald S. Bultje 1277dc07fb svq1enc: Use hpeldsp instead of dsputil for half-pel functions
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:32 +03:00
Ronald S. Bultje 2f6bc5f7c1 svq3: Use hpeldsp instead of dsputil for half-pel functions
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:27 +03:00
Ronald S. Bultje f4fed5a2f9 mpegvideo: Use hpeldsp instead of dsputil for half-pel functions
This also converts vc1, since that is mpegvideo-based.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:21 +03:00
Ronald S. Bultje 6caa44aa7d svq1: Use hpeldsp instead of dsputil for half-pel functions
This makes svq1 independent of dsputil.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:14 +03:00
Ronald S. Bultje c10470035e mimic: Use hpeldsp instead of dsputil for half-pel functions
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:08 +03:00
Ronald S. Bultje 8071264f21 interplayvideo: Use hpeldsp instead of dsputil for half-pel functions
This makes interplayvideo independent of dsputil.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:18:02 +03:00
Ronald S. Bultje 0f0a11d576 bink: Use hpeldsp instead of dsputil for half-pel functions
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:17:56 +03:00
Ronald S. Bultje 8f992dc8c7 indeo3: Use hpeldsp instead of dsputil for half-pel functions
This makes the Indeo 3 decoder independent of dsputil.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:17:50 +03:00
Ronald S. Bultje cb7ecb7563 vp56: Use hpeldsp instead of dsputil for half-pel functions
This makes vp5 and vp6 independent of dsputil.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:17:33 +03:00
Ronald S. Bultje 3bd062bf7f vp3: Use hpeldsp instead of dsputil for half-pel functions
This makes vp3 independent of dsputil.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:17:26 +03:00
Ronald S. Bultje 68d8238cca hpeldsp: Add half-pel functions (currently copies of dsputil)
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-19 23:17:17 +03:00
Vittorio Giovara 3fce136798 lavfi: new interlace filter
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-04-11 21:33:07 +02:00
Anton Khirnov 93e65e9a6c Cosmetics, restore alphabetic order in atomics lists. 2013-04-11 12:31:14 +02:00
Ronald S. Bultje b93b27edb0 dsputil: Make dsputil selectable
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-04-10 11:04:05 +03:00
Reinhard Tartler a862c7d336 Integrate lcov/gcov into Libav
The gcov/lcov are a common toolchain for visualizing code coverage with
the GNU/Toolchain. The documentation and implementation of this
integration was heavily inspired from the blog entry by Mike Melanson:
http://multimedia.cx/eggs/using-lcov-with-ffmpeg/
2013-04-05 18:55:11 +02:00
Luca Barbato 19f251a288 clang: use -fsantize=address and -fsanitize=thread
The previous syntax is deprecated.
2013-04-03 12:23:43 +02:00
Martin Storsjö 817dff578f configure: Check for the atomic.h functions used in the suncc atomics header
The "suncc" atomics implementation uses a suncc specific memory
barrier, but also relies on a few atomic functions from atomic.h,
that are not suncc specific but specific to solaris. This made
the current implementation fail on suncc on linux.
2013-04-03 09:23:04 +02:00
Anton Khirnov f9f6402e9c configure: prettify atomics handling.
Add simpler names and a shorthand for native atomics (as opposed to
pthreads fallback).
2013-04-03 09:22:31 +02:00
Martin Storsjö cfe5908a72 configure: Add error_resilience as dependency to the eatqi decoder
This makes standalone compilation of the eatqi decoder
succeed. The dependency comes from the shared mpeg12dec.o file.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-03-27 17:37:15 +02:00
Janne Grunau d767e2f969 configure: fix dependencies of XvMC and old vdpau mpeg2 decoders 2013-03-26 22:53:18 +01:00
Martin Storsjö 2ece5bf3ec configure: Remove a stray msmpeg4v1 encoder declaration
No such encoder exists currently.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-03-26 16:17:00 +02:00
Martin Storsjö 3b2d0ec473 configure: Remove the mpegvideo dependency from svq1
The svq1 decoder can be built standalone without mpegvideo.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-03-26 15:50:00 +02:00
Ronald S. Bultje 0b499c9b06 h264: Make it possible to compile without error_resilience
Error resilience is enabled by the h264 decoder, unless explicitly
disabled. --disable-everything --enable-decoder=h264 will produce
a h264 decoder with error resilience enabled, while
--disable-everything --enable-decoder=h264 --disable-error-resilience
will produce a h264 decoder with error resilience disabled.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-03-26 09:55:05 +02:00