mirror of
https://github.com/rive-app/rive-ios.git
synced 2026-01-18 17:11:28 +01:00
Re-add skia iOS build scripts
Re-add these build scripts as they were causing some tests to error out. Diffs= c3f96b62a Re-add skia iOS build scripts (#8056) Co-authored-by: David Skuza <david@rive.app>
This commit is contained in:
@@ -1 +1 @@
|
||||
bbc2bba5b013552e946e505d5f9445d6fe0b129f
|
||||
c3f96b62a132adce1e5c658ef45fc9e4c92c3d91
|
||||
|
||||
47
scripts/build.skia.macos.sh
Executable file
47
scripts/build.skia.macos.sh
Executable file
@@ -0,0 +1,47 @@
|
||||
#!/bin/bash
|
||||
set -ex
|
||||
|
||||
ARCH_X64=x64
|
||||
ARCH_ARM64=arm64
|
||||
|
||||
usage() {
|
||||
printf "Usage: %s -a arch\n" "$0"
|
||||
printf "\t-a Specify an architecture (i.e. '%s', '%s')\n" $ARCH_X64 $ARCH_ARM64
|
||||
exit 1 # Exit script after printing help
|
||||
}
|
||||
|
||||
while getopts "a:cd" opt; do
|
||||
case "$opt" in
|
||||
a) ARCH_NAME="$OPTARG" ;;
|
||||
\?) usage ;; # Print usage in case parameter is non-existent
|
||||
esac
|
||||
done
|
||||
|
||||
if [ -z "$ARCH_NAME" ]; then
|
||||
echo "No architecture specified"
|
||||
usage
|
||||
fi
|
||||
|
||||
path=`readlink -f "${BASH_SOURCE:-$0}"`
|
||||
DEV_SCRIPT_DIR=`dirname $path`
|
||||
|
||||
export SKIA_REPO="https://github.com/rive-app/skia"
|
||||
export SKIA_BRANCH="rive"
|
||||
export COMPILE_TARGET="macos_$EXPECTED_NDK_VERSION_$ARCH_NAME"
|
||||
export CACHE_NAME="rive_skia_macos"
|
||||
export MAKE_SKIA_FILE="make_skia_macos.sh"
|
||||
export SKIA_DIR_NAME="skia"
|
||||
# we can have multiple at the same time...
|
||||
export ARCHIVE_CONTENTS_NAME="archive_contents_macos_$ARCH_NAME"
|
||||
|
||||
if [ -d "$DEV_SCRIPT_DIR/../submodules/rive-runtime" ];
|
||||
then
|
||||
export RIVE_RUNTIME_DIR="$DEV_SCRIPT_DIR/../submodules/rive-runtime"
|
||||
else
|
||||
export RIVE_RUNTIME_DIR="$DEV_SCRIPT_DIR/../../runtime"
|
||||
fi
|
||||
|
||||
# Build skia
|
||||
pushd "$RIVE_RUNTIME_DIR"/skia/dependencies
|
||||
./make_skia_macos.sh $ARCH_NAME
|
||||
popd
|
||||
50
scripts/build.skia.sh
Executable file
50
scripts/build.skia.sh
Executable file
@@ -0,0 +1,50 @@
|
||||
#!/bin/bash
|
||||
set -ex
|
||||
|
||||
ARCH_X86=x86
|
||||
ARCH_X64=x64
|
||||
ARCH_ARM=arm
|
||||
ARCH_ARM64=arm64
|
||||
ARCH_SIM_ARM64=iossim_arm64
|
||||
|
||||
usage() {
|
||||
printf "Usage: %s -a arch\n" "$0"
|
||||
printf "\t-a Specify an architecture (i.e. '%s', '%s', '%s', '%s', '%s')\n" $ARCH_X86 $ARCH_X64 $ARCH_ARM $ARCH_ARM64 $ARCH_SIM_ARM64
|
||||
exit 1 # Exit script after printing help
|
||||
}
|
||||
|
||||
while getopts "a:cd" opt; do
|
||||
case "$opt" in
|
||||
a) ARCH_NAME="$OPTARG" ;;
|
||||
\?) usage ;; # Print usage in case parameter is non-existent
|
||||
esac
|
||||
done
|
||||
|
||||
if [ -z "$ARCH_NAME" ]; then
|
||||
echo "No architecture specified"
|
||||
usage
|
||||
fi
|
||||
|
||||
path=`readlink -f "${BASH_SOURCE:-$0}"`
|
||||
DEV_SCRIPT_DIR=`dirname $path`
|
||||
|
||||
export SKIA_REPO="https://github.com/rive-app/skia"
|
||||
export SKIA_BRANCH="rive"
|
||||
export COMPILE_TARGET="ios_$EXPECTED_NDK_VERSION_$ARCH_NAME"
|
||||
export CACHE_NAME="rive_skia_ios"
|
||||
export MAKE_SKIA_FILE="make_skia_ios.sh"
|
||||
export SKIA_DIR_NAME="skia"
|
||||
# we can have multiple at the same time...
|
||||
export ARCHIVE_CONTENTS_NAME="archive_contents_ios_$ARCH_NAME"
|
||||
|
||||
if [ -d "$DEV_SCRIPT_DIR/../submodules/rive-runtime" ];
|
||||
then
|
||||
export RIVE_RUNTIME_DIR="$DEV_SCRIPT_DIR/../submodules/rive-runtime"
|
||||
else
|
||||
export RIVE_RUNTIME_DIR="$DEV_SCRIPT_DIR/../../runtime"
|
||||
fi
|
||||
|
||||
# Build skia
|
||||
pushd "$RIVE_RUNTIME_DIR"/skia/dependencies
|
||||
./make_skia_ios.sh $ARCH_NAME
|
||||
popd
|
||||
Reference in New Issue
Block a user