CC = gcc
CFLAGS = -Wall -Wextra -std=gnu11 -O2
TARGET = test-syscalls
SRCS = main.c \
test-openat.c \
test-read.c \
test-write.c \
test-close.c \
test-dup.c \
test-dup2.c \
test-stat.c \
test-fstat.c \
test-lstat.c \
test-getdents64.c \
test-append.c \
test-pread-sparse.c \
test-link.c \
test-unlink.c \
test-copyup-inode-stability.c \
test-rename.c \
test-mknod.c \
test-mkfifo.c \
test-copyup-permissions.c \
test-open-readonly.c
OBJS = $(SRCS:.c=.o)
all: $(TARGET)
$(TARGET): $(OBJS)
$(CC) $(CFLAGS) -o $(TARGET) $(OBJS)
%.o: %.c test-common.h
$(CC) $(CFLAGS) -c $< -o $@
clean:
rm -f $(TARGET) $(OBJS)
.PHONY: all clean