[FFmpeg-cvslog] build: add -L flags before existing LDFLAGS

Mans Rullgard git at videolan.org
Thu Jul 21 16:54:44 CEST 2011


ffmpeg | branch: master | Mans Rullgard <mans at mansr.com> | Wed Jul 13 18:17:54 2011 +0100| [371584c42bffa21991a0e0d97a03f6d42123ba1f] | committer: Mans Rullgard

build: add -L flags before existing LDFLAGS

This ensures the linker picks the just built libraries even
if LDFLAGS for some reason contains -L flags pointing at
other directories containing libav libraries.

Signed-off-by: Mans Rullgard <mans at mansr.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=371584c42bffa21991a0e0d97a03f6d42123ba1f
---

 Makefile |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index a27fe28..9d6ec3a 100644
--- a/Makefile
+++ b/Makefile
@@ -20,13 +20,15 @@ $(foreach VAR,$(SILENT),$(eval override $(VAR) = @$($(VAR))))
 $(eval INSTALL = @$(call ECHO,INSTALL,$$(^:$(SRC_PATH)/%=%)); $(INSTALL))
 endif
 
+ALLFFLIBS = avcodec avdevice avfilter avformat avutil postproc swscale
+
 IFLAGS     := -I. -I$(SRC_PATH)
 CPPFLAGS   := $(IFLAGS) $(CPPFLAGS)
 CFLAGS     += $(ECFLAGS)
 CCFLAGS     = $(CFLAGS)
 YASMFLAGS  += $(IFLAGS) -Pconfig.asm
 HOSTCFLAGS += $(IFLAGS)
-LDFLAGS    += $(ALLFFLIBS:%=-Llib%)
+LDFLAGS    := $(ALLFFLIBS:%=-Llib%) $(LDFLAGS)
 
 define COMPILE
 	$($(1)DEP)
@@ -66,8 +68,6 @@ BASENAMES   = ffmpeg ffplay ffprobe ffserver
 ALLPROGS    = $(BASENAMES:%=%$(EXESUF))
 ALLMANPAGES = $(BASENAMES:%=%.1)
 
-ALLFFLIBS = avcodec avdevice avfilter avformat avutil postproc swscale
-
 FFLIBS-$(CONFIG_AVDEVICE) += avdevice
 FFLIBS-$(CONFIG_AVFILTER) += avfilter
 FFLIBS-$(CONFIG_AVFORMAT) += avformat



More information about the ffmpeg-cvslog mailing list