blob: 74488eb91364e4e9935b4453a3cd3708eb41fc5c [file] [log] [blame]
yuezonghe824eb0c2024-06-27 02:32:26 -07001#*******************************************************************************
2# include ZTE library makefile
3#*******************************************************************************
4include $(COMMON_MK)
5
6##############USER COMIZE BEGIN################
7LIB_STATIC = libnvram.a
8LIB_SHARED = libnvram.so
9
10OBJS = nv_api.o cfg_api.o sys_infra.o cfg_api_wrapper.o
11
12CFLAGS += -g
13#LDFLAGS += -lpthread
14##############USER COMIZE END##################
15
16CFLAGS += -I$(APP_DIR)/include
17CFLAGS += -fPIC
18LDFLAGS += -shared
19
20all: $(LIB_STATIC) $(LIB_SHARED)
21
22$(LIB_STATIC) : $(OBJS)
23 $(AR) rcs $(LIB_STATIC) $(OBJS)
24
25$(LIB_SHARED): $(OBJS)
26 $(CC) $(LDFLAGS) -o $@ $^
27
28romfs:
29 $(ROMFSINST) $(LIB_SHARED) /lib/$(LIB_SHARED)
30
31clean:
32 -$(RM) *.a *.o *.so $(LIB_SHARED) $(LIB_STATIC) $(OBJS)
33