From 03469faebf14f79fb091e170fcc0531ea680acce Mon Sep 17 00:00:00 2001 From: Hans Ekkehard Plesser Date: Fri, 14 Apr 2023 22:13:54 +0200 Subject: [PATCH] Fix OpenMP issues on CI under macOS and re-activate testing with threads on macOS. Co-authored-by: Nicolai Haug <39106781+nicolossus@users.noreply.github.com> --- .github/workflows/nestbuildmatrix.yml | 1 - build_support/ci_build.sh | 6 +++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/nestbuildmatrix.yml b/.github/workflows/nestbuildmatrix.yml index 5620149441..eb9a32c806 100644 --- a/.github/workflows/nestbuildmatrix.yml +++ b/.github/workflows/nestbuildmatrix.yml @@ -226,7 +226,6 @@ jobs: - name: "Install MacOS system dependencies" run: | brew install coreutils gsl open-mpi libomp automake autoconf libtool boost - brew info python - name: "Restore pip cache" env: diff --git a/build_support/ci_build.sh b/build_support/ci_build.sh index 870136fd5f..5ec8b1fd8e 100755 --- a/build_support/ci_build.sh +++ b/build_support/ci_build.sh @@ -178,7 +178,7 @@ if [ "$xNEST_BUILD_TYPE" = "FULL_MACOS" ]; then xLTDL=1 xMPI=1 xMUSIC=0 - xOPENMP=0 + xOPENMP=1 xPYTHON=1 xREADLINE=1 xSIONLIB=0 @@ -196,6 +196,9 @@ echo "MSGBLD0232: Setting configuration variables." if [ "$xOPENMP" = "1" ] ; then CONFIGURE_OPENMP="-Dwith-openmp=ON" + if [ "$xNEST_BUILD_TYPE" = "FULL_MACOS" ]; then + CONFIGURE_OPENMP="${CONFIGURE_OPENMP} -DOpenMP_ROOT=`brew --prefix libomp`" + fi else CONFIGURE_OPENMP="-Dwith-openmp=OFF" fi @@ -303,6 +306,7 @@ cmake \ -DCMAKE_CXX_FLAGS="$CXX_FLAGS" \ -Dwith-optimize=ON \ -Dwith-warning=ON \ + -Dwith-userdoc=OFF \ $CONFIGURE_BOOST \ $CONFIGURE_OPENMP \ $CONFIGURE_MPI \