Skip to content

Commit

Permalink
Fix install_conda in setup-ubuntu.sh to consider the CPU architecture (
Browse files Browse the repository at this point in the history
…#8706)

Summary:
The function install_conda in setup_ubuntu.sh always downloads the conda package corresponding to
the CPU architecture x86_64.
Fix the function to download the conda package based on the actual CPU architecture (x86_64 or aarch64).

Resolves #8453

Pull Request resolved: #8706

Reviewed By: Yuhta

Differential Revision: D53727378

Pulled By: mbasmanova

fbshipit-source-id: 5e2e076dd3a67f3de115dcc64c682b4cbf59fd34
  • Loading branch information
acvictor authored and facebook-github-bot committed Feb 14, 2024
1 parent 793222b commit 5d1d2a3
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions scripts/setup-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -119,11 +119,20 @@ function install_fbthrift {

function install_conda {
mkdir -p conda && cd conda
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
ARCH=$(uname -m)

if [ "$ARCH" != "x86_64" ] && [ "$ARCH" != "aarch64" ]; then
echo "Unsupported architecture: $ARCH"
exit 1
fi

wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-$ARCH.sh

MINICONDA_PATH=/opt/miniconda-for-velox
bash Miniconda3-latest-Linux-x86_64.sh -b -p $MINICONDA_PATH
bash Miniconda3-latest-Linux-$ARCH.sh -b -p $MINICONDA_PATH
}


function install_velox_deps {
run_and_time install_fmt
run_and_time install_folly
Expand Down

0 comments on commit 5d1d2a3

Please sign in to comment.