Commit 0568fc11 authored by mru's avatar mru

Generate dependencies when object files are built

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@19608 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 2b6ada08
...@@ -21,25 +21,16 @@ ALLFFLIBS = avcodec avdevice avfilter avformat avutil postproc swscale ...@@ -21,25 +21,16 @@ ALLFFLIBS = avcodec avdevice avfilter avformat avutil postproc swscale
CPPFLAGS := -DHAVE_AV_CONFIG_H -I$(BUILD_ROOT_REL) -I$(SRC_PATH) $(CPPFLAGS) CPPFLAGS := -DHAVE_AV_CONFIG_H -I$(BUILD_ROOT_REL) -I$(SRC_PATH) $(CPPFLAGS)
%.o: %.c %.o: %.c
$(DEPEND_CMD)
$(CC) $(CPPFLAGS) $(CFLAGS) $(LIBOBJFLAGS) -c $(CC_O) $< $(CC) $(CPPFLAGS) $(CFLAGS) $(LIBOBJFLAGS) -c $(CC_O) $<
%.o: %.S %.o: %.S
$(DEPEND_CMD)
$(AS) $(CPPFLAGS) $(ASFLAGS) $(LIBOBJFLAGS) -c -o $@ $< $(AS) $(CPPFLAGS) $(ASFLAGS) $(LIBOBJFLAGS) -c -o $@ $<
%.ho: %.h %.ho: %.h
$(CC) $(CPPFLAGS) $(CFLAGS) $(LIBOBJFLAGS) -Wno-unused -c -o $@ -x c $< $(CC) $(CPPFLAGS) $(CFLAGS) $(LIBOBJFLAGS) -Wno-unused -c -o $@ -x c $<
%.d: %.c
$(DEPEND_CMD)
%.d: %.S
$(DEPEND_CMD)
%.d: %.cpp
$(DEPEND_CMD)
%.o: %.d
%$(EXESUF): %.c %$(EXESUF): %.c
SVN_ENTRIES = $(SRC_PATH_BARE)/.svn/entries SVN_ENTRIES = $(SRC_PATH_BARE)/.svn/entries
...@@ -83,4 +74,4 @@ CLEANSUFFIXES = *.o *~ *.ho *.map ...@@ -83,4 +74,4 @@ CLEANSUFFIXES = *.o *~ *.ho *.map
DISTCLEANSUFFIXES = *.d *.pc DISTCLEANSUFFIXES = *.d *.pc
LIBSUFFIXES = *.a *.lib *.so *.so.* *.dylib *.dll *.def *.dll.a *.exp LIBSUFFIXES = *.a *.lib *.so *.so.* *.dylib *.dll *.def *.dll.a *.exp
-include $(DEPS) -include $(wildcard $(DEPS))
...@@ -1309,7 +1309,7 @@ target_path='.' ...@@ -1309,7 +1309,7 @@ target_path='.'
# gcc stupidly only outputs the basename of targets with -MM, but we need the # gcc stupidly only outputs the basename of targets with -MM, but we need the
# full relative path for objects in subdirectories for non-recursive Make. # full relative path for objects in subdirectories for non-recursive Make.
DEPEND_CMD='$(DEPCC) $(DEPFLAGS) $< | sed -e "/^\#.*/d" -e "s,^[[:space:]]*$(*F)\\.o,$(@D)/$(*F).o," > $@' DEPEND_CMD='$(DEPCC) $(DEPFLAGS) $< | sed -e "/^\#.*/d" -e "s,^[[:space:]]*$(*F)\\.o,$(@D)/$(*F).o," > $(@:.o=.d)'
DEPFLAGS='$(CPPFLAGS) $(CFLAGS) -MM' DEPFLAGS='$(CPPFLAGS) $(CFLAGS) -MM'
# find source path # find source path
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment