summaryrefslogtreecommitdiff
path: root/Makefile
blob: 75e1c39b3386fd6b6b3f42e2acbb39f3cdd9298b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
PREFIX := /usr/local
BIN_DIR := $(PREFIX)/bin

ifdef PCC
PCC_CFLAGS=-D__float128="long double"
else
PCC_CFLAGS=
endif


OBJS := $(patsubst %.c,%.o,$(wildcard *.c))

CFLAGS = $(PCC_CFLAGS) $(CFLAGS_EXTRA) -Wno-deprecated-declarations

OBJ_NAME = pullreqd

all : clean $(OBJ_NAME)

$(OBJ_NAME) : $(OBJS)
	$(CC) $(OBJS) $(CFLAGS) -lpthread -lgit2 -o $(OBJ_NAME)
%.o : %.c
	$(CC) -c $< -o $@ $(CFLAGS)
clean :
	rm -f $(OBJ_NAME) $(OBJS)
install :
	install -D -m755 $(OBJ_NAME) $(BIN_DIR)/$(OBJ_NAME)
uninstall :
	rm -f $(BIN_DIR)/$(OBJ_NAME)