How to compile libpomelo for Android
This is a tutorial on how to compile libpomelo for Android on Windows 7 (libpomelo is a C language client SDK for Pomelo).
1. download and extract Eclipse ADT with the Android SDK for Windows (with a single download, the Eclipse ADT bundle includes everything you need) to C:\Android\adt-bundle-windows-x86-20140702\, then download and extract the current Android NDK for Windows to C:\Android\android-ndk-r10c\ – if not yet done (use your paths accordingly if installed in other directories).
2. download and install git, select Use Git from the Windows Command Prompt during installation
3. run Eclipse ADT (C:\Android\adt-bundle-windows-x86-20140702\eclipse\eclipse.exe) and create a new project with File->New->Android Application Project, fill in some Application, project and package names, use the blank activity template (leave default workspace setting as C:\users\%yourusername%\workspace)
4. Left click on your project then select New -> Folder and choose jni as the folder name

5. Left click on this new folder and select New->File

name it Android.mk and paste this into
LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := libpomelo_shared LOCAL_MODULE_FILENAME := libpomelo LOCAL_WHOLE_STATIC_LIBRARIES := pomelo_static include $(BUILD_SHARED_LIBRARY) LOCAL_CFLAGS := -D__ANDROID__ $(call import-module,libpomelo)
6. Repeat step 5. and create a file in the same jni folder called Application.mk and fill it with
APP_ABI := armeabi armeabi-v7a x86
By default, the NDK build system will generate machine code only for the armeabi ABI. This corresponds to an ARMv5TE based CPU with software floating point operations. You can use APP_ABI to select a different ABI – the above APP_ABI definition creates 3 libraries with support for a ARMv5TE CPU, a ARMv7 with hardware FPU instructions and x86 devices.
7. Add a new folder as written in step 4., call it pomelo, open a terminal, navigate to this folder (e.g. C:\users\dennis\workspace\Test\pomelo\) and clone the libpomelo source into
git clone https://github.com/NetEase/libpomelo.git
8. Back in Eclipse with a Refresh on the pomelo folder should update your directory and file structure like this

9. navigate with a terminal to your root project folder and type
C:\Android\android-ndk-r10c\ndk-build NDK_MODULE_PATH=./pomelo/
to compile libpomelo for Android.
10. After a successful compilation you’ll find the libpomelo.so libraries in the appropriate folder in the libs\ folder.
No comments yet.
Leave a comment
About Dennis D. Spreen
Search
Recent Posts
- How to compile Lua 5.4.0 for Android as a dynamic library using Android Studio 4
- Please make inline vars usable for production – fix RSP-28892
- How to compile Lua 5.4.0 as a Mac OS X dynamic library
- How to compile Lua 5.4.0 for Linux as a shared library
- How to compile Lua 5.4.0 for Windows
- Daily Wage – a Spigot/Bukkit plugin that pays out a daily wage
- How to compile Lua 5.3.5 for Windows
- Better Collada exporter for Blender with custom properties
- MOS6502-delphi – a MOS 6502 CPU emulator for Delphi
- Pass a multidimensional array as a parameter (with a hidden caveat)
Categories
Tags
Archives
- May 2020
- March 2020
- June 2019
- March 2017
- August 2016
- July 2016
- June 2016
- January 2016
- September 2015
- February 2015
- January 2015
- October 2014
- September 2014
- August 2014
- May 2014
- March 2014
- February 2014
- November 2011
- June 2011
- February 2011
- March 2010
- September 2009
- August 2009
- July 2009
- May 2009
- March 2009
- February 2009
- January 2009
- November 2008
- October 2008
- February 2008
- June 2007
Delphi Feeds
- # Detect And Ban Web Attackers With An AI Judge In Free Pascal November 15, 2026
- Give Local AI Agents Short-Term And Long-Term Memory That Learns While You Chat November 13, 2026
- CodeBot 4 November 13, 2026
- Today's Episode of Testing with AI November 13, 2026
- Word Without Word: Build and Preview .docx Files Straight from Delphi November 13, 2026
- Build 1618 is available (TLS 1.3 Support) November 13, 2026
- An MCP Client Inside Your Delphi Application: the Dashboard's AI Assistant November 12, 2026
- Claude just deleted half of my C: drive November 12, 2026
- DPM Package Manager for Delphi - v1 Released November 12, 2026
- Death to Dependency Hell: Why I Built My Own Stack Instead of Gluing Together Everyone Else’s November 12, 2026

