[FFmpeg-devel] [PATCH] tests/api: Fix API test build on windows with --enable-shared

Hendrik Leppkes h.leppkes at gmail.com
Mon Nov 30 22:50:12 CET 2015


---
I'm not quite sure if this fix is 100% correct, but it works here.

The problem is that FF_DEP_LIBS points to the .dll files, but you can't link to the .dll files,
you need to point to the import libraries. Unfortunately there is no variable which simply
holds all import libraries - but they do appear to be part of FF_EXTRALIBS, so thats used instead.

tests/api/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/api/Makefile b/tests/api/Makefile
index c48c34a..a6d8e42 100644
--- a/tests/api/Makefile
+++ b/tests/api/Makefile
@@ -14,7 +14,7 @@ $(APITESTOBJS) $(APITESTOBJS:.o=.i): CPPFLAGS += -DTEST
 $(APITESTOBJS) $(APITESTOBJS:.o=.i): CFLAGS += -Umain
 
 $(APITESTPROGS): %$(EXESUF): %.o $(EXEOBJS) $(FF_DEP_LIBS)
-	$(LD) $(LDFLAGS) $(LDEXEFLAGS) $(LD_O) $(filter %.o,$^) $(FF_DEP_LIBS) $(FFEXTRALIBS) $(ELIBS)
+	$(LD) $(LDFLAGS) $(LDEXEFLAGS) $(LD_O) $(filter %.o,$^) $(FF_EXTRALIBS) $(ELIBS)
 
 testclean::
 	$(RM) $(addprefix $(APITESTSDIR)/,$(CLEANSUFFIXES) *-test$(EXESUF))
-- 
2.6.2.windows.1



More information about the ffmpeg-devel mailing list