0

I am trying to compile json-c for Android. I am not able to configure using Android.configure.mk file in json-c library in this source code.

I tried compiling using the command

   make -f Android.configure.mk

Will anyone please let me know how to use this Android.configure.mk with androgenizer?.

Karthick pop
  • 616
  • 3
  • 16
Suman
  • 4,221
  • 7
  • 44
  • 64

1 Answers1

1

Json-c Android Cygwin native build

1, get the Json-c code

$git clone https://github.com/json-c/json-c/json-c.git

2, automake the project need to install libtool, autoconf, automake

$sh autogen.sh
$./configure

3, build the android objects Actually in the step 2 we generate the config.h and json_config.h. What we need is an android.mk file. We can generate the file by

$make -f Makefile.am Android.mk

Before run the command, we need to copy the androgenizer.exe to /cygwin_dir/bin

$ndk-build NDK_PROJECT_PATH=$(pwd) APP_BUILD_SCRIPT=$(pwd)/Android.mk

then we generate the libjson-c.so at .\libs\armeabi\

Alex Song
  • 11
  • 1
  • Thanks for the info. I already did as mentioned in this link steps: http://freelancer-suman.blogspot.in/p/steps-for-porting-json-c-for-android.html – Suman Sep 24 '14 at 07:28