INCLUDE_DIRS = -I .. -L..
ERROR_LEVEL = 0
CFLAGS = -D ERROR_LEVEL=${ERROR_LEVEL} -g ${INCLUDE_DIRS} -Wall

all: charger

charger.o: charger.c
	gcc ${CFLAGS} -c charger.c

charger: charger.o ../smart_battery/smart_battery.o ../util/util.o \
	 ../xantrex_xfr/xfr.o ../serial/serial.o
	gcc $(CFLAGS) -o charger charger.o ../smart_battery/smart_battery.o ../util/util.o ../xantrex_xfr/xfr.o ../serial/serial.o

clean:
	rm *.o *~ charger.exe

