majic/Makefile

23 lines
467 B
Makefile
Raw Normal View History

CFLAGS = -std=c99 -g -Wall -Werror
2020-07-09 14:21:08 +00:00
CPPFLAGS = -I$(ERL_EI_INCLUDE_DIR) -I/usr/local/include
LDFLAGS = -L$(ERL_EI_LIBDIR) -L/usr/local/lib
LDLIBS = -lpthread -lei -lm -lmagic
PRIV = priv/
RM = rm -Rf
2020-07-09 14:21:08 +00:00
ifeq ($(EI_INCOMPLETE),YES)
LDLIBS += -lerl_interface
CFLAGS += -DEI_INCOMPLETE
endif
2020-06-15 20:23:14 +00:00
all: priv/libmagic_port
2020-06-15 20:23:14 +00:00
priv/libmagic_port: src/libmagic_port.c
mkdir -p priv
2020-07-09 14:21:08 +00:00
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $< $(LDLIBS) -o $@
clean:
2020-06-14 16:39:46 +00:00
$(RM) $(PRIV)
.PHONY: clean