I interpret the message "non-system libraries in the linker flags" as a warning that you are not using the default system libraries (in usr/lib ), which can be completely accurate, but which can also lead to errors (incompatibility between versions of different libraries) . Does this warning mean that you are completely up to you.
Then, about how you tried to solve it, I think you mistakenly use the LOCAL_SHARED_LIBRARIES NDK variable.
Paste here a sample from one of my Android.mk files that uses Assimp
As you can see, I declare LOCAL_MODULE with a custom name, configure several variables, and then include a PREBUILT_STATIC_LIBRARY script that tells the NDK to use this library.
Then, in LOCAL_STATIC_LIBRARIES I list the libraries that I use with their module name , but not as if it were a linker flag, as you do here.
In your case, I believe you should do the following, for example for stl
include $(CLEAR_VARS) LOCAL_MODULE := STLPortShared LOCAL_EXPORT_C_INCLUDES := <path to stlport includes> LOCAL_SRC_FILES := <path to stlport library> include $(PREBUILT_SHARED_LIBRARY) ...
I think this should do it. Of course, repeat the process for each libs that causes problems, and don't forget to include(CLEAR_VARS) between each lib specification.
source share