aboutsummaryrefslogtreecommitdiff
path: root/tools/buildsteps
diff options
context:
space:
mode:
authorMemphiz <memphis@machzwo.de>2015-01-23 13:37:43 +0100
committerMemphiz <memphis@machzwo.de>2015-01-23 19:04:13 +0100
commitbdc80fec39a40ae46c897264f2b59420a43d5b7e (patch)
tree7fd274bd1622bde6672a170920d4e33f57a914d1 /tools/buildsteps
parent52ff0d56a47ec2e3eb411706009c0dd1f484896f (diff)
[jenkins/droid] - allow to select the ndk version through jenkins jobs and bump to ndk r10d
Diffstat (limited to 'tools/buildsteps')
-rw-r--r--tools/buildsteps/android/configure-depends9
-rw-r--r--tools/buildsteps/androidx86/configure-depends9
-rw-r--r--tools/buildsteps/defaultenv13
3 files changed, 24 insertions, 7 deletions
diff --git a/tools/buildsteps/android/configure-depends b/tools/buildsteps/android/configure-depends
index 8d9bcced41..344750c04e 100644
--- a/tools/buildsteps/android/configure-depends
+++ b/tools/buildsteps/android/configure-depends
@@ -2,15 +2,20 @@ WORKSPACE=${WORKSPACE:-$( cd $(dirname $0)/../../.. ; pwd -P )}
XBMC_PLATFORM_DIR=android
. $WORKSPACE/tools/buildsteps/defaultenv
+NDK_ARCH="arm"
+#the following pathes must exist on the slave and use the defined scheme here!
+CURRENT_NDK_PATH=$ANDROID_DEV_ROOT/android-ndk-r$NDK_VERSION
+CURRENT_TOOLCHAIN=$ANDROID_DEV_ROOT/android-toolchain-$NDK_ARCH-$SDK_VERSION-r$NDK_VERSION
+
if [ "$(rebuildDepends)" == "1" ]
then
cd $WORKSPACE/tools/depends;./configure \
--with-tarballs=$TARBALLS \
--host=arm-linux-androideabi \
--with-sdk-path=$SDK_PATH \
- --with-ndk=$NDK_PATH \
+ --with-ndk=$CURRENT_NDK_PATH \
$(if [ "$SDK_VERSION" != "Default" ]; then echo --with-sdk=android-$SDK_VERSION;fi) \
- --with-toolchain=$TOOLCHAIN \
+ --with-toolchain=$CURRENT_TOOLCHAIN \
--prefix=$XBMC_DEPENDS_ROOT \
--enable-neon
fi
diff --git a/tools/buildsteps/androidx86/configure-depends b/tools/buildsteps/androidx86/configure-depends
index 9fc2ad876f..89fd36f34b 100644
--- a/tools/buildsteps/androidx86/configure-depends
+++ b/tools/buildsteps/androidx86/configure-depends
@@ -2,14 +2,19 @@ WORKSPACE=${WORKSPACE:-$( cd $(dirname $0)/../../.. ; pwd -P )}
XBMC_PLATFORM_DIR=android
. $WORKSPACE/tools/buildsteps/defaultenv
+NDK_ARCH=x86
+#the following pathes must exist on the slave and use the defined scheme here!
+CURRENT_NDK_PATH=$ANDROID_DEV_ROOT/android-ndk-r$NDK_VERSION
+CURRENT_TOOLCHAIN=$ANDROID_DEV_ROOT/android-toolchain-$NDK_ARCH-$SDK_VERSION-r$NDK_VERSION
+
if [ "$(rebuildDepends)" == "1" ]
then
cd $WORKSPACE/tools/depends;./configure \
--with-tarballs=$TARBALLS \
--host=i686-linux-android \
--with-sdk-path=$SDK_PATH \
- --with-ndk=$NDK_PATH \
+ --with-ndk=$CURRENT_NDK_PATH \
$(if [ "$SDK_VERSION" != "Default" ]; then echo --with-sdk=android-$SDK_VERSION;fi) \
- --with-toolchain=$TOOLCHAIN_X86 \
+ --with-toolchain=$CURRENT_TOOLCHAIN \
--prefix=$XBMC_DEPENDS_ROOT
fi
diff --git a/tools/buildsteps/defaultenv b/tools/buildsteps/defaultenv
index 76ebb84a52..78ea7a0124 100644
--- a/tools/buildsteps/defaultenv
+++ b/tools/buildsteps/defaultenv
@@ -1,5 +1,6 @@
BUILDTHREADS=${BUILDTHREADS:-1}
SDK_VERSION=${SDK_VERSION:-"Default"}
+NDK_VERSION=${NDK_VERSION:-"Default"}
Configuration=${Configuration:-"Default"}
XBMC_DEPENDS_ROOT=${XBMC_DEPENDS_ROOT:-"Default"}
PATH_CHANGE_REV_FILENAME=".last_success_revision"
@@ -34,7 +35,8 @@ case $XBMC_PLATFORM_DIR in
;;
android)
- DEFAULT_SDK_VERSION="Default"
+ DEFAULT_SDK_VERSION="14"
+ DEFAULT_NDK_VERSION="10d"
DEFAULT_XBMC_DEPENDS_ROOT=$WORKSPACE/tools/depends/xbmc-depends
DEFAULT_CONFIGURATION="Debug"
;;
@@ -56,6 +58,11 @@ then
SDK_VERSION=$DEFAULT_SDK_VERSION
fi
+if [ "$NDK_VERSION" == "Default" ]
+then
+ NDK_VERSION=$DEFAULT_NDK_VERSION
+fi
+
if [ "$XBMC_DEPENDS_ROOT" == "Default" ]
then
XBMC_DEPENDS_ROOT=$DEFAULT_XBMC_DEPENDS_ROOT
@@ -74,14 +81,14 @@ fi
#helper functions
-#hash a dir based on the git revision, SDK_PATH, NDK_PATH, SDK_VERSION, TOOLCHAIN TOOLCHAIN_X86 (for droidx86) and XBMC_DEPENDS_ROOT
+#hash a dir based on the git revision, SDK_PATH, NDK_PATH, NDK_VERSION, SDK_VERSION, TOOLCHAIN TOOLCHAIN_X86 (for droidx86) and XBMC_DEPENDS_ROOT
function getBuildHash ()
{
local checkPath
checkPath="$1"
local hashStr
hashStr="$(git rev-list HEAD --max-count=1 -- $checkPath)"
- hashStr="$hashStr $SDK_PATH $NDK_PATH $SDK_VERSION $TOOLCHAIN $TOOLCHAIN_X86 $XBMC_DEPENDS_ROOT"
+ hashStr="$hashStr $SDK_PATH $NDK_PATH $NDK_VERSION $SDK_VERSION $TOOLCHAIN $TOOLCHAIN_X86 $XBMC_DEPENDS_ROOT"
echo $hashStr
}