summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorSteve Lhomme <robux4@gmail.com>2016-12-15 18:00:56 +0100
committerDiego Biurrun <diego@biurrun.de>2016-12-16 10:03:21 +0100
commitf7174d7ed045445d00a6d557236737d09ad32343 (patch)
tree607cd97db0e6d6af5c20f90816ae737b1f5d4cf0 /configure
parentef9a711be718ed3802a263d1d9ed340a4aaef224 (diff)
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.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure1
1 files changed, 1 insertions, 0 deletions
diff --git a/configure b/configure
index 25640ebb7f..2ecd0ed718 100755
--- a/configure
+++ b/configure
@@ -3279,6 +3279,7 @@ probe_cc(){
_DEPFLAGS='$(CPPFLAGS) $(CFLAGS) -showIncludes -Zs'
_cflags_speed="-O2"
_cflags_size="-O1"
+ _cflags_noopt="-O1"
if $_cc -nologo- 2>&1 | grep -q Linker; then
_ld_o='-out:$@'
else