mastodont-c/Makefile
me@ow.nekobit.net 71a358001c Handle multiple errors (somewhat)
FossilOrigin-Name: 2145b0a4409a8f4d6eb5e999b2c7275a34f20a7dede06fddd6f8d360aed765b9
2022-04-27 18:36:50 +00:00

18 lines
351 B
Makefile

CC ?= cc
CFLAGS = -g -ansi -Wall -Werror=implicit-function-declaration -I ./include/ `pkg-config --cflags libcjson`
SRC = $(wildcard src/*.c)
OBJ = $(patsubst %.c,%.o,$(SRC))
TARGET = libmastodont.a # shared
AR = ar
all: static
static: $(OBJ)
$(AR) rcs $(TARGET) $(OBJ)
%.o: %.c
$(CC) $(CFLAGS) -c $< -o $@
clean:
rm -f $(TARGET)
rm -f $(OBJ)