Update comments for Doxygen. Move old, unused files to the testing folder.
[matches/MCTX3420.git] / server / Makefile
index 72d37de..10be3ec 100644 (file)
@@ -1,33 +1,39 @@
 # Makefile for server software
 CXX = gcc
-FLAGS = -std=c99 -Wall -Werror -pedantic -g
-LIB = -lfcgi -lssl -lcrypto -lpthread -lm
-OBJ = log.o control.o sensor.o fastcgi.o thread.o main.o
+FLAGS = -std=gnu99 -Wall -pedantic -g -I/usr/include/opencv -I/usr/include/opencv2/highgui -L/usr/lib `mysql_config --cflags`
+LIB = -lfcgi -lssl -lcrypto -lpthread -lm -lopencv_highgui -lopencv_core -lopencv_ml -lopencv_imgproc -lldap -lcrypt `mysql_config --libs`
+OBJ = log.o control.o data.o fastcgi.o main.o sensor.o actuator.o image.o bbb_pin.o pin_test.o login.o sensors/sensors.a actuators/actuators.a
 RM = rm -f
 
 BIN = server
-BIN2 = stream
+#BIN2 = stream
 
-all : $(BIN) $(BIN2)
+all :
+       $(MAKE) -C sensors
+       $(MAKE) -C actuators
+       $(MAKE) $(BIN)
 
-stream : stream.c
-       $(CXX) -o stream stream.c -I/usr/include/opencv -I/usr/include/opencv2/highgui -L/usr/lib -lopencv_highgui -lopencv_core -lopencv_ml -lopencv_imgproc -lm
 
 
 $(BIN) : $(OBJ)
        $(CXX) $(FLAGS) -o $(BIN) $(OBJ) $(LIB)
 
+microscope : microscope.o
+       $(CXX) $(FLAGS) -o microscope microscope.o $(LIB)
+
 
 %.o : %.c
        $(CXX) $(FLAGS) -c $<
 
 
-
 clean :
+       make -C sensors clean
+       make -C actuators clean
        $(RM) $(BIN) $(BIN2)
        $(RM) *.o
 
 clean_full: #cleans up all backup files
+       make -C sensors clean_full
        $(RM) $(BIN) $(BIN2) $(OBJ) $(LINKOBJ)
        $(RM) *.*~
        $(RM) *~

UCC git Repository :: git.ucc.asn.au