new makefile
This commit is contained in:
parent
27581edf32
commit
58884c9928
1 changed files with 7 additions and 13 deletions
20
Makefile
20
Makefile
|
@ -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
|
||||
rm -f ~/bin/herbe
|
||||
|
||||
clean:
|
||||
rm -f herbe
|
||||
|
||||
.PHONY: all install uninstall clean
|
||||
.PHONY: compile install uninstall
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue