Re-enable -O2 optimization
[fio.git] / Makefile
index 40d47d5ef66329af53e8657cbbddf67737ee9205..da0bb199458e6e303cc6b6047f4f8484be1dce72 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -14,7 +14,7 @@ SOURCE = gettime.c fio.c ioengines.c init.c stat.c log.c time.c filesetup.c \
                rbtree.c smalloc.c filehash.c profile.c debug.c lib/rand.c \
                lib/num2str.c $(wildcard crc/*.c) engines/cpu.c \
                engines/mmap.c engines/sync.c engines/null.c engines/net.c \
-               memalign.c
+               memalign.c server.c client.c iolog.c ieee754.c
 
 ifeq ($(UNAME), Linux)
   SOURCE += diskutil.c fifo.c blktrace.c helpers.c cgroup.c trim.c \
@@ -63,6 +63,10 @@ endif
 
 OBJS = $(SOURCE:.c=.o)
 
+T_OBJS = t/stest.o
+T_OBJS += mutex.o smalloc.o t/log.o
+T_PROGS = t/stest
+
 ifneq ($(findstring $(MAKEFLAGS),s),s)
 ifndef V
        QUIET_CC        = @echo '   ' CC $@;
@@ -80,6 +84,9 @@ all: .depend $(PROGS) $(SCRIPTS)
 .c.o: .depend
        $(QUIET_CC)$(CC) -o $@ -c $(CFLAGS) $(CPPFLAGS) $<
 
+t/stest: $(T_OBJS)
+       $(QUIET_CC)$(CC) $(LDFLAGS) $(CFLAGS) -o $@ $(T_OBJS) $(LIBS) $(LDFLAGS)
+
 fio: $(OBJS)
        $(QUIET_CC)$(CC) $(LDFLAGS) $(CFLAGS) -o $@ $(OBJS) $(LIBS) $(LDFLAGS)
 
@@ -89,7 +96,7 @@ fio: $(OBJS)
 $(PROGS): .depend
 
 clean:
-       -rm -f .depend $(OBJS) $(PROGS) core.* core
+       -rm -f .depend $(OBJS) $(T_OBJS) $(PROGS) $(T_PROGS) core.* core
 
 cscope:
        @cscope -b -R