aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: a7f0cb95976f329a2ebd9dface52317c6d45d9ec (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
31
32
33
34
35
36
37
.POSIX:
.SUFFIXES: .c .o

CC=cc
debug=-g -DDEBUG -DLOCAL
CFLAGS=$(MORE_CFLAGS) -Wall -Wpedantic

OBJS=bee.o irc.o util.o unix.o chanlist.o

all: apiobot
apiobot: $(OBJS)
	$(CC) $(CFLAGS) -o apiobot $(OBJS)

debug:
	make apiobot MORE_CFLAGS="-DDEBUG -DLOCAL -g"
local:
	make apiobot MORE_CFLAGS="-DLOCAL"
	
.c.o:
	$(CC) $(CFLAGS) -c $< -o $@

bee.o: bee.c irc.h unix.h conf.h debug.h chanlist.h
irc.o: irc.c irc.h debug.h conf.h util.h chanlist.h
thing.o: thing.c conf.h
unix.o: unix.c unix.h conf.h irc.h
util.o: util.c util.h debug.h conf.h
chanlist.o: chanlist.c


run: all
	./apiobot

dr: debug
	./apiobot

clean:
	rm *.o apiobot