fdcreate/Makefile
2022-08-12 15:15:18 +00:00

21 lines
366 B
Makefile

CC?=gcc
CFLAGS?=-Os
CFLAGS+=-D_GNU_SOURCE
LDLIBS+=-lskarnet
PREFIX?=/usr
BINDIR=$(PREFIX)/bin
MANDIR=$(PREFIX)/share/man
all: fdcreate
clean:
@rm -f fdcreate fdcreate.o
check:
./fdcreate test [ -f /proc/self/fd/3 ]
install:
install -Dm755 fdcreate -t $(DESTDIR)$(BINDIR)
install -Dm644 fdcreate.1 -t $(DESTDIR)$(MANDIR)/man1
.PHONY: install check clean all