build: do not use LIB as variable name
authorMans Rullgard <mans@mansr.com>
Wed, 10 Oct 2012 22:02:57 +0000 (23:02 +0100)
committerMans Rullgard <mans@mansr.com>
Wed, 10 Oct 2012 22:46:31 +0000 (23:46 +0100)
The Microsoft linker uses the LIB environment variable which
clashes with a make variable of the same name.

Signed-off-by: Mans Rullgard <mans@mansr.com>
library.mak

index 64b5f2b..b365935 100644 (file)
@@ -33,11 +33,11 @@ install-libs-$(CONFIG_STATIC): install-lib$(NAME)-static
 install-libs-$(CONFIG_SHARED): install-lib$(NAME)-shared
 
 define RULES
-$(EXAMPLES) $(TOOLS): LIB = $(FULLNAME:%=$(LD_LIB))
-$(TESTPROGS):         LIB = $(SUBDIR)$(LIBNAME)
+$(EXAMPLES) $(TOOLS): THISLIB = $(FULLNAME:%=$(LD_LIB))
+$(TESTPROGS):         THISLIB = $(SUBDIR)$(LIBNAME)
 
 $(EXAMPLES) $(TESTPROGS) $(TOOLS): %$(EXESUF): %.o
-       $$(LD) $(LDFLAGS) $$(LD_O) $$(filter %.o,$$^) $$(LIB) $(FFEXTRALIBS) $$(ELIBS)
+       $$(LD) $(LDFLAGS) $$(LD_O) $$(filter %.o,$$^) $$(THISLIB) $(FFEXTRALIBS) $$(ELIBS)
 
 $(SUBDIR)$(SLIBNAME): $(SUBDIR)$(SLIBNAME_WITH_MAJOR)
        $(Q)cd ./$(SUBDIR) && $(LN_S) $(SLIBNAME_WITH_MAJOR) $(SLIBNAME)