[PATCH] Separate io engines into separate loadable objects
[fio.git] / engines / Makefile
diff --git a/engines/Makefile b/engines/Makefile
new file mode 100644 (file)
index 0000000..2d8de7a
--- /dev/null
@@ -0,0 +1,20 @@
+CC     = gcc
+CFLAGS = -Wall -O2 -W -shared -rdynamic -fPIC
+ALL_CFLAGS = $(CFLAGS) -I.. -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
+LIBS   =
+OBJS   = fio-engine-sync.o fio-engine-splice.o fio-engine-mmap.o fio-engine-libaio.o fio-engine-posixaio.o fio-engine-sg.o fio-engine-cpu.o
+
+all: depend $(OBJS)
+
+depend:
+       @$(CC) -MM $(ALL_CFLAGS) *.c 1> .depend
+
+clean:
+       -rm -f *.o $(OBJS) .depend
+
+%.o: %.c
+       $(CC) $(ALL_CFLAGS) -o $*.o $<
+
+ifneq ($(wildcard .depend),)
+include .depend
+endif