~umgeher/herbe

58884c99287cb2846462b40e8c58dff392d5361c — Umgeher Torgersen 2 years ago 27581ed
new makefile
1 files changed, 7 insertions(+), 13 deletions(-)

M Makefile
M Makefile => Makefile +7 -13
@@ 3,22 3,16 @@ CFLAGS = -Wall -Wextra -pedantic -I/usr/X11R6/include -L/usr/X11R6/lib -lX11 -lX
PREFIX ?= /usr/local
CC ?= cc

all: herbe

config.h: config.def.h
compile:
	cp config.def.h config.h

herbe: herbe.c config.h
	$(CC) herbe.c $(CFLAGS) -o herbe

install: herbe
	mkdir -p ${DESTDIR}${PREFIX}/bin
	cp -f herbe ${DESTDIR}${PREFIX}/bin
install: compile
	mkdir -p ~/bin
	cp -f herbe ~/bin
	chmod +x ~/bin/herbe

uninstall:
	rm -f ${DESTDIR}${PREFIX}/bin/herbe

clean:
	rm -f herbe
	rm -f ~/bin/herbe

.PHONY: all install uninstall clean
.PHONY: compile install uninstall