Skip to content

Commit

Permalink
Android NDK build support in travis.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
syoyo committed Aug 4, 2015
1 parent 0dca898 commit 28c37b1
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
9 changes: 9 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,18 @@ language: cpp

compiler: gcc

before_install:
- sudo apt-get update -qq -y
- sudo apt-get install -qq -y libgd2-xpm ia32-libs ia32-libs-multiarch p7zip > /dev/null
- wget -q --timeout=120 http://dl.google.com/android/ndk/android-ndk-r10e-linux-x86.bin -O ndk.bin
- md5sum ndk.bin | grep c3edd3273029da1cbd2f62c48249e978
- 7zr x ndk.bin $(sed 's/^/ -xr!/g' ndk-excludes.txt) | awk '/^Extracting/ { i++; if (i > 50) {print; i = 0}}'
- export ANDROID_HOME=$(pwd)/android-sdk-linux

script:
- make
- make test
- (cd jni; make)

addons:
coverity_scan:
Expand Down
8 changes: 7 additions & 1 deletion jni/Makefile
Original file line number Diff line number Diff line change
@@ -1,2 +1,8 @@
ifeq ($(ANDROID_HOME),)
NDK ?= $(ANDROID_NDK)
else
NDK ?= $(lastword $(sort $(wildcard $(dir $(ANDROID_HOME))/android-ndk*)))
endif

all:
ndk-build
$(NDK)/ndk-build V=1

0 comments on commit 28c37b1

Please sign in to comment.