Browse Source

travis: build for android, not publish until touch controls are not done

pull/2/head
Alibek Omarov 5 years ago
parent
commit
61f49938e5
  1. 29
      .travis.yml
  2. 32
      scripts/travis_android_deps.sh

29
.travis.yml

@ -66,20 +66,21 @@ jobs: @@ -66,20 +66,21 @@ jobs:
after_script:
- ccache --show-stats
- sh scripts/continious_upload.sh xash3d-fwgs-${ARCH}.AppImage xashds-linux-${ARCH}
# - # ...
# name: "Build for Android"
# cache: ccache
# os: linux
# dist: xenial
# before_script:
# - sh scripts/travis_common_deps.sh
# - sh scripts/travis_${TRAVIS_OS_NAME}_deps.sh
# - export ANDROID_HOME=$PWD/android-sdk-linux
# - export PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools:$PWD/android-ndk
# script:
# - sh scripts/build_${TRAVIS_OS_NAME}_engine.sh
# after_script:
# - ccache --show-stats
- # ...
name: "Build for Android"
cache: ccache
os: linux
dist: xenial
before_script:
- sh scripts/travis_common_deps.sh
- sh scripts/travis_android_deps.sh
- export ANDROID_SDK_HOME=$TRAVIS_BUILD_DIR/sdk
- export ANDROID_NDK_HOME=$ANDROID_SDK_HOME/ndk-bundle
script:
- cd android
- sh compile.sh
after_script:
- ccache --show-stats
# - sh scripts/continious_upload.sh xash3d-fwgs.apk
# - # ...
# name: "Build for Windows MinGW"

32
scripts/travis_android_deps.sh

@ -0,0 +1,32 @@ @@ -0,0 +1,32 @@
#!/bin/bash
echo "Download HLSDK"
cd $TRAVIS_BUILD_DIR
git clone --depth 1 --recursive https://github.com/FWGS/hlsdk-xash3d hlsdk || exit 1
echo "Download Android SDK"
mkdir -p sdk && cd sdk
wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip -qO sdk.zip > /dev/null 2>/dev/null || exit 1
echo "Unpack Android SDK"
unzip sdk.zip > /dev/null 2>/dev/null || exit 1
echo "Download all needed tools and NDK"
cd tools/bin || exit 1
./sdkmanager --install build-tools\;29.0.1 platform-tools platforms\;android-19 ndk-bundle
echo "Download Xash3D FWGS Android source"
git clone --depth 1 https://github.com/FWGS/xash3d-android-project -b waf android || exit 1
cd android
echo "Fetching submodules"
git submodule update --init xash-extras || exit 1
ln -s $TRAVIS_BUILD_DIR xash3d-fwgs-sl
echo "Installed Xash3D FWGS source symlink"
ln -s $TRAVIS_BUILD_DIR/hlsdk hlsdk-xash3d-sl
echo "Install HLSDK source symlink"
cd $TRAVIS_BUILD_DIR
Loading…
Cancel
Save