Permalink
Fetching contributors…
Cannot retrieve contributors at this time
76 lines (62 sloc) 2.38 KB
language: java
branches:
excludes:
- gh-pages
notifications:
email: false
env:
global:
- ANDROID_SDK_VERSION="r22.0.1"
- ANDROID_BUILD_TOOLS_VERSION="r17"
- ANDROID_PLATFORM_TOOLS_VERSION="r17"
jdk:
- openjdk7
before_install:
# Update a system for ia32 libraries
# Just full upgrade of system and installing a ia32-libs not works
# It's debian based system, /very/ stable version only
- sudo apt-get update -qq
- if [ `uname -m` = x86_64 ]; then sudo apt-get install -qq --force-yes libgd2-xpm ia32-libs ia32-libs-multiarch; fi
# Base android sdk setup
- wget https://dl-ssl.google.com/android/android-sdk_${ANDROID_SDK_VERSION}-linux.tgz
- tar -zxf android-sdk_${ANDROID_SDK_VERSION}-linux.tgz
- export ANDROID_HOME=`pwd`/android-sdk-linux
- export ANDROID_BUILD_TOOLS_HOME=${ANDROID_HOME}/build-tools/17.0.0
- export PATH=${ANDROID_BUILD_TOOLS_HOME}:${ANDROID_HOME}/tools:${PATH}
- export BASEDIR=`pwd`
# Build tools
# Zip from repository contains android-*.*.* folder inside,
# we are need only a content from it
- mkdir -p ${ANDROID_BUILD_TOOLS_HOME}
- cd ${ANDROID_BUILD_TOOLS_HOME}
- export FILE=build-tools_${ANDROID_BUILD_TOOLS_VERSION}-linux.zip
- wget https://dl-ssl.google.com/android/repository/${FILE}
- unzip -q ${FILE}
- rm ${FILE}
- export FILE=$(ls)
- mv ${FILE}/* .
- rmdir ${FILE}
- cd ${BASEDIR}
# Platform tools unneed for build, but i know Google - crazy peoples
# In case of fire uncomment lines below
#- export FILE=platform-tools_${ANDROID_BUILD_TOOLS_VERSION}-linux.zip
#- wget https://dl-ssl.google.com/android/repository/${FILE}
#- unzip -q ${FILE}
#- rm ${FILE}
#- export PATH=${ANDROID_HOME}/platform-tools:${PATH}
# Android SDK Platform API 14
- export FILE=android-14_r03.zip
- wget https://dl-ssl.google.com/android/repository/${FILE}
- mkdir -p ${ANDROID_HOME}/platforms
- unzip -q ${FILE} -d ${ANDROID_HOME}/platforms
- mv ${ANDROID_HOME}/platforms/android-4.0.2 ${ANDROID_HOME}/platforms/android-14
- rm ${FILE}
- unset FILE
# We are should update Gradle, because Android Build Tools works with 1.6,
# but on travis installed 1.4
- wget http://downloads.gradle.org/distributions/gradle-1.6-all.zip
- unzip -q -o gradle-1.6-all.zip
- export PATH="${BASEDIR}/gradle-1.6/bin:${PATH}"
# Let's try to build...
install: gradle build
script: gradle check