[MPlayer-cvslog] r29714 - in trunk: common.mak configure subdir.mak

diego subversion at mplayerhq.hu
Thu Sep 24 12:09:14 CEST 2009


Author: diego
Date: Thu Sep 24 12:09:14 2009
New Revision: 29714

Log:
Sync with current FFmpeg HEAD.

Modified:
   trunk/common.mak
   trunk/configure
   trunk/subdir.mak

Modified: trunk/common.mak
==============================================================================
--- trunk/common.mak	Thu Sep 24 11:47:36 2009	(r29713)
+++ trunk/common.mak	Thu Sep 24 12:09:14 2009	(r29714)
@@ -18,27 +18,18 @@ endif
 
 ALLFFLIBS = avcodec avdevice avfilter avformat avutil postproc swscale
 
-CFLAGS := -DHAVE_AV_CONFIG_H -I$(BUILD_ROOT_REL) -I$(SRC_PATH) $(OPTFLAGS)
+CPPFLAGS := -DHAVE_AV_CONFIG_H -I$(BUILD_ROOT_REL) -I$(SRC_PATH) $(CPPFLAGS)
 
 %.o: %.c
-	$(CC) $(CFLAGS) $(LIBOBJFLAGS) -c -o $@ $<
+	$(CCDEP)
+	$(CC) $(CPPFLAGS) $(CFLAGS) $(CC_DEPFLAGS) -c $(CC_O) $<
 
 %.o: %.S
-	$(AS) $(CFLAGS) $(LIBOBJFLAGS) -c -o $@ $<
+	$(ASDEP)
+	$(AS) $(CPPFLAGS) $(ASFLAGS) $(AS_DEPFLAGS) -c -o $@ $<
 
 %.ho: %.h
-	$(CC) $(CFLAGS) $(LIBOBJFLAGS) -Wno-unused -c -o $@ -x c $<
-
-%.d: %.c
-	$(DEPEND_CMD) > $@
-
-%.d: %.S
-	$(DEPEND_CMD) > $@
-
-%.d: %.cpp
-	$(DEPEND_CMD) > $@
-
-%.o: %.d
+	$(CC) $(CPPFLAGS) $(CFLAGS) -Wno-unused -c -o $@ -x c $<
 
 %$(EXESUF): %.c
 
@@ -71,16 +62,17 @@ EXAMPLES  := $(addprefix $(SUBDIR),$(add
 OBJS      := $(addprefix $(SUBDIR),$(OBJS))
 TESTPROGS := $(addprefix $(SUBDIR),$(addsuffix -test$(EXESUF),$(TESTPROGS)))
 
-DEP_LIBS := $(foreach NAME,$(FFLIBS),lib$(NAME)/$($(BUILD_SHARED:yes=S)LIBNAME))
+DEP_LIBS := $(foreach NAME,$(FFLIBS),$(BUILD_ROOT_REL)/lib$(NAME)/$($(CONFIG_SHARED:yes=S)LIBNAME))
 
 ALLHEADERS := $(subst $(SRC_DIR)/,$(SUBDIR),$(wildcard $(SRC_DIR)/*.h $(SRC_DIR)/$(ARCH)/*.h))
-checkheaders: $(filter-out %_template.ho,$(ALLHEADERS:.h=.ho))
+SKIPHEADERS = $(addprefix $(SUBDIR),$(SKIPHEADERS-))
+checkheaders: $(filter-out $(SKIPHEADERS:.h=.ho),$(ALLHEADERS:.h=.ho))
 
 DEPS := $(OBJS:.o=.d)
 depend dep: $(DEPS)
 
-CLEANSUFFIXES     = *.o *~ *.ho
+CLEANSUFFIXES     = *.o *~ *.ho *.map
 DISTCLEANSUFFIXES = *.d *.pc
-LIBSUFFIXES       = *.a *.lib *.so *.so.* *.dylib *.dll *.def *.dll.a *.exp *.map
+LIBSUFFIXES       = *.a *.lib *.so *.so.* *.dylib *.dll *.def *.dll.a *.exp
 
--include $(DEPS)
+-include $(wildcard $(DEPS))

Modified: trunk/configure
==============================================================================
--- trunk/configure	Thu Sep 24 11:47:36 2009	(r29713)
+++ trunk/configure	Thu Sep 24 12:09:14 2009	(r29714)
@@ -8435,6 +8435,8 @@ LIBSWSCALE = $_libswscale
 LIBSWSCALE_A = $_libswscale_a
 LIBSWSCALE_SO = $_libswscale_so
 
+CC_O=-o \$@
+LD=gcc
 CONFIG_STATIC=yes
 SRC_PATH=..
 BUILD_ROOT=..

Modified: trunk/subdir.mak
==============================================================================
--- trunk/subdir.mak	Thu Sep 24 11:47:36 2009	(r29713)
+++ trunk/subdir.mak	Thu Sep 24 12:09:14 2009	(r29714)
@@ -22,22 +22,20 @@ THIS_LIB := $(SUBDIR)$($(CONFIG_SHARED:y
 
 define RULES
 $(SUBDIR)%$(EXESUF): $(SUBDIR)%.o
-	$(CC) $(FFLDFLAGS) -o $$@ $$^ -l$(FULLNAME) $(FFEXTRALIBS) $$(ELIBS)
+	$(LD) $(FFLDFLAGS) -o $$@ $$^ -l$(FULLNAME) $(FFEXTRALIBS) $$(ELIBS)
 
 $(SUBDIR)%-test.o: $(SUBDIR)%.c
-	$(CC) $(CFLAGS) -DTEST -c -o $$@ $$^
+	$(CC) $(CPPFLAGS) $(CFLAGS) -DTEST -c -o $$@ $$^
 
 $(SUBDIR)%-test.o: $(SUBDIR)%-test.c
-	$(CC) $(CFLAGS) -DTEST -c -o $$@ $$^
+	$(CC) $(CPPFLAGS) $(CFLAGS) -DTEST -c -o $$@ $$^
 
 $(SUBDIR)x86/%.o: $(SUBDIR)x86/%.asm
+	$(YASM) $(YASMFLAGS) -I $$(<D)/ -M -o $$@ $$< > $$(@:.o=.d)
 	$(YASM) $(YASMFLAGS) -I $$(<D)/ -o $$@ $$<
 
-$(SUBDIR)x86/%.d: $(SUBDIR)x86/%.asm
-	$(YASM) $(YASMFLAGS) -I $$(<D)/ -M -o $$(@:%.d=%.o) $$< > $$@
-
 clean::
-	rm -f $(EXAMPLES) $(addprefix $(SUBDIR),*-test$(EXESUF) $(CLEANFILES) $(CLEANSUFFIXES) $(LIBSUFFIXES)) \
+	rm -f $(addprefix $(SUBDIR),*-example$(EXESUF) *-test$(EXESUF) $(CLEANFILES) $(CLEANSUFFIXES) $(LIBSUFFIXES)) \
 	    $(addprefix $(SUBDIR), $(foreach suffix,$(CLEANSUFFIXES),$(addsuffix /$(suffix),$(DIRS))))
 
 distclean:: clean
@@ -54,7 +52,7 @@ $(SUBDIR)$(SLIBNAME): $(SUBDIR)$(SLIBNAM
 
 $(SUBDIR)$(SLIBNAME_WITH_MAJOR): $(OBJS)
 	$(SLIB_CREATE_DEF_CMD)
-	$(CC) $(SHFLAGS) $(FFLDFLAGS) -o $$@ $$(filter-out $(DEP_LIBS),$$^) $(FFEXTRALIBS) $(EXTRAOBJS)
+	$(LD) $(SHFLAGS) $(FFLDFLAGS) -o $$@ $$(filter %.o,$$^) $(FFEXTRALIBS) $(EXTRAOBJS)
 	$(SLIB_EXTRA_CMD)
 
 ifdef SUBDIR


More information about the MPlayer-cvslog mailing list