I’m trying to find information on how to do add a post-build target for my static library that copies the library and its associated header files to a specific directory.
I read about LOCAL_EXPORT_C_INCLUDES but I’m still unsure what exactly it does, since it doesnt seem to copy headers for me.
Generally I want to copy the lib to $(LOCAL_PATH)/../lib and the headers $(LOCAL_PATH)/../include.
Add the following to the end of your
Android.mk, afterinclude $(BUILD_SHARED_LIBRARY):Note that make requires leading tab, not spaces before
cp.The last line could be defined differently to copy all include files available to the compiler:
But there is no way to automatically choose which
.hfiles should be copied, and which should be left alone.