2020-10-17 00:09:15 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
if [ "${COMPILER}" = "gcc" ]; then
|
2021-09-04 21:23:47 +00:00
|
|
|
export CC=gcc-10
|
|
|
|
export CXX=g++-10
|
2020-10-17 00:09:15 +00:00
|
|
|
else
|
|
|
|
export CC=clang
|
|
|
|
export CXX=clang++
|
|
|
|
fi
|
2020-11-24 00:44:30 +00:00
|
|
|
|
2021-07-13 14:52:58 +00:00
|
|
|
if [ "${PLATFORM}" = x86 ]; then
|
2021-07-17 22:39:29 +00:00
|
|
|
ADDITIONAL_CMAKE_ARGS="$ADDITIONAL_CMAKE_ARGS -DCMAKE_TOOLCHAIN_FILE=cmake/linux-compiler-i386-multilib.cmake"
|
2020-10-17 00:09:15 +00:00
|
|
|
fi
|
|
|
|
echo "Additional CMake Args - ${ADDITIONAL_CMAKE_ARGS}"
|
|
|
|
|
|
|
|
# Generate CMake into ./build
|
2021-07-13 14:52:58 +00:00
|
|
|
cmake \
|
|
|
|
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
|
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DPACKAGE_MODE=TRUE \
|
2021-11-28 01:07:13 +00:00
|
|
|
-DWAYLAND_API=TRUE \
|
2021-07-13 14:52:58 +00:00
|
|
|
-DDISABLE_ADVANCE_SIMD=TRUE \
|
2021-12-12 23:05:56 +00:00
|
|
|
-DDISABLE_PCSX2_WRAPPER=TRUE \
|
|
|
|
-DCMAKE_INSTALL_PREFIX="squashfs-root/usr/" \
|
2021-07-13 14:52:58 +00:00
|
|
|
-DOpenGL_GL_PREFERENCE="LEGACY" \
|
|
|
|
-DOPENGL_opengl_LIBRARY="" \
|
2021-07-17 22:39:29 +00:00
|
|
|
-DXDG_STD=TRUE \
|
|
|
|
$ADDITIONAL_CMAKE_ARGS \
|
2021-07-13 14:52:58 +00:00
|
|
|
-GNinja \
|
2020-10-17 00:09:15 +00:00
|
|
|
-B build
|