392ef8cb81
FossilOrigin-Name: 63773000f0554657fd047c0416a22def13bb02da3eb18bfb87fcd6ba60fa55ae
21 lines
617 B
Makefile
21 lines
617 B
Makefile
CC ?= cc
|
|
MASTODONT_DIR = mastodont-c/
|
|
MASTODONT = $(MASTODONT_DIR)libmastodont.a
|
|
CFLAGS += -g -Wall -I ../$(MASTODONT_DIR)include/ -Wno-unused-variable -Wno-discarded-qualifiers -I/usr/include/ $(shell pkg-config --cflags libcurl libcjson libpcre)
|
|
LDFLAGS = -L./../$(MASTODONT_DIR) -lmastodont $(shell pkg-config --libs libcjson libcurl libpcre) -lfcgi
|
|
TARGET = tests
|
|
SRC = unit/main.c ../src/mime.c ../src/string.c
|
|
OBJ = $(patsubst %.c,%.o,$(SRC))
|
|
|
|
all: $(TARGET)
|
|
|
|
$(TARGET): $(OBJ)
|
|
$(CC) -o $(TARGET) $(OBJ) $(LDFLAGS)
|
|
|
|
%.o: %.c %.h
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
clean:
|
|
rm -f $(TARGET) $(OBJ)
|
|
|
|
.PHONY: all clean
|