mirror of
https://github.com/rive-app/rive-cpp.git
synced 2026-01-18 21:21:17 +01:00
fix viewer build
Diffs= a8c86e949 fix viewer build (#6527) Co-authored-by: Chris Dalton <99840794+csmartdalton@users.noreply.github.com>
This commit is contained in:
59
skia/renderer/build/macosx/build_skia_renderer.sh
Executable file
59
skia/renderer/build/macosx/build_skia_renderer.sh
Executable file
@@ -0,0 +1,59 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
source ../../../../dependencies/macosx/config_directories.sh
|
||||
|
||||
CONFIG=debug
|
||||
GRAPHICS=gl
|
||||
OTHER_OPTIONS=
|
||||
|
||||
for var in "$@"; do
|
||||
if [[ $var = "release" ]]; then
|
||||
CONFIG=release
|
||||
fi
|
||||
if [[ $var = "gl" ]]; then
|
||||
GRAPHICS=gl
|
||||
fi
|
||||
if [[ $var = "d3d" ]]; then
|
||||
GRAPHICS=d3d
|
||||
fi
|
||||
if [[ $var = "metal" ]]; then
|
||||
GRAPHICS=metal
|
||||
fi
|
||||
if [[ $var = "text" ]]; then
|
||||
OTHER_OPTIONS+=--with_rive_text
|
||||
fi
|
||||
done
|
||||
|
||||
if [[ ! -f "$DEPENDENCIES/bin/premake5" ]]; then
|
||||
pushd $DEPENDENCIES_SCRIPTS
|
||||
./get_premake5.sh
|
||||
popd
|
||||
fi
|
||||
|
||||
if [[ ! -d "$DEPENDENCIES/sokol" ]]; then
|
||||
pushd $DEPENDENCIES_SCRIPTS
|
||||
./get_sokol.sh
|
||||
popd
|
||||
fi
|
||||
|
||||
if [[ ! -f "$DEPENDENCIES/skia/out/$GRAPHICS/$CONFIG/libskia.a" ]]; then
|
||||
pushd $DEPENDENCIES_SCRIPTS
|
||||
./make_viewer_skia.sh $GRAPHICS $CONFIG
|
||||
popd
|
||||
fi
|
||||
|
||||
export PREMAKE=$DEPENDENCIES/bin/premake5
|
||||
pushd ..
|
||||
$PREMAKE --scripts=../../../build --file=./premake5.lua gmake2 $OTHER_OPTIONS
|
||||
|
||||
for var in "$@"; do
|
||||
if [[ $var = "clean" ]]; then
|
||||
make clean
|
||||
make config=release clean
|
||||
fi
|
||||
done
|
||||
|
||||
make config=$CONFIG -j$(($(sysctl -n hw.physicalcpu) + 1))
|
||||
|
||||
popd
|
||||
Reference in New Issue
Block a user