Skip to content

Commit

Permalink
Darwin: Fix compilation
Browse files Browse the repository at this point in the history
Signed-off-by: sekaiacg <[email protected]>
  • Loading branch information
sekaiacg committed May 10, 2024
1 parent 7e3cbe1 commit 0503855
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions build_darwin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,14 @@ cmake_build()
local MAKE_CMD="time -p make -C $OUT -j$(sysctl -n hw.logicalcpu)"
fi;

local PROCESSOR=""
[ ${ABI} == "x86_64" ] && PROCESSOR="x86_64"
[ ${ABI} == "aarch64" ] && PROCESSOR="arm64"

if [[ $TARGET == "Darwin" ]]; then
cmake -S ${BUILD_DIR} -B ${OUT} ${BUILD_METHOD} \
-DCMAKE_SYSTEM_NAME="Darwin" \
-DCMAKE_SYSTEM_PROCESSOR="${PROCESSOR}" \
-DCMAKE_BUILD_TYPE="Release" \
-DCMAKE_C_COMPILER_TARGET="${ABI}-apple-darwin" \
-DCMAKE_CXX_COMPILER_TARGET="${ABI}-apple-darwin" \
Expand Down

0 comments on commit 0503855

Please sign in to comment.