forked from Xfennec/progress
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
22 lines (21 loc) · 683 Bytes
/
Copy pathMakefile
File metadata and controls
22 lines (21 loc) · 683 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
OBJ = cv
override CFLAGS += -g -Wall -D_FILE_OFFSET_BITS=64
override LFLAGS += -lncurses -lm
PREFIX ?= /usr/local
BINDIR = $(PREFIX)/bin
MANDIR = $(PREFIX)/share/man/man1
$(OBJ) : cv.o sizes.o hlist.o
$(CC) -Wall $^ -o $@ $(LFLAGS)
%.o : %.c
$(CC) $(CFLAGS) -c $^
clean :
rm -f *.o $(OBJ)
install : $(OBJ)
@echo "Installing program to $(DESTDIR)$(BINDIR) ..."
@mkdir -p $(DESTDIR)$(BINDIR)
@install -pm0755 $(OBJ) $(DESTDIR)$(BINDIR)/$(TARGET) || \
echo "Failed. Try "make PREFIX=~ install" ?"
@echo "Installing manpage to $(DESTDIR)$(MANDIR) ..."
@mkdir -p $(DESTDIR)$(MANDIR)
@install -pm0644 cv.1 $(DESTDIR)$(MANDIR)/ || \
echo "Failed. Try "make PREFIX=~ install" ?"