[PATCH] engines/Makefile had extra LIBS line
[fio.git] / Makefile
CommitLineData
ebac4655
JA
1CC = gcc
2CFLAGS = -Wall -O2 -g -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
3PROGS = fio
4SCRIPTS = fio_generate_plots
5
6all: depend $(PROGS) $(SCRIPTS)
2866c82d 7 $(MAKE) -C engines
ebac4655 8
6796209a 9fio: fio.o ioengines.o init.o stat.o log.o time.o md5.o crc32.o
2866c82d 10 $(CC) $(CFLAGS) -o $@ $(filter %.o,$^) -lpthread -laio -lm -lrt -ldl
ebac4655
JA
11
12clean:
2866c82d 13 -rm -f *.o .depend cscope.out $(PROGS) engines/*.o
ebac4655
JA
14
15depend:
16 @$(CC) -MM $(ALL_CFLAGS) *.c 1> .depend
17
592ef98a
JA
18cscope:
19 @cscope -b
20
ebac4655
JA
21INSTALL = install
22prefix = /usr/local
23bindir = $(prefix)/bin
2866c82d 24libdir = $(prefix)/lib/fio
ebac4655
JA
25
26install: $(PROGS) $(SCRIPTS)
27 $(INSTALL) -m755 -d $(DESTDIR)$(bindir)
28 $(INSTALL) $(PROGS) $(SCRIPTS) $(DESTDIR)$(bindir)
2866c82d
JA
29 $(INSTALL) -m755 -d $(DESTDIR) $(libdir)
30 $(INSTALL) engines/*.o $(libdir)
ebac4655
JA
31
32ifneq ($(wildcard .depend),)
33include .depend
34endif