2020-11-12 05:21:35 +00:00
|
|
|
#!/bin/bash -ex
|
|
|
|
|
|
|
|
set -o pipefail
|
|
|
|
|
2021-09-12 20:27:29 +01:00
|
|
|
export PATH="/usr/local/opt/ccache/libexec:$PATH"
|
2020-11-12 05:21:35 +00:00
|
|
|
# ccache configurations
|
|
|
|
export CCACHE_CPP2=yes
|
|
|
|
export CCACHE_SLOPPINESS=time_macros
|
|
|
|
|
|
|
|
export CC="ccache clang"
|
|
|
|
export CXX="ccache clang++"
|
2022-09-21 17:36:12 +01:00
|
|
|
export OBJC="clang"
|
|
|
|
export ASM="clang"
|
2020-11-12 05:21:35 +00:00
|
|
|
|
|
|
|
ccache -s
|
|
|
|
|
|
|
|
mkdir build && cd build
|
2023-01-15 16:15:42 +00:00
|
|
|
# TODO: LibreSSL ASM disabled due to platform detection issues in build.
|
2021-09-12 20:27:29 +01:00
|
|
|
cmake .. -DCMAKE_BUILD_TYPE=Release \
|
2023-03-01 17:58:09 +00:00
|
|
|
-DCMAKE_OSX_ARCHITECTURES="$TARGET_ARCH" \
|
2021-09-12 20:27:29 +01:00
|
|
|
-DENABLE_QT_TRANSLATION=ON \
|
|
|
|
-DCITRA_ENABLE_COMPATIBILITY_REPORTING=${ENABLE_COMPATIBILITY_REPORTING:-"OFF"} \
|
|
|
|
-DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON \
|
|
|
|
-DUSE_DISCORD_PRESENCE=ON \
|
|
|
|
-DENABLE_FFMPEG_AUDIO_DECODER=ON \
|
|
|
|
-DENABLE_FFMPEG_VIDEO_DUMPER=ON \
|
2023-01-05 23:16:40 +00:00
|
|
|
-DENABLE_ASM=OFF \
|
2021-09-12 20:27:29 +01:00
|
|
|
-GNinja
|
2020-11-12 05:21:35 +00:00
|
|
|
ninja
|
|
|
|
|
|
|
|
ccache -s
|
|
|
|
|
2023-03-01 17:58:09 +00:00
|
|
|
CURRENT_ARCH=`arch`
|
|
|
|
if [ "$TARGET_ARCH" = "$CURRENT_ARCH" ]; then
|
|
|
|
ctest -VV -C Release
|
|
|
|
fi
|