Recently, I'v been developing a native c++ project with Android studio, which needs some other external open source libraries. I want to involve these libraries (for example, hello library)inside the Android Studio project by using CMake's add_subdirectory command to ease my code management. I refer the online guide doc from https://developer.android.com/studio/projects/configure-cmake, but not completely. Concretly, I add the following items to my top level CMakeList.txt:
set( lib_src_DIR /Users/dependencies/hello-1.1.1 ) set( lib_build_DIR /Users/dependencies/hello ) file(MAKE_DIRECTORY ${lib_build_DIR}) add_subdirectory( ${lib_src_DIR} ${lib_build_DIR} ) the whole top level CMakeLists.txt post as the following picture: 
Everything's done, I build this project, what I expect to see is libhello.a in the /Users/dependencies/hello directory, but there's only some Cmake related files, like following: 
Thers's no libhello.a found in the hello directory and its subdirectories, it seems like my hello library is not compiled at all. The following picture is my hello project's CMakeList.txt:
I'm sure this hello project can compile because I tried use cmake command to compile it directly, it's ok.
So, why add_subdirectory in the top level CMakeLists.txt don't work? Was I missing some other settings ? By the way, this top level CMakeLists.txt was genereated by the Android Studio automatically when I create the native C++ project, I just add something in it.
hellostatic library?