blob: 22a5e03b4e848e72236d69686d1c234564ce81a1 [file] [log] [blame]
ROOT = $(shell pwd)/../..
include ../Make.defines
LOCAL_PATH=$(BUILD_ROOT)/lynq_lib
INC_DIR +=
LIB_DIR +=
LIBS += -llog -lmbtk_lib
CFLAGS += -shared -Wl,-shared,-Bsymbolic
DEFINE +=
MY_FILES_PATH:=$(LOCAL_PATH)/src
#ifeq ($(CONFIG_MBTK_QL_SUPPORT),y)
#MY_FILES_PATH += $(LOCAL_PATH)/ql
#endif
#ifeq ($(CONFIG_MBTK_PLATFORM),linux)
#MY_FILES_PATH += $(LOCAL_PATH)/platform/linux
#endif
LOCAL_SRC_FILES = $(wildcard src/*.c) $(wildcard src/*.cpp)
OBJS = $(patsubst %.c, %.o, $(patsubst %.cpp, %.o, $(LOCAL_SRC_FILES)))
$(info OBJS = $(OBJS))
dtarget := $(OUT_DIR)/lib/liblynq_lib.so
all: $(dtarget)
$(dtarget): $(OBJS)
$(CC) $(CFLAGS) $(LIB_DIR) $(LIBS) $(OBJS) -o $@
%.o:%.c
$(CC) $(CFLAGS) $(INC_DIR) $(DEFINE) -c $< -o $@
%.o:%.cpp
$(CC) $(CFLAGS) $(INC_DIR) $(DEFINE) -c $< -o $@
clean:
rm -f $(OBJS) $(dtarget)