Skip to content

Commit

Permalink
Add omp 17
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesYang007 committed May 26, 2024
1 parent 31ca206 commit 716a941
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 35 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,12 @@ jobs:
- name: Install micromamba
uses: mamba-org/setup-micromamba@v1
with:
environment-name: build
environment-file: environment.yml
init-shell: bash
generate-run-shell: true
create-args: >-
llvm-openmp==11.1.0
- name: Setup OpenMP prefix
run: |
echo "OPENMP_PREFIX=$MAMBA_ROOT_PREFIX/envs/build" >> $GITHUB_ENV
echo "OPENMP_PREFIX=$MAMBA_ROOT_PREFIX/envs/adelie" >> $GITHUB_ENV
shell: micromamba-shell {0}
- name: Build wheels
uses: pypa/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.1.32.dev10
1.1.32.dev11
1 change: 1 addition & 0 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@ dependencies:
- python
- pip
- ffmpeg
- llvm-openmp==17.0.6
- pip:
- poetry
34 changes: 4 additions & 30 deletions tools/wheels/cibw_before_build.sh
Original file line number Diff line number Diff line change
@@ -1,40 +1,14 @@
# install homebrew + libomp
set -ex

if [[ "$OSTYPE" == "darwin"* ]]; then
# See https://github.com/scikit-learn/scikit-learn/blob/09781c540077a7f1f4f2392c9287e08e479c4f29/build_tools/wheels/build_wheels.sh#L18-L50
# See https://cibuildwheel.pypa.io/en/stable/faq/#macos-library-dependencies-do-not-satisfy-target-macos
# We need to explicitly set the deployment target to the version of the intended machine.
if [[ "$CIBW_BUILD" == *-macosx_arm64 ]]; then
## install conda
#set -ex
## macos arm64 runners do not have conda installed. Thus we much install conda manually
#EXPECTED_SHA="dd832d8a65a861b5592b2cf1d55f26031f7c1491b30321754443931e7b1e6832"
#MINIFORGE_URL="https://github.com/conda-forge/miniforge/releases/download/23.11.0-0/Mambaforge-23.11.0-0-MacOSX-arm64.sh"
#curl -L --retry 10 $MINIFORGE_URL -o miniforge.sh

## Check SHA
#file_sha=$(shasum -a 256 miniforge.sh | awk '{print $1}')
#if [ "$EXPECTED_SHA" != "$file_sha" ]; then
# echo "SHA values did not match!"
# exit 1
#fi

## Install miniforge
#MINIFORGE_PATH=$HOME/miniforge
#bash ./miniforge.sh -b -p $MINIFORGE_PATH
#PATH="$PATH:$MINIFORGE_PATH/bin"
#CONDA_HOME=$MINIFORGE_PATH

export MACOSX_DEPLOYMENT_TARGET=12.0
#OPENMP_URL="https://anaconda.org/conda-forge/llvm-openmp/11.1.0/download/osx-arm64/llvm-openmp-11.1.0-hf3c4609_1.tar.bz2"
export MACOSX_DEPLOYMENT_TARGET=13.0
else
# Non-macos arm64 envrionments already have conda installed
#CONDA_HOME="/usr/local/miniconda"

export MACOSX_DEPLOYMENT_TARGET=10.9
#OPENMP_URL="https://anaconda.org/conda-forge/llvm-openmp/11.1.0/download/osx-64/llvm-openmp-11.1.0-hda6cdc1_1.tar.bz2"
fi

#sudo conda create -n build $OPENMP_URL
#export OPENMP_PREFIX="$CONDA_HOME/envs/build"
set -ex
echo $OPENMP_PREFIX
fi

0 comments on commit 716a941

Please sign in to comment.