2019-10-23 16:58:19 +00:00
|
|
|
include ${TRICK_HOME}/share/trick/makefiles/Makefile.common
|
|
|
|
|
|
|
|
RM = rm -rf
|
|
|
|
CC = cc
|
|
|
|
CPP = c++
|
|
|
|
CURL = curl
|
|
|
|
MV = mv
|
|
|
|
CP = cp
|
|
|
|
MKDIR = mkdir
|
|
|
|
|
|
|
|
CFLAGS = -g -Wall
|
|
|
|
CPPFLAGS = -g -Wall -std=c++11
|
|
|
|
|
|
|
|
INCLUDE_DIRS = -Iinclude -I${TRICK_HOME}/include
|
|
|
|
|
|
|
|
OBJDIR = obj
|
|
|
|
LIBDIR = lib
|
|
|
|
INCDIR = include
|
|
|
|
|
|
|
|
#TRICK_LIB_DIR comes from Makefile.common
|
|
|
|
|
|
|
|
TRICK_HTTP_OBJS = \
|
|
|
|
${OBJDIR}/VariableServerSession.o \
|
|
|
|
${OBJDIR}/VariableServerVariable.o \
|
|
|
|
${OBJDIR}/http_GET_handlers.o \
|
|
|
|
${OBJDIR}/WebServer.o \
|
|
|
|
${OBJDIR}/simpleJSON.o
|
|
|
|
|
|
|
|
#############################################################################
|
|
|
|
## MODEL TARGETS ##
|
|
|
|
#############################################################################
|
|
|
|
|
2019-10-25 18:21:39 +00:00
|
|
|
all: ${TRICK_LIB_DIR}/libtrickHTTP.a
|
2019-10-23 16:58:19 +00:00
|
|
|
|
2019-10-25 18:21:39 +00:00
|
|
|
$(TRICK_HTTP_OBJS): $(OBJDIR)/%.o : src/%.cpp | $(OBJDIR)
|
2019-10-23 16:58:19 +00:00
|
|
|
$(CPP) $(CPPFLAGS) ${INCLUDE_DIRS} -c $< -o $@
|
|
|
|
|
2019-10-25 18:21:39 +00:00
|
|
|
${TRICK_LIB_DIR}/libtrickHTTP.a: ${TRICK_HTTP_OBJS}
|
2019-10-23 16:58:19 +00:00
|
|
|
ar crs $@ ${TRICK_HTTP_OBJS}
|
|
|
|
|
2019-10-25 18:21:39 +00:00
|
|
|
# ---------------------------------------------------------------------------
|
2019-10-23 16:58:19 +00:00
|
|
|
|
|
|
|
${OBJDIR}:
|
|
|
|
mkdir -p ${OBJDIR}
|
|
|
|
|
|
|
|
clean:
|
|
|
|
${RM} *~
|
|
|
|
${RM} ${OBJDIR}
|