diff --git a/Makefile b/Makefile index 3f52658..7cf48b4 100644 --- a/Makefile +++ b/Makefile @@ -1,23 +1,9 @@ -include ../config.mk +include ./config.mk -SRCDIR := . -OBJS := crc.o +NAME := Crc -LIB := $(BUILD_DIR)/libcrc.a +GCC_SRCS := $(LIBSRC_PATH)/crc/crc.c -INCLUDES := . .. -DEFINES := - -all : $(LIB) - -$(LIB) : $(OBJS) - $(AR) -r $(LIB) $(OBJS) - -clean: - rm -f *.o - rm -f *.a - -.PHONY: clean - -include ../compile.mk +INCLUDES += -I $(LIBSRC_PATH) +include $(MAKE_HOME)/compile.mk diff --git a/config.mk b/config.mk new file mode 100644 index 0000000..bf77a39 --- /dev/null +++ b/config.mk @@ -0,0 +1,6 @@ +MAKE_HOME ?= /home/jens/work/software/make +CONFIG ?= debug +BUILD_DIR ?= ./build/${CONFIG} +MAKEFLAGS += --no-print-directory + +LIBSRC_PATH ?= $(realpath ../../libsrc)