A native C/C++ library for Android that builds a shared library libnative-lib.so featuring an ImGui overlay, hooking/memory utilities, and modern networking (HTTP/2/HTTP/3/TLS) via prebuilt libraries.
This project uses CMake (>= 3.10) and C++17.
- ImGui (Android + OpenGL ES 3 backends) for UI overlay
- Hooking & memory utilities: Dobby, KittyMemory (+ Keystone)
- Loader/symbol helper: xdl
- Networking: cURL + BoringSSL (crypto/ssl) + nghttp2 + nghttp3 + ngtcp2 (crypto)
- Supports multiple Android ABIs (as available under
prebuilt/)
/build/jni/
├─ CMakeLists.txt # Main build configuration
├─ hacks/hooks.h # Hook-related header
├─ include/ # Public and vendor headers
│ ├─ assets/ fonts/ includes/ menu/ vendor/ nlohmann/
│ ├─ vendor/stb_image.h # STB image header (upstream)
│ ├─ vendor/stb_image_resize2.h # STB resize header (upstream)
│ └─ color.h
├─ prebuilt/ # Per-ABI prebuilt static libraries
│ ├─ crypto/ ssl/ curl/ nghttp2/ nghttp3/ ngtcp2/ ngtcpc/ dobby/ include/
│ └─ README.md # Prebuilt library list
├─ src/
│ ├─ core/ # JNI, networking utils, app state, etc.
│ ├─ main/ # entry point, input hook
│ ├─ menu/ # ImGui menu/theme implementation
│ └─ third_party/
│ └─ stb_impl.cpp # STB compilation unit (image + resize2)
└─ third_party/
├─ ImGui/ # ImGui sources + backends
├─ KittyMemory/ # Memory utils (+ Keystone deps)
└─ xdl/ # Loader/symbol helper
Note: stb_image and stb_image_resize2 are integrated via headers under include/vendor and compiled through src/third_party/stb_impl.cpp. The previous reference to Layout_sample/ImGui/stb_image.cpp is no longer used.
- Dobby (static)
- BoringSSL (libcrypto, libssl) (static)
- cURL (static)
- nghttp2, nghttp3, ngtcp2, ngtcp2_crypto (static)
- KittyMemory (+ Keystone static per-ABI at
third_party/KittyMemory/Deps/Keystone/libs-android/${ANDROID_ABI}/libkeystone.a) - xdl (built from sources under
third_party/xdl) - ImGui (built from sources under
third_party/ImGui) - STB image + resize2 (headers in
include/vendor, compiled viasrc/third_party/stb_impl.cpp)
Refer to each library's license in its directory. Project license: set according to your needs.
- Android NDK installed (set
ANDROID_NDK_HOMEorANDROID_NDK_ROOT) - CMake >= 3.10
- Appropriate toolchain/SDK for the target ABI
Example build for arm64-v8a:
# 1) Create build directory
cmake -S . -B build-android-arm64 \
-DANDROID_ABI=arm64-v8a \
-DANDROID_PLATFORM=android-21 \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_TOOLCHAIN_FILE="$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake"
# 2) Compile
cmake --build build-android-arm64 -jThe output libnative-lib.so will be located under the build directory (e.g., build-android-arm64/). Repeat for other ABIs present in prebuilt/.
Important flags:
-DANDROID_ABI=...: pick one that exists (e.g.,armeabi-v7a,arm64-v8a,x86,x86_64) matching subfolders inprebuilt/<lib>/<ABI>/.-DANDROID_PLATFORM=android-21or as needed.
- Copy the resulting
.sointo your app'sjniLibs/structure, e.g.:
app/src/main/jniLibs/arm64-v8a/libnative-lib.so
- Ensure Gradle/AGP packages
jniLibsinto the APK/AAB. - Load the library from Java/Kotlin:
static {
System.loadLibrary("native-lib");
}- STB headers missing: ensure
include/vendor/stb_image.handinclude/vendor/stb_image_resize2.hexist (downloaded from upstream) and that thestb_imagetarget includesinclude/vendorintarget_include_directories. Also ensuresrc/third_party/stb_impl.cppdefines bothSTB_IMAGE_IMPLEMENTATIONandSTB_IMAGE_RESIZE2_IMPLEMENTATION. - ABI mismatch at link time: make sure
-DANDROID_ABImatches the ABI subfolders underprebuilt/(all required prebuilt libs must exist for the chosen ABI). - Missing headers: ensure include paths in CMake are correct and folders exist under
include/orthird_party/.
- Logging: use
logcat(the library links againstlog/android). - Graphics: backends use
EGLandGLESv3(ensure a valid OpenGL ES context during ImGui Android backend initialization).
This project combines work from multiple open-source libraries: ImGui, Dobby, KittyMemory, Keystone, xdl, cURL, BoringSSL, nghttp2/nghttp3/ngtcp2, STB, and others. Please respect each project's license.
