| SHELL = /bin/sh |
| RM = rm -f |
| |
| |
| LOCAL_CFLAGS := \ |
| -Wall \ |
| -g \ |
| -Wall \ |
| -fPIC \ |
| -shared \ |
| -D__COMPILE_OPTION__ \ |
| -D__LINUX_OS__ \ |
| |
| CPPFLAGS=\ |
| -std=c++11 \ |
| |
| LOCAL_PATH = . |
| $(warning ################# Typethree LOCAL_PATH:$(LOCAL_PATH),ROOT: $(ROOT),includedir:$(includedir),libdir:$(libdir)) |
| |
| LOCAL_C_INCLUDES = \ |
| -I$(LOCAL_PATH)/include \ |
| -I$(ROOT)$(includedir)/liblog \ |
| -I$(ROOT)$(includedir)/logger \ |
| -I$(ROOT)$(includedir)/include \ |
| |
| LOCAL_LIBS := \ |
| -L. \ |
| -ldl \ |
| -lrt \ |
| -llog \ |
| -lutils \ |
| -lcutils \ |
| -llynq-log \ |
| -lpthread \ |
| -llynq-codec \ |
| # -llynq-log \ |
| |
| $(warning libs=$(LOCAL_LIBS)) |
| |
| CXXSRC=\ |
| |
| SOURCES = $(wildcard *.c wildcard src/*.c) |
| |
| EXECUTABLE = liblynq-rtp.so |
| |
| COBJS=$(SOURCES:.c=.o) |
| $(warning test) |
| all: $(EXECUTABLE) |
| $(EXECUTABLE): $(COBJS) |
| $(CXX) -shared -Wl,--no-undefined $(COBJS) $(LOCAL_LIBS) $(LOCAL_CFLAGS) $(LOCAL_C_INCLUDES) -o $@ |
| |
| %.o: %.c |
| $(warning ----->build $<) |
| $(CC) $(LOCAL_C_INCLUDES) $(LOCAL_CFLAGS) $(LOCAL_LIBS) -o $@ -c $< |
| |
| .PHONY: install clean |
| install: |
| mkdir -p $(ROOT)$(base_libdir)/ |
| install $(EXECUTABLE) $(ROOT)$(base_libdir)/ |
| |
| clean: |
| rm -f $(EXECUTABLE) rm -rf *.o |
| find ./ -name *.o | xargs rm -rf |