summaryrefslogtreecommitdiff
path: root/Makefile
blob: f9d958d7af5537f5b30e4cdb479e7a372fcc7042 (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
29
30
# gridcal - compute great-circle distance between two grid locators 
.POSIX:

SRC = gridcal.c getgrid.c
OBJ = ${SRC:.c=.o}
PROG= gridcal getgrid

all: options gridcal getgrid

options:
	@echo "-+- build options -+-"
	@echo "PREFIX  = ${PREFIX}"
	@echo "CFLAGS  = ${CFLAGS}"
	@echo "LDFLAGS = ${LDFLAGS}"
	@echo "CC      = ${CC}"
	@echo "-+-+-+-+-+-+-+-+-+-+-" 

gridcal: ${OBJ}
	$(CC) $(LDFLAGS) -o $@ gridcal.o -lm

getgrid: ${OBJ}
	$(CC) $(LDFLAGS) -o $@ getgrid.o -lm


debug: clean
	${MAKE} CFLAGS="${DEBUG}" all

clean:
	rm -f ${PROG} ${OBJ}