[FFmpeg-cvslog] r18294 - in trunk: common.mak subdir.mak
mru
subversion
Wed Apr 1 02:53:22 CEST 2009
Author: mru
Date: Wed Apr 1 02:53:22 2009
New Revision: 18294
Log:
Move make rules applicable only to subdirs into subdir.mak
Modified:
trunk/common.mak
trunk/subdir.mak
Modified: trunk/common.mak
==============================================================================
--- trunk/common.mak Wed Apr 1 02:45:28 2009 (r18293)
+++ trunk/common.mak Wed Apr 1 02:53:22 2009 (r18294)
@@ -81,34 +81,4 @@ CLEANSUFFIXES = *.o *~ *.ho
DISTCLEANSUFFIXES = *.d *.pc
LIBSUFFIXES = *.a *.lib *.so *.so.* *.dylib *.dll *.def *.dll.a *.exp *.map
-define RULES
-$(SUBDIR)%$(EXESUF): $(SUBDIR)%.o
- $(CC) $(FFLDFLAGS) -o $$@ $$^ $(SUBDIR)$(LIBNAME) $(FFEXTRALIBS)
-
-$(SUBDIR)%-test.o: $(SUBDIR)%.c
- $(CC) $(CFLAGS) -DTEST -c -o $$@ $$^
-
-$(SUBDIR)%-test.o: $(SUBDIR)%-test.c
- $(CC) $(CFLAGS) -DTEST -c -o $$@ $$^
-
-$(SUBDIR)x86/%.o: $(SUBDIR)x86/%.asm
- $(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)) \
- $(addprefix $(SUBDIR), $(foreach suffix,$(CLEANSUFFIXES),$(addsuffix /$(suffix),$(DIRS))))
-
-distclean:: clean
- rm -f $(addprefix $(SUBDIR),$(DISTCLEANSUFFIXES)) \
- $(addprefix $(SUBDIR), $(foreach suffix,$(DISTCLEANSUFFIXES),$(addsuffix /$(suffix),$(DIRS))))
-endef
-
-$(eval $(RULES))
-
-examples: $(EXAMPLES)
-testprogs: $(TESTPROGS)
-
-include $(DEPS)
Modified: trunk/subdir.mak
==============================================================================
--- trunk/subdir.mak Wed Apr 1 02:45:28 2009 (r18293)
+++ trunk/subdir.mak Wed Apr 1 02:53:22 2009 (r18294)
@@ -19,6 +19,29 @@ endif
INCINSTDIR := $(INCDIR)/lib$(NAME)
define RULES
+$(SUBDIR)%$(EXESUF): $(SUBDIR)%.o
+ $(CC) $(FFLDFLAGS) -o $$@ $$^ $(SUBDIR)$(LIBNAME) $(FFEXTRALIBS)
+
+$(SUBDIR)%-test.o: $(SUBDIR)%.c
+ $(CC) $(CFLAGS) -DTEST -c -o $$@ $$^
+
+$(SUBDIR)%-test.o: $(SUBDIR)%-test.c
+ $(CC) $(CFLAGS) -DTEST -c -o $$@ $$^
+
+$(SUBDIR)x86/%.o: $(SUBDIR)x86/%.asm
+ $(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)) \
+ $(addprefix $(SUBDIR), $(foreach suffix,$(CLEANSUFFIXES),$(addsuffix /$(suffix),$(DIRS))))
+
+distclean:: clean
+ rm -f $(addprefix $(SUBDIR),$(DISTCLEANSUFFIXES)) \
+ $(addprefix $(SUBDIR), $(foreach suffix,$(DISTCLEANSUFFIXES),$(addsuffix /$(suffix),$(DIRS))))
+
ifdef BUILD_SHARED
all: $(SUBDIR)$(SLIBNAME)
@@ -72,3 +95,6 @@ uninstall-headers::
endef
$(eval $(RULES))
+
+examples: $(EXAMPLES)
+testprogs: $(TESTPROGS)
More information about the ffmpeg-cvslog
mailing list