Skip to content

bulid bither android

姜家志 edited this page Jan 8, 2015 · 7 revisions

Bulid bither-android

To get started, ensure you have the latest JDK and Android SDK installed .

We use the submodle(bitherj) of bitherj

You can use "git clone git@github.com:bither/bither-android.git --recursive" to clone bither-android

or if you have already cloned bither-android , you can execute the following commands

git submodule init
git submodule update

You must configure the path of JDK and Android SDK.

echo "export ANDROID_HOME='Your android sdk path'" >> ~/.bash_profile
source ~/.bash_profile

Make sure com.android.support .

Open Android Studio -> Tools -> Android -> SDK Manager.
Make sure Extras/Android Support Repository and Extras/Android Support Library are checked.
Click Install packages and wait util the packages are installed successfully.

We use Gradle(1.10) compilation our project .

Gradle: http://www.gradle.org/downloads

You must use gradle (v1.10)

Now try running one of the example apps:

cd ../bither-android 
gradle assembleDebug

You will get apk from ../bither-android/build/outputs/apk/bither-android-debug.apk

Run bither-android in Android Studio

If you want to modify the our code . You can use Android Studio

 Android Studio : https://developer.android.com/sdk/installing/studio.html

Set JDK and SDK Location of Android Studio .

  File->Project Structure into Project Structure->SDK Location-> JDK location
  File->Project Structure into Project Structure->SDK Location->Android SDK location

Set Gradle of Android Studio

 Preferences->Gradle->Use Local gradle distribution

You can import project

 File->Import Project  , Select  "bither-android" in the dir 
Clone this wiki locally