Skip to content
Snippets Groups Projects

Use OpenMP_CXX_INCLUDE_DIRS, fix OpenMP_CXX_FLAGS usage

These are fixes for issues encountered building VTK-m 1.6.0 with AppleClang 1200.0.32.29 (Xcode 12.4 command line tools) on macOS 10.15.7 with an external OpenMP runtime (libomp 13 from MacPorts).

  • Use OpenMP_CXX_INCLUDE_DIRS if set: Compilers such as AppleClang do not include OpenMP headers. Specifying the path to OpenMP headers using OpenMP_CXX_INCLUDE_DIR during configure may cause the OpenMP_CXX_INCLUDE_DIRS variable to be set (see https://cmake.org/cmake/help/latest/module/FindOpenMP.html), which if not used during the build will cause fatal errors due to omp.h not being found.

  • Convert OpenMP_CXX_FLAGS from space-separated list to semicolon-separated list before appending to compiler options in order to avoid warnings from AppleClang during build caused by -Xclang -fopenmp being treated as one argument rather than two:

clang: warning: argument unused during compilation: '-Xclang -fopenmp' [-Wunused-command-line-argument]
Edited by Christopher Chavez

Merge request reports

Merge request pipeline #257501 waiting for manual action

Merge request pipeline waiting for manual action for 084710c9

Closed by Christopher ChavezChristopher Chavez 2 years ago (Mar 19, 2022 12:28am UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading