How to use Makefile wildcards/globbing on Android NDK JNI
Here is a short little thing I ran into a few days ago. Many of you may know how a normal Android Makefile looks, something like this: LOCAL_PATH := $( call my-dir) MY_PATH := $(LOCAL_PATH) TARGET_ABI := android-4-armeabi include $(CLEAR_VARS) LOCAL_MODULE := libmain LOCAL_C_INCLUDES := \ $(LOCAL_PATH) /Box2D \ $(LOCAL_PATH) /libpng \ $(LOCAL_PATH) /libzip \ LOCAL_CFLAGS := \ -g3 \ -ggdb \ -gstabs+ \ -DANDROID_NDK \ # Look here! LOCAL_SRC_FILES := \ main.cpp \ cool_file.cpp \ LOCAL_LDLIBS := -lGLESv1_CM -llog -lz LOCAL_STATIC_LIBRARIES := libBox2D libzip libpng include $(BUILD_SHARED_LIBRARY) Ok, notice the section LOCAL_SRC_FILES . If you have many files in your project this could grow huge. O(N) where N is...