summaryrefslogtreecommitdiff
path: root/util_lib/Makefile
blob: f7a7d829991763c6ab0b8bfe9e7259db6183bb33 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#
# Utility function library
#
UTIL_LIB_SRCS:=util_lib/compute_ip_checksum.c
UTIL_LIB_SRCS+=util_lib/sha256.c
UTIL_LIB_OBJS:=$(patsubst %.c, %.o, $(UTIL_LIB_SRCS))
UTIL_LIB_DEPS:=$(patsubst %.c, %.d, $(UTIL_LIB_SRCS))
UTIL_LIB:=libutil.a

-include $(UTIL_LIB_DEPS)

$(UTIL_LIB): CPPFLAGS += -I$(srcdir)/util_lib/include

$(UTIL_LIB): $(UTIL_LIB_OBJS)
	@$(MKDIR) -p $(@D)
	$(AR) rs $(UTIL_LIB) $(UTIL_LIB_OBJS)