Daniel Marino
30 October 2024
Resolving OpenMP Compilation Issues on macOS for CMake Builds
It can be annoying to keep getting the "Could NOT find OpenMP_C" warning on macOS, especially when CMake uses Xcode's Clang by default, which does not support OpenMP. Multiple builds may be impacted by this problem, which is frequent on Apple Silicon. It is frequently fixed by setting CMake to use a Clang version that is compatible with OpenMP, such as one installed using MacPorts. This post offers a number of tried-and-true methods and scripts for rerouting CMake to the appropriate compiler pathways, facilitating seamless parallel processing, and preventing configuration mistakes.