summaryrefslogtreecommitdiff
path: root/test/Makefile
blob: 25cf4d9c810b7cc2ae1cb3a438ebe3941f1562f3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
CFLAGS ?= -g -O2
XCFLAGS =
override CFLAGS += -Wall -D_GNU_SOURCE -L../src/ -I../src/include/

all_targets += poll poll-cancel ring-leak fsync io_uring_setup io_uring_register \
	       io_uring_enter nop sq-full cq-full 35fa71a030ca-test \
		917257daa0fe-test b19062a56726-test eeed8b54e0df-test link \
		send_recvmsg a4c0b3decb33-test 500f9fbadef8-test timeout \
		sq-space_left stdout cq-ready cq-peek-batch file-register \
		cq-size 8a9973408177-test a0908ae19763-test 232c93d07b74-test \
		socket-rw accept timeout-overflow defer read-write io-cancel

include ../Makefile.quiet

all: $(all_targets)

%: %.c
	$(QUIET_CC)$(CC) $(CFLAGS) -o $@ $< -luring $(XCFLAGS)

test_srcs := poll.c poll-cancel.c ring-leak.c fsync.c io_uring_setup.c \
	io_uring_register.c io_uring_enter.c nop.c sq-full.c cq-full.c \
	35fa71a030ca-test.c 917257daa0fe-test.c b19062a56726-test.c \
	eeed8b54e0df-test.c link.c send_recvmsg.c a4c0b3decb33-test.c \
	500f9fbadef8-test.c timeout.c sq-space_left.c stdout.c cq-ready.c\
	cq-peek-batch.c file-register.c cq-size.c 8a9973408177-test.c \
	a0908ae19763-test.c 232c93d07b74-test.c socket-rw.c accept.c \
	timeout-overflow.c defer.c read-write.c io-cancel.c

test_objs := $(patsubst %.c,%.ol,$(test_srcs))

35fa71a030ca-test: XCFLAGS = -lpthread
232c93d07b74-test: XCFLAGS = -lpthread
send_recvmsg: XCFLAGS = -lpthread

clean:
	rm -f $(all_targets) $(test_objs)

runtests:
	@./runtests.sh $(all_targets)
runtests-loop:
	@./runtests-loop.sh $(all_targets)