Fix io piece logging to not have O(n) runtime
[fio.git] / Makefile
... / ...
CommitLineData
1#CC = /opt/intel/cce/9.1.045/bin/icc
2CC = gcc -W
3DEBUGFLAGS = -D_FORTIFY_SOURCE=2
4OPTFLAGS= -O2 -g $(EXTFLAGS)
5CFLAGS = -Wwrite-strings -Wall -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(OPTFLAGS) $(DEBUGFLAGS) -rdynamic
6PROGS = fio
7SCRIPTS = fio_generate_plots
8OBJS = gettime.o fio.o ioengines.o init.o stat.o log.o time.o md5.o crc32.o \
9 filesetup.o eta.o verify.o memory.o io_u.o parse.o mutex.o options.o \
10 rbtree.o
11
12OBJS += engines/cpu.o
13OBJS += engines/libaio.o
14OBJS += engines/mmap.o
15OBJS += engines/posixaio.o
16OBJS += engines/sg.o
17OBJS += engines/splice.o
18OBJS += engines/sync.o
19OBJS += engines/null.o
20OBJS += engines/net.o
21OBJS += engines/syslet-rw.o
22OBJS += engines/guasi.o
23
24INSTALL = install
25prefix = /usr/local
26bindir = $(prefix)/bin
27
28all: $(PROGS) $(SCRIPTS)
29
30fio: $(OBJS)
31 $(CC) $(CFLAGS) -o $@ $(filter %.o,$^) $(EXTLIBS) -lpthread -lm -ldl -laio -lrt
32
33clean:
34 -rm -f *.o .depend cscope.out $(PROGS) engines/*.o core.* core
35
36depend:
37 @$(CC) -MM $(ALL_CFLAGS) *.c engines/*.c 1> .depend
38
39cscope:
40 @cscope -b
41
42$(PROGS): | depend
43
44install: $(PROGS) $(SCRIPTS)
45 $(INSTALL) -m755 -d $(DESTDIR)$(bindir)
46 $(INSTALL) $(PROGS) $(SCRIPTS) $(DESTDIR)$(bindir)
47
48ifneq ($(wildcard .depend),)
49include .depend
50endif