mirror of
https://github.com/rive-app/rive-cpp.git
synced 2026-01-18 21:21:17 +01:00
fix builds for editor and tasks Went with beta3 for anything that looks like apple silicone, seems to have been used in other cases (maybe we want to try beta4 though?) also we use beta2 a "lot" elsewhere, so stuck to that on linux. but i think we should probably just bump everything to 4 Diffs= b153a81b61 Fix premake tag (#8865) 8c9dc78dbd Android BrowserStack fixups (#8856) Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com> Co-authored-by: Maxwell Talbot <talbot.maxwell@gmail.com>
57 lines
1.5 KiB
Bash
Executable File
57 lines
1.5 KiB
Bash
Executable File
#!/bin/bash
|
|
set -e
|
|
|
|
# This script should be called on a Mac!
|
|
|
|
if [[ ! -f "dependencies/bin/premake5" ]]; then
|
|
mkdir -p dependencies/bin
|
|
pushd dependencies
|
|
# v5.0.0-beta2 doesn't support apple silicon properly, update the branch
|
|
# once a stable one is avaialble that supports it
|
|
git clone --depth 1 --branch v5.0.0-beta3 https://github.com/premake/premake-core.git
|
|
pushd premake-core
|
|
if [[ $LOCAL_ARCH == "arm64" ]]; then
|
|
PREMAKE_MAKE_ARCH=ARM
|
|
else
|
|
PREMAKE_MAKE_ARCH=x86
|
|
fi
|
|
make -f Bootstrap.mak osx PLATFORM=$PREMAKE_MAKE_ARCH
|
|
cp bin/release/* ../bin
|
|
popd
|
|
popd
|
|
fi
|
|
|
|
export PREMAKE=$PWD/dependencies/bin/premake5
|
|
|
|
for var in "$@"; do
|
|
if [[ $var = "clean" ]]; then
|
|
echo 'Cleaning...'
|
|
rm -fR out
|
|
fi
|
|
done
|
|
|
|
mkdir -p out
|
|
mkdir -p out_with_renames
|
|
|
|
pushd ../../../
|
|
PACKAGES=$PWD
|
|
popd
|
|
export PREMAKE_PATH="dependencies/export-compile-commands":"$PACKAGES/runtime_unity/native_plugin/platform":"$PACKAGES/runtime/build":"$PREMAKE_PATH"
|
|
|
|
$PREMAKE gmake2 --file=../premake5_yoga_v2.lua --out=out --no-yoga-renames
|
|
pushd out
|
|
make -j$(($(sysctl -n hw.physicalcpu) + 1))
|
|
popd
|
|
|
|
nm out/librive_yoga.a --demangle &>yoga_names.txt
|
|
|
|
dart gen_header.dart
|
|
|
|
# make with renames just to examine the exported symbols...
|
|
$PREMAKE gmake2 --file=../premake5_yoga_v2.lua --out=out_with_renames
|
|
pushd out_with_renames
|
|
make -j$(($(sysctl -n hw.physicalcpu) + 1))
|
|
popd
|
|
|
|
nm out_with_renames/librive_yoga.a --demangle &>yoga_renames.txt
|