xbot/Makefile

29 lines
667 B
Makefile
Raw Normal View History

2015-03-24 10:12:35 +00:00
CC=gcc
CFLAGS=-g -std=gnu99 -c -lconfig -ldl -I./lib
BINFLAGS=-g -rdynamic -ldl -lconfig
2015-03-24 10:12:35 +00:00
SRC=./src
OBJ=./build
OBJECTS=$(OBJ)/*.o
EXEC=xbot
2015-04-07 16:44:37 +00:00
.PHONY: mods
2015-03-24 10:12:35 +00:00
main:
@rm -rf build
@mkdir build
2015-04-07 18:18:24 +00:00
$(CC) $(CFLAGS) $(SRC)/config.c -o $(OBJ)/config.o
2015-03-24 17:48:11 +00:00
$(CC) $(CFLAGS) $(SRC)/main.c -o $(OBJ)/main.o
$(CC) $(CFLAGS) $(SRC)/irc.c -o $(OBJ)/irc.o
$(CC) $(CFLAGS) $(SRC)/util.c -o $(OBJ)/util.o
$(CC) $(CFLAGS) $(SRC)/events.c -o $(OBJ)/events.o
$(CC) $(CFLAGS) $(SRC)/module.c -o $(OBJ)/module.o
2015-03-24 10:12:35 +00:00
$(CC) -o $(EXEC) $(OBJECTS) $(BINFLAGS)
@echo "All Done!"
2015-04-07 16:44:37 +00:00
mods:
2015-04-18 15:51:15 +00:00
$(MAKE) -C mods/hello
2015-04-08 18:56:32 +00:00
$(MAKE) -C mods/autojoin
2015-04-18 15:51:15 +00:00
$(MAKE) -C mods/uptime
2015-04-07 16:44:37 +00:00
2015-03-24 10:12:35 +00:00
clean:
@rm -rf build $(EXEC)