Skip to content

Commit

Permalink
conda: cmake args from variant
Browse files Browse the repository at this point in the history
  • Loading branch information
tvandera committed Jun 13, 2024
1 parent 46742db commit 1590784
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
17 changes: 11 additions & 6 deletions conda-recipes/smurff/build.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
#!/bin/bash

export CMAKE_ARGS="-DCMAKE_INSTALL_PREFIX=$PREFIX -DENABLE_MPI=OFF"
if [ $blas_impl == "mkl" ]
then
SKBUILD_CMAKE_ARGS="-DENABLE_MKL=ON"
elif [ $blas_impl == "openblas" ]
then
SKBUILD_CMAKE_ARGS="-DENABLE_OPENBLAS=ON"
fi

# make sure we use CONDA_BUILD_SYSROOT
# https://github.com/conda/conda-build/issues/3452#issuecomment-47539707
[[ ${target_platform} == "osx-64" ]] && \
CMAKE_ARGS="$CMAKE_ARGS -DCMAKE_OSX_SYSROOT=${CONDA_BUILD_SYSROOT}"
export SKBUILD_CMAKE_ARGS

$PYTHON -m pip install . --no-deps -vv
$PYTHON -m pip install . \
$EXTRA_CMAKE_ARGS \
--no-deps -vv
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ logging.level = "INFO"
ENABLE_BOOST = "OFF"
ENABLE_CMDLINE = "OFF"
ENABLE_TESTS = "OFF"
ENABLE_OPENBLAS = "ON"

[tool.setuptools_scm] # Section required
write_to = "python/smurff/_version.py"
Expand Down

0 comments on commit 1590784

Please sign in to comment.