diff options
author | Philip Gladstone <philipjsg@users.sourceforge.net> | 2003-01-14 15:30:42 +0000 |
---|---|---|
committer | Philip Gladstone <philipjsg@users.sourceforge.net> | 2003-01-14 15:30:42 +0000 |
commit | 77b71ddc11cef98fce54e56dc7a7d26c213a6b6d (patch) | |
tree | 9b129f08eba5ac817c75ac9b0bc577ed3d54d9a8 /libavformat | |
parent | cb7c98d6e2277e4ea370aa23926820899bfcd181 (diff) | |
download | ffmpeg-77b71ddc11cef98fce54e56dc7a7d26c213a6b6d.tar.gz |
AUtomatic dependency generation. Runs on Linux (at least). Probably should
update .cvsignore (somehere) to exclude .d files
Originally committed as revision 1459 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/Makefile | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/libavformat/Makefile b/libavformat/Makefile index 9ff067c531..0ecdcc2cc7 100644 --- a/libavformat/Makefile +++ b/libavformat/Makefile @@ -50,6 +50,8 @@ endif LIB= $(LIBPREF)avformat$(LIBSUF) +DEPS= $(OBJS:.o=.d) + all: $(LIB) $(LIB): $(OBJS) @@ -70,9 +72,15 @@ installlib: all %.o: %.c $(CC) $(CFLAGS) -c -o $@ $< +%.d: %.c + @echo $@ \\ > $@ + $(CC) $(CFLAGS) -MM $< >> $@ + +-include $(DEPS) + # BeOS: remove -Wall to get rid of all the "multibyte constant" warnings %.o: %.cpp g++ $(subst -Wall,,$(CFLAGS)) -c -o $@ $< clean: - rm -f *.o *~ *.a $(LIB) + rm -f *.o *.d *~ *.a $(LIB) |