Build Rsync for Android Yourself

To build rsync for Android you’ll need to have the Android NDK installed already.

Then clone the rsync for android source (e.g. from CyanogenMod LineageOS) …

… create the missing jni/Application.mk  build file (e.g. from this Gist) and adapt it to your case

… and start the build with

You’ll find your self-build rsync in obj/local/*/rsync . 😀

Update 2017-10-06:

  • Updated sources from CyanogenMod to LineageOS.
  • Added links to Gist and Andoid NDK docs
  • Updated steps to work with up-to-date setups

If you get something like the following warnings and errors …

… you probably need to update config.h and change /* #undef MAJOR_IN_SYSMACROS */ to #define MAJOR_IN_SYSMACROS 1 .

3 thoughts on “Build Rsync for Android Yourself”

  1. Android NDK: APP_PLATFORM not set. Defaulting to minimum supported version android-14.    Android NDK: There is no Android.mk under /data/rsync-android/android_external_rsync/jni    Android NDK: If this is intentional  please define APP_BUILD_SCRIPT to point   Android NDK: to a valid NDK build script.    /opt/android-ndk/build/core/add-application.mk:116: *** Android NDK: Aborting…    .  Stop. well you need to provide something for the Application.mk, don’t you?

    1. Sorry, I didn’t notice there was no link to the Gist in the text. Now it’s there. 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *