mirror of
https://github.com/nodejs/node.git
synced 2024-11-30 15:30:56 +01:00
2790db5e3d
PR-URL: https://github.com/nodejs/node/pull/22997 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
24 lines
607 B
Bash
Executable File
24 lines
607 B
Bash
Executable File
#!/bin/bash
|
|
|
|
export TOOLCHAIN=$PWD/android-toolchain-arm
|
|
mkdir -p $TOOLCHAIN
|
|
API=${3:-24}
|
|
$1/build/tools/make-standalone-toolchain.sh \
|
|
--toolchain=arm-linux-androideabi-4.9 \
|
|
--arch=arm \
|
|
--install-dir=$TOOLCHAIN \
|
|
--platform=android-$API \
|
|
--force
|
|
export PATH=$TOOLCHAIN/bin:$PATH
|
|
export AR=arm-linux-androideabi-ar
|
|
export CC=arm-linux-androideabi-gcc
|
|
export CXX=arm-linux-androideabi-g++
|
|
export LINK=arm-linux-androideabi-g++
|
|
export PLATFORM=android
|
|
export CFLAGS="-D__ANDROID_API__=$API"
|
|
|
|
if [[ $2 == 'gyp' ]]
|
|
then
|
|
./gyp_uv.py -Dtarget_arch=arm -DOS=android -f make-android
|
|
fi
|