You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

Makefile 659 B

1234567891011121314151617181920212223242526272829303132
  1. # -*- coding: utf-8 -*-
  2. ifeq ($(SDKPATH),)
  3. CURDIR := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
  4. SDKPATH = $(CURDIR)/arm64-v8a
  5. endif
  6. TARGET := libmace_loader.so
  7. all: $(TARGET)
  8. # can be find at NDK_ROOT/toolchains/llvm/prebuilt/linux-x86_64/bin/
  9. CXX = aarch64-linux-android21-clang++
  10. CXXFLAGS = -std=c++14 -I$(SDKPATH)/include \
  11. -Dmgb_mace_loader_init=mgb_c_opr_init
  12. DEBUG ?= 0
  13. ifeq ($(DEBUG), 1)
  14. CXXFLAGS += -O0 -g
  15. else
  16. CXXFLAGS += -O2
  17. endif
  18. LDFLAGS = -L$(SDKPATH)/lib -lmace -llog
  19. LDLIBS = -shared -fPIC
  20. $(TARGET): mace_loader.cpp extern_c_opr.h
  21. $(CXX) $(CXXFLAGS) $(LDLIBS) -o $@ $< $(LDFLAGS)
  22. clean:
  23. @rm -f $(TARGET)