This is useful for debugging. Dependencies for these files are not generated due to limitations in many compilers.
Signed-off-by: Mans Rullgard <[email protected]> --- Makefile | 3 +++ configure | 1 + library.mak | 8 ++++++-- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 1cbf2aa..9abb835 100644 --- a/Makefile +++ b/Makefile @@ -45,6 +45,9 @@ COMPILE_S = $(call COMPILE,AS) %.o: %.S $(COMPILE_S) +%.i: %.c + $(CC) $(CCFLAGS) $(CC_E) $< + %.h.c: $(Q)echo '#include "$*.h"' >$@ diff --git a/configure b/configure index 26cd7ea..2759aef 100755 --- a/configure +++ b/configure @@ -3689,6 +3689,7 @@ ASFLAGS=$ASFLAGS AS_C=$AS_C AS_O=$AS_O CC_C=$CC_C +CC_E=$CC_E CC_O=$CC_O LD_O=$LD_O LD_LIB=$LD_LIB diff --git a/library.mak b/library.mak index b365935..d4308c8 100644 --- a/library.mak +++ b/library.mak @@ -15,12 +15,16 @@ $(SUBDIR)%-test.o: $(SUBDIR)%-test.c $(SUBDIR)%-test.o: $(SUBDIR)%.c $(COMPILE_C) +$(SUBDIR)%-test.i: $(SUBDIR)%.c + $(CC) $(CCFLAGS) $(CC_E) $< + $(SUBDIR)x86/%.o: $(SUBDIR)x86/%.asm $(DEPYASM) $(YASMFLAGS) -I $(<D)/ -M -o $@ $< > $(@:.o=.d) $(YASM) $(YASMFLAGS) -I $(<D)/ -o $@ $< -$(OBJS) $(SUBDIR)%.h.o $(TESTOBJS): CPPFLAGS += -DHAVE_AV_CONFIG_H -$(TESTOBJS): CPPFLAGS += -DTEST +LIBOBJS := $(OBJS) $(SUBDIR)%.h.o $(TESTOBJS) +$(LIBOBJS) $(LIBOBJS:.o=.i): CPPFLAGS += -DHAVE_AV_CONFIG_H +$(TESTOBJS) $(TESTOBJS:.o=.i): CPPFLAGS += -DTEST $(SUBDIR)$(LIBNAME): $(OBJS) $(RM) $@ -- 1.7.12.3 _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
