1 LOCAL_PATH := $(call my-dir) 2 3 include $(CLEAR_VARS) 4 LOCAL_MODULE := libfoo 5 LOCAL_SRC_FILES := foo.c 6 include $(BUILD_SHARED_LIBRARY) 7 8 include $(CLEAR_VARS) 9 LOCAL_MODULE := main 10 LOCAL_SRC_FILES := main.c 11 # Use linker flags to list libfoo.so at link time. 12 # ndk-build should warn about this. 13 LOCAL_LDLIBS := -lz -L$(NDK_APP_OUT)/local/$(TARGET_ARCH_ABI) -lfoo 14 include $(BUILD_EXECUTABLE) 15