Reputation:
Following is my CMakeLists.txt file
cmake_minimum_required(VERSION 3.4.1)
add_library( native-lib SHARED src/main/cpp/native-lib.cpp )
find_library( log-lib log )
target_link_libraries( native-lib ${log-lib} )
I have specified, SHARED
in add_library
since I want a shared object library.
But it is not giving me the so file.
what am I missing?
Upvotes: 1
Views: 1807
Reputation: 159
You know that CMake doesn't compile anything ? It just configures a Makefile (or IDE project's files) for you.
Generate your Makefile / Visual Studio / What ever you use file project via CMake and then compile.
You will have your library then ;)
Upvotes: 2