CLI tool
cnlohr/rawdrawandroid avatar
cnlohr/rawdrawandroid

rawdrawandroid: Build Android Apps in Pure C Without Java or Kotlin

Build android apps without any java, entirely in C and Make

4,318 stars261 forksCMIT

At a glance

What is it?
rawdrawandroid is a Makefile-based build framework for Android that compiles C source files directly into an APK using the NDK, bypassing Gradle, Android Studio's build system, and any Java or Kotlin code, producing APKs as small as 25kB for API 26.
Who is it for?
rawdrawandroid is for C developers who want to ship Android apps without learning Java or Kotlin, who are comfortable reading and editing a Makefile to understand exactly what commands are executed, and who accept that the tool has no warranty and no official app store track record. It is not for teams who need Jetpack components, Material Design widgets, Google Play Services APIs, or the standard Android testing infrastructure.
Can I use it commercially?
Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 91 days ago.
What is it written in?
Mainly C, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 25, 2026, and from our analysis. They are not legal advice.

Editorial analysis

What rawdrawandroid Does and Why It Exists

Standard Android development involves Gradle, Android Studio, a Java or Kotlin codebase, and a multi-megabyte build process. rawdrawandroid takes a different approach: it provides a Makefile that invokes the Android NDK toolchain directly, compiles your C source files, packages the result with an AndroidManifest, and produces a signed APK. The full build and install cycle takes approximately two seconds, according to the README, and the resulting APK is about 25kB for API 26 targets with a single architecture.

The author's stated motivation is that Makefile-based builds make the exact commands visible and modifiable. Everything that executes is in the Makefile, which makes it easy to add custom rules or tweak flags. The README also states the project is partly a response to online claims that certain things in Android require Java, particularly permission requests through the JNI: the tool demonstrates that they do not.

What You Get: Features Provided by the Framework

The framework gives you a working Android activity written in C with the following capabilities, as listed in the README:

- An OpenGL ES window for rendering - Accelerometer and gyroscope input - Multi-touch support - An Android software keyboard for text input - Access to asset files bundled in the APK via AAssetManager - Permission request support for things like audio capture - Direct access to USB devices

The framework also supports OpenXR on Meta Quest hardware, and the README links to the tsopenxr repository for that use case. Testing was done against Android API levels 22, 24, 28, 29, 30, 32, and 34. The ANDROIDVERSION Makefile variable defaults to 30, and ANDROIDTARGET defaults to ANDROIDVERSION.

Setting Up and Running Your First Build

The simpler path is installing Android Studio with NDK support, which handles dependency resolution. The leaner alternative is a command-line NDK install. Either way, you need Java for the APK signing step. Install the prerequisites on a Debian-based system:

bash
sudo apt install openjdk-17-jdk-headless adb

The README notes that openjdk-25 also works. Then clone the repository with submodules, which pulls in the rawdraw dependency:

bash
git clone https://github.com/cnlohr/rawdrawandroid --recurse-submodules
cd rawdrawandroid

Generate a signing key before building:

bash
make keystore

Connect an Android device with USB debugging enabled. Then build, push, and run in one step:

bash
make push run

This compiles test.c, packages the APK, installs it on the connected device, and launches it. The Makefile warns that APPNAME and PACKAGENAME must be overridden before shipping anything. The default package name is org.yourorg.cnfgtest, which is intended only for testing.

Debugging with lldb-server

Source-level debugging uses lldb-server pushed to the device. The README gives the exact sequence. First copy the lldb-server binary from the NDK to the device:

bash
adb push ~/Android/Sdk/ndk/<ver>/toolchains/llvm/prebuilt/linux-x86_64/lib/clang/19/lib/linux/aarch64/lldb-server /sdcard
adb shell run-as org.yourorg.cnfgtest cp /sdcard/lldb-server /data/data/org.yourorg.cnfgtest/
adb shell run-as org.yourorg.cnfgtest chmod +x /data/data/org.yourorg.cnfgtest/lldb-server

Then start the server on the device and connect from the host. This two-step process is the only supported debugging approach. There is no integration with Android Studio's debugger since the build system does not use Gradle or the IDE.

Limitations, Google Play Publishing, and Platform Coverage

The README carries a clear disclaimer: no warranty, no guarantee of support, use at your own risk. The author has never released an app on the Play Store and notes there may be fundamental issues with using this toolset for commercial apps.

Publishing to Google Play requires several manual steps. You need a real signing key, specific changes to your app's AndroidManifest, and compliance with Play's target API requirements. The README has a dedicated Play section that covers key generation and certificate export, but it is presented as guidance rather than a tested production workflow.

The tool was developed and tested on Arch Linux with GNOME on Xorg and Wayland. Some testing was done on Windows through WSL. The README describes Windows support as cursory. There is no CI verification for all combinations of desktop OS, NDK version, and Android API level. Makefile variable paths for SDK_LOCATIONS include ~/Android/Sdk and $(HOME)/Library/Android/sdk, so macOS is in the detection list, but Macs with Apple Silicon are not mentioned.

The Android API 30 minimum target (required by Google Play as of its current policies) increases the APK size to 45kB because it must include ARM64 and ARM32 binaries.

rawdrawandroid vs. Standard Android Studio Development

Android Studio with Kotlin or Java is the official supported path for Android applications. It provides access to Jetpack libraries, Material Design components, the full range of Google Play Services APIs, the built-in testing framework, and the UI toolkit. Developers who need any of those components cannot use rawdrawandroid as a direct replacement.

rawdrawandroid targets a specific niche: C developers who want to port existing C code (games, embedded tools, signal processing) to Android without rewriting in Java, and developers who want to understand the complete build chain without Gradle abstraction. The README points to the rawdraw project as a broader framework that runs on Windows, Linux, Raspberry Pi, and Android from the same C codebase. If you already have a rawdraw application on another platform, rawdrawandroid extends that to Android with the same source file.

Maintenance and License

The last push to the repository was on 2026-07-01. The Makefile header states the project is under the MIT/x11 or NewBSD License. Both licenses permit unrestricted use, modification, and redistribution. The repository has no GitHub releases. Development is tracked through commits on the master branch.

The project is a single-author repository with no public Discord invite at the time of the README. The author notes that contributors can reach out on Discord with a message explaining their reason, and an invite may be sent. There is no formal issue tracker process described in the README.

Editorial conclusion

rawdrawandroid is for C developers who want to ship Android apps without learning Java or Kotlin, who are comfortable reading and editing a Makefile to understand exactly what commands are executed, and who accept that the tool has no warranty and no official app store track record. It is not for teams who need Jetpack components, Material Design widgets, Google Play Services APIs, or the standard Android testing infrastructure. If you plan to ship on Google Play, read the Play section of the README before writing any code: it requires a real signing key, specific AndroidManifest changes, and several manual preparation steps that differ from the development workflow.

Frequently asked questions

Can rawdrawandroid build apps that run on Google Play?

The README includes a Google Play section covering signing keys and manifest changes, but the author notes they have never released a Play Store app with this toolset and there may be fundamental issues for commercial apps. Review the Play section of the README before committing to it for a production release.

What Android API levels does rawdrawandroid support?

The Makefile notes testing against API levels 22, 24, 28, 29, 30, 32, and 34. The ANDROIDVERSION variable defaults to 30. APK size increases from about 25kB at API 26 to about 45kB at API 30, which includes both ARM64 and ARM32 binaries.

Does rawdrawandroid work on Windows?

The README describes a GUI-less install path for Windows and WSL. The author notes that some testing was done on Windows by a contributor, but the primary development and testing environment is Linux. The Makefile includes windows-x86_64 in its OS detection.

Official sources

  1. cnlohr/rawdrawandroid on GitHub
  2. Issues
  3. License: MIT
  4. README
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/cnlohr-rawdrawandroid.svg)](https://hysenlabs.com/projects/cnlohr-rawdrawandroid)