Skip to content

Commit

Permalink
Correct INSTALL_PREFIX for arm64 target
Browse files Browse the repository at this point in the history
  • Loading branch information
nmahadevuni committed Oct 4, 2023
1 parent 0e9cf61 commit 67de8bf
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions scripts/setup-helper-functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@

# github_checkout $REPO $VERSION $GIT_CLONE_PARAMS clones or re-uses an existing clone of the
# specified repo, checking out the requested version.

OS=$(uname)

function github_checkout {
local REPO=$1
shift
Expand Down Expand Up @@ -55,8 +58,6 @@ function github_checkout {
function get_cxx_flags {
local CPU_ARCH=$1

local OS
OS=$(uname)
local MACHINE
MACHINE=$(uname -m)
ADDITIONAL_FLAGS=""
Expand Down Expand Up @@ -129,6 +130,11 @@ function cmake_install {
CPU_TARGET="${CPU_TARGET:-unknown}"
COMPILER_FLAGS=$(get_cxx_flags $CPU_TARGET)

if [[ "$OS" == "Darwin" && "${CPU_TARGET}" == "arm64" ]]; then
INSTALL_PREFIX="${INSTALL_PREFIX:-/opt/homebrew}"
fi


# CMAKE_POSITION_INDEPENDENT_CODE is required so that Velox can be built into dynamic libraries \
cmake -Wno-dev -B"${BINARY_DIR}" \
-GNinja \
Expand Down

0 comments on commit 67de8bf

Please sign in to comment.