Merged PR 1407725: Clean up scripts fro non Win platforms
Less scripts to run our build. Related work items: #15816394
This commit is contained in:
Родитель
d9013f4472
Коммит
1c47d75ea6
16
makeaosp-arm
16
makeaosp-arm
|
@ -1,16 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK=/home/xplatappxuser/android-ndk-r16b \
|
||||
-DCMAKE_SYSTEM_VERSION=19 \
|
||||
-DCMAKE_ANDROID_ARCH_ABI=armeabi \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE=MinSizeRel -DAOSP=on ..
|
||||
make
|
|
@ -1,16 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK=/home/xplatappxuser/android-ndk-r16b \
|
||||
-DCMAKE_SYSTEM_VERSION=27 \
|
||||
-DCMAKE_ANDROID_ARCH_ABI=arm64-v8a \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE=MinSizeRel -DAOSP=on ..
|
||||
make
|
|
@ -1,16 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK=/home/xplatappxuser/android-ndk-r16b \
|
||||
-DCMAKE_SYSTEM_VERSION=19 \
|
||||
-DCMAKE_ANDROID_ARCH_ABI=armeabi-v7a \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE=MinSizeRel -DAOSP=on ..
|
||||
make
|
16
makeaosp-x86
16
makeaosp-x86
|
@ -1,16 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK=/home/xplatappxuser/android-ndk-r16b \
|
||||
-DCMAKE_SYSTEM_VERSION=19 \
|
||||
-DCMAKE_ANDROID_ARCH_ABI=x86 \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE=MinSizeRel -DAOSP=on ..
|
||||
make
|
|
@ -0,0 +1,72 @@
|
|||
#!/bin/bash
|
||||
# script to build AOSP.
|
||||
|
||||
ndk=
|
||||
arch=x86
|
||||
build=MinSizeRel
|
||||
version=19
|
||||
|
||||
usage()
|
||||
{
|
||||
echo "usage: makeaosp [-ndk ndk_path] [-arch arch] [-v version] [-b buildType]"
|
||||
echo $'\t' "-ndk Path to Android NDK. Default $ANDROID_NDK_ROOT or $ANDROID_NDK"
|
||||
echo $'\t' "-arch Architecture ABI. Default x86"
|
||||
echo $'\t' "-v Android version. Default 19"
|
||||
echo $'\t' "-b Build type. Default MinSizeRel"
|
||||
}
|
||||
|
||||
printsetup()
|
||||
{
|
||||
echo "NDK Path:" $ndk
|
||||
echo "Architecture:" $arch
|
||||
echo "Version:" $version
|
||||
echo "Build Type:" $build
|
||||
}
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
case $1 in
|
||||
-ndk ) shift
|
||||
ndk=$1
|
||||
;;
|
||||
-arch ) shift
|
||||
arch=$1
|
||||
;;
|
||||
-b ) shift
|
||||
build=$1
|
||||
;;
|
||||
-v ) shift
|
||||
version=$1
|
||||
;;
|
||||
-h ) usage
|
||||
exit
|
||||
;;
|
||||
* ) usage
|
||||
exit 1
|
||||
esac
|
||||
shift
|
||||
done
|
||||
|
||||
if [ -z "$ndk" ] && [ -n "$ANDROID_NDK_ROOT" ]; then
|
||||
ndk="$ANDROID_NDK_ROOT"
|
||||
elif [ -z "$ndk" ] && [ -n "$ANDROID_ROOT"]; then
|
||||
ndk="$ANDROID_ROOT"
|
||||
elif [ -z "$ndk" ]; then
|
||||
echo "Android NDK not found"
|
||||
exit 1
|
||||
fi
|
||||
printsetup
|
||||
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK="$ndk" \
|
||||
-DCMAKE_SYSTEM_VERSION="$version" \
|
||||
-DCMAKE_ANDROID_ARCH_ABI="$arch" \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE="$build" -DAOSP=on ..
|
||||
make
|
|
@ -1,16 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir android
|
||||
cd android
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK=/users/rubengu/Library/Android/sdk/ndk-bundle \
|
||||
-DCMAKE_SYSTEM_VERSION=19 \
|
||||
-DCMAKE_ANDROID_ARCH_ABI=x86 \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE=MinSizeRel -DAOSP=on ..
|
||||
make
|
|
@ -1,17 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_SYSTEM_NAME=Android \
|
||||
-DCMAKE_ANDROID_NDK=/users/rubengu/Library/Android/sdk/ndk-bundle \
|
||||
-DCMAKE_SYSTEM_VERSION=19 \
|
||||
-DCMAKE_ANDROID_ARCH_ABI=x86 \
|
||||
-DCMAKE_ANDROID_NDK_TOOLCHAIN_VERSION=clang \
|
||||
-DCMAKE_ANDROID_STL_TYPE=c++_shared \
|
||||
-DCMAKE_BUILD_TYPE=Debug -DAOSP=on ..
|
||||
make
|
|
@ -0,0 +1,44 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac for ios
|
||||
build=MinSizeRel
|
||||
arch=x86_64
|
||||
|
||||
usage()
|
||||
{
|
||||
echo "usage: makemac [-b buildType]"
|
||||
echo $'\t' "-b Build type. Default MinSizeRel"
|
||||
echo $'\t' "-arch OSX Architecture. Default x86_64 (simulator)"
|
||||
}
|
||||
|
||||
printsetup()
|
||||
{
|
||||
echo "Build Type:" $build
|
||||
echo "Architecture:" $arch
|
||||
}
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
case $1 in
|
||||
-b ) shift
|
||||
build=$1
|
||||
;;
|
||||
-arch ) shift
|
||||
arch=$1
|
||||
;;
|
||||
-h ) usage
|
||||
exit
|
||||
;;
|
||||
* ) usage
|
||||
exit 1
|
||||
esac
|
||||
shift
|
||||
done
|
||||
printsetup
|
||||
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=$build -DIOS=on -DCMAKE_TOOLCHAIN_FILE=../cmake/ios.cmake -DCMAKE_OSX_ARCHITECTURES=$arch ..
|
||||
make
|
10
makeiosarm64
10
makeiosarm64
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=MinSizeRel -DIOS=on -DCMAKE_TOOLCHAIN_FILE=../cmake/ios.cmake -DCMAKE_OSX_ARCHITECTURES=arm64 ..
|
||||
make
|
10
makeiossim
10
makeiossim
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=MinSizeRel -DIOS=on -DCMAKE_TOOLCHAIN_FILE=../cmake/ios.cmake -DCMAKE_OSX_ARCHITECTURES=x86_64 ..
|
||||
make
|
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=Debug -DIOS=on -DCMAKE_TOOLCHAIN_FILE=../cmake/ios.cmake -DCMAKE_OSX_ARCHITECTURES=x86_64 ..
|
||||
make
|
10
makelinux
10
makelinux
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on linux
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=MinSizeRel -DLINUX=on ..
|
||||
make
|
|
@ -0,0 +1,38 @@
|
|||
#!/bin/bash
|
||||
# script to build on linux
|
||||
build=MinSizeRel
|
||||
|
||||
usage()
|
||||
{
|
||||
echo "usage: makelinux [-b buildType]"
|
||||
echo $'\t' "-b Build type. Default MinSizeRel"
|
||||
}
|
||||
|
||||
printsetup()
|
||||
{
|
||||
echo "Build Type:" $build
|
||||
}
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
case $1 in
|
||||
-b ) shift
|
||||
build=$1
|
||||
;;
|
||||
-h ) usage
|
||||
exit
|
||||
;;
|
||||
* ) usage
|
||||
exit 1
|
||||
esac
|
||||
shift
|
||||
done
|
||||
printsetup
|
||||
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=$build -DLINUX=on ..
|
||||
make
|
10
makelinuxchk
10
makelinuxchk
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on linux
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=Debug -DLINUX=on ..
|
||||
make
|
10
makemac
10
makemac
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=MinSizeRel -DMACOS=on ..
|
||||
make
|
|
@ -0,0 +1,38 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
build=MinSizeRel
|
||||
|
||||
usage()
|
||||
{
|
||||
echo "usage: makemac [-b buildType]"
|
||||
echo $'\t' "-b Build type. Default MinSizeRel"
|
||||
}
|
||||
|
||||
printsetup()
|
||||
{
|
||||
echo "Build Type:" $build
|
||||
}
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
case $1 in
|
||||
-b ) shift
|
||||
build=$1
|
||||
;;
|
||||
-h ) usage
|
||||
exit
|
||||
;;
|
||||
* ) usage
|
||||
exit 1
|
||||
esac
|
||||
shift
|
||||
done
|
||||
printsetup
|
||||
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=$build -DMACOS=on ..
|
||||
make
|
10
makemacchk
10
makemacchk
|
@ -1,10 +0,0 @@
|
|||
#!/bin/bash
|
||||
# script to build on mac
|
||||
mkdir .vs
|
||||
cd .vs
|
||||
|
||||
# clean up any old builds of xPlatAppx modules
|
||||
find . -name *xPlatAppx* -d | xargs rm -r
|
||||
|
||||
cmake -DCMAKE_BUILD_TYPE=Debug -DMACOS=on ..
|
||||
make
|
|
@ -43,13 +43,12 @@ function StartEmulator {
|
|||
|
||||
function CreateApp {
|
||||
# Prepare package and compile
|
||||
cd $xplatappxdir/test/mobile/xPlatAppxAndroid
|
||||
cd $xplatappxdir/../mobile/xPlatAppxAndroid
|
||||
mkdir app/src/main/assets
|
||||
cp -R $xplatappxdir/test/appx/* app/src/main/assets
|
||||
cp -R $xplatappxdir/../appx/* app/src/main/assets
|
||||
mkdir -p app/src/main/jniLibs/x86
|
||||
cp $xplatappxdir/android/lib/libxPlatAppx.so app/src/main/jniLibs/x86
|
||||
JAVA_HOME="/Applications/Android Studio.app/Contents/jre/jdk/Contents/Home"
|
||||
rm -r build
|
||||
cp $xplatappxdir/../../.vs/lib/libxPlatAppx.so app/src/main/jniLibs/x86
|
||||
rm -r build app/build
|
||||
sh ./gradlew assembleDebug
|
||||
}
|
||||
|
||||
|
@ -87,7 +86,7 @@ function ParseResult {
|
|||
StartEmulator
|
||||
# Clean up. This commands might fail, but is not an error
|
||||
adb shell rm -r /data/data/com.microsoft.xplatappxandroid/files
|
||||
rm $xplatappxdir/test/mobile/xPlatAppxAndroid/testResults.txt
|
||||
rm $xplatappxdir/../mobile/xPlatAppxAndroid/testResults.txt
|
||||
|
||||
CreateApp
|
||||
RunTest
|
|
@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
|
|||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.5.1-all.zip
|
||||
|
|
Загрузка…
Ссылка в новой задаче