Add libretro-build-android-mips.sh

This commit is contained in:
twinaphex 2015-08-04 04:30:27 +02:00
parent 39b0f2c654
commit 8ced0c59b1
2 changed files with 51 additions and 2 deletions

17
libretro-build-android-mips.sh Executable file
View File

@ -0,0 +1,17 @@
#! /usr/bin/env bash
# vim: set ts=3 sw=3 noet ft=sh : bash
SCRIPT="${0#./}"
BASE_DIR="${SCRIPT%/*}"
WORKDIR="$PWD"
if [ "$BASE_DIR" = "$SCRIPT" ]; then
BASE_DIR="$WORKDIR"
else
if [[ "$0" != /* ]]; then
# Make the path absolute
BASE_DIR="$WORKDIR/$BASE_DIR"
fi
fi
platform=android-mips ${BASE_DIR}/libretro-build.sh $@

View File

@ -58,7 +58,6 @@ case "$platform" in
;;
esac
export NDK_ROOT_DIR
echo ${NDK_ROOT_DIR}
CC="$NDK_ROOT_DIR/toolchains/arm-linux-androideabi-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/arm-linux-androideabi-gcc"
CXX="$NDK_ROOT_DIR/toolchains/arm-linux-androideabi-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/arm-linux-androideabi-g++"
CXX11="$NDK_ROOT_DIR/toolchains/arm-linux-androideabi-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/arm-linux-androideabi-g++"
@ -87,12 +86,39 @@ case "$platform" in
;;
esac
export NDK_ROOT_DIR
echo ${NDK_ROOT_DIR}
CC="$NDK_ROOT_DIR/toolchains/arm-linux-androideabi-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/arm-linux-androideabi-gcc"
CXX="$NDK_ROOT_DIR/toolchains/arm-linux-androideabi-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/arm-linux-androideabi-g++"
CXX11="$NDK_ROOT_DIR/toolchains/arm-linux-androideabi-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/arm-linux-androideabi-g++"
;;
android-mips)
FORMAT_ABI="mips"
DIST_DIR="android/${FORMAT_ABI}"
FORMAT_EXT=so
FORMAT=.android_${FORMAT_ABI}
FORMAT_COMPILER_TARGET=android-${FORMAT_ABI}
FORMAT_COMPILER_TARGET_ALT=android-${FORMAT_ABI}
FORMAT_ABI_ANDROID=yes
UNAME_PLATFORM="$(uname)"
HOST_PLATFORM="linux"
case "$UNAME_PLATFORM" in
osx|*Darwin*)
HOST_PLATFORM="darwin"
;;
win|*mingw32*|*MINGW32*|*MSYS_NT*)
HOST_PLATFORM="windows"
;;
win64|*mingw64*|*MINGW64*)
HOST_PLATFORM="windows"
;;
esac
export NDK_ROOT_DIR
CC="$NDK_ROOT_DIR/toolchains/mipsel-linux-android-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/mipsel-linux-android-gcc"
CXX="$NDK_ROOT_DIR/toolchains/mipsel-linux-android-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/mipsel-linux-android-g++"
CXX11="$NDK_ROOT_DIR/toolchains/mipsel-linux-android-4.8/prebuilt/${HOST_PLATFORM}-x86_64/bin/mipsel-linux-android-g++"
;;
qnx)
DIST_DIR="qnx"
FORMAT_EXT=so
@ -285,6 +311,12 @@ case "$platform" in
FORMAT_COMPILER_TARGET="${platform}"
DIST_DIR="android/armeabi-v7a"
;;
android-mips)
platform=android-mips
FORMAT_EXT="so"
FORMAT_COMPILER_TARGET="${platform}"
DIST_DIR="android/mips"
;;
theos_ios*)
platform=theos_ios
FORMAT_EXT="dylib"