io_size vs. time_based discrepancy
[fio.git] / Makefile
index d287126edc417ef117d0c9d50b6a4ffefc4f5cfe..e30273ce86fcd38a371913a48c825ed57c63dd5b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -47,6 +47,7 @@ SOURCE :=     gettime.c ioengines.c init.c stat.c log.c time.c filesetup.c \
                lib/hweight.c lib/getrusage.c idletime.c td_error.c \
                profiles/tiobench.c profiles/act.c io_u_queue.c filelock.c \
                lib/tp.c lib/bloom.c lib/gauss.c lib/mountcheck.c workqueue.c \
+               lib/output_buffer.c \
                $(patsubst $(SRCDIR)/%,%,$(wildcard $(SRCDIR)/crc/*.c))
 
 ifdef CONFIG_LIBHDFS
@@ -237,6 +238,7 @@ ifneq (,$(findstring CYGWIN,$(CONFIG_TARGET_OS)))
     T_DEDUPE_OBJS += os/windows/posix.o lib/hweight.o
     T_SMALLOC_OBJS += os/windows/posix.o lib/hweight.o
     T_LFSR_TEST_OBJS += os/windows/posix.o lib/hweight.o
+    T_ZIPF_OBJS += lib/strcasestr.o
 endif
 
 T_TEST_PROGS = $(T_SMALLOC_PROGS)
@@ -322,7 +324,14 @@ parse.o: lex.yy.o y.tab.o
 endif
 
 init.o: init.c FIO-VERSION-FILE
+       @mkdir -p $(dir $@)
        $(QUIET_CC)$(CC) -o $@ $(CFLAGS) $(CPPFLAGS) -c $<
+       @$(CC) -MM $(CFLAGS) $(CPPFLAGS) $(SRCDIR)/$*.c > $*.d
+       @mv -f $*.d $*.d.tmp
+       @sed -e 's|.*:|$*.o:|' < $*.d.tmp > $*.d
+       @sed -e 's/.*://' -e 's/\\$$//' < $*.d.tmp | fmt -1 | \
+               sed -e 's/^ *//' -e 's/$$/:/' >> $*.d
+       @rm -f $*.d.tmp
 
 gcompat.o: gcompat.c gcompat.h
        $(QUIET_CC)$(CC) $(CFLAGS) $(GTK_CFLAGS) $(CPPFLAGS) -c $<