2015-02-10 21:42:23 -05:00
|
|
|
# Install destination and prefix
|
|
|
|
DESTDIR ?=
|
2015-02-10 21:11:15 -05:00
|
|
|
PREFIX ?= /usr/local
|
|
|
|
|
|
|
|
# Build flags
|
2016-01-14 19:43:14 -05:00
|
|
|
OPTS = -std=gnu99
|
2015-02-10 21:11:15 -05:00
|
|
|
|
|
|
|
# Build rules
|
|
|
|
all: backly
|
|
|
|
.PHONY: all install clean
|
|
|
|
|
|
|
|
backly: backly.c Makefile
|
2016-01-14 19:43:14 -05:00
|
|
|
gcc $(OPTS) $(CFLAGS) -o backly backly.c
|
2015-02-10 21:11:15 -05:00
|
|
|
|
|
|
|
install: backly
|
2015-02-10 21:42:23 -05:00
|
|
|
install -Dm 0755 backly $(DESTDIR)/$(PREFIX)/bin/backly
|
2015-02-10 21:11:15 -05:00
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f backly
|