1+ # For more information about using CMake with Android Studio, read the
2+ # documentation: https://d.android.com/studio/projects/add-native-code.html.
3+ # For more examples on how to use CMake, see https://github.com/android/ndk-samples.
4+
5+ # Sets the minimum CMake version required for this project.
6+ cmake_minimum_required (VERSION 3.22.1)
7+
8+ # Declares the project name. The project name can be accessed via ${ PROJECT_NAME},
9+ # Since this is the top level CMakeLists.txt, the project name is also accessible
10+ # with ${CMAKE_PROJECT_NAME} (both CMake variables are in-sync within the top level
11+ # build script scope).
12+ project ("uprobechecker" )
13+
14+ # Creates and names a library, sets it as either STATIC
15+ # or SHARED, and provides the relative paths to its source code.
16+ # You can define multiple libraries, and CMake builds them for you.
17+ # Gradle automatically packages shared libraries with your APK.
18+ #
19+ # In this top level CMakeLists.txt, ${CMAKE_PROJECT_NAME} is used to define
20+ # the target library name; in the sub-module's CMakeLists.txt, ${PROJECT_NAME}
21+ # is preferred for the same purpose.
22+ #
23+ # In order to load a library into your app from Java/Kotlin, you must call
24+ # System.loadLibrary() and pass the name of the library defined here;
25+ # for GameActivity/NativeActivity derived applications, the same library name must be
26+ # used in the AndroidManifest.xml file.
27+ add_library (${CMAKE_PROJECT_NAME} SHARED
28+ # List C/C++ source files with relative paths to this CMakeLists.txt.
29+ native-lib.cpp)
30+
31+ # Specifies libraries CMake should link to your target library. You
32+ # can link libraries from various origins, such as libraries defined in this
33+ # build script, prebuilt third-party libraries, or Android system libraries.
34+ target_link_libraries (${CMAKE_PROJECT_NAME}
35+ # List libraries link to the target library
36+ android
37+ log )
0 commit comments