Android CMake 使用Android Native library

首先使用

 

 

find_library( # Sets the name of the path variable.
              android-lib
              # Specifies the name of the NDK library that
              # you want CMake to locate.
              android)

再进行链接

 

target_link_libraries( # Specifies the target library.
                       native-lib
                       avcodec-56
                       avfilter-5
                       avformat-56
                       avutil-54
                       swresample-1
                       swscale-3
                       # Links the target library to the log library
                       # included in the NDK.
                      ${android-lib} ${log-lib}  )

 

 


posted @ 2017-06-30 16:11  清澈见底  阅读(266)  评论(0编辑  收藏  举报