parallel-runtimes / lomp

Little OpenMP Library
Apache License 2.0
153 stars 17 forks source link

LOMP_COMPILE_OPTIONS-NOTFOUND #25

Open JimCownie opened 3 years ago

JimCownie commented 3 years ago

Describe the bug LOMP is now showing LOMP_COMPILE_OPTIONS-NOTFOUND as the compile options printed when it announces itself (with LOMP_DEBUG=1) on my Mac M1. I believe this used to work.

To Reproduce Build LOMP on mac M1, run any code with LOMP_DEBUG=1, see something like

LOMP:runtime version 0.1 (SO version 1) compiled at 11:03:55 on Jul 21 2021
LOMP:from Git commit 554e597 for aarch64 by LLVM:13:0:0
LOMP:with configuration LOMP_COMPILE_OPTIONS-NOTFOUND;DEBUG=10;LOMP_WARN_API_STUBS=1;LOMP_WARN_ARCH_FEATURES=1

It seems to work OK on LInux

LOMP:runtime version 0.1 (SO version 1) compiled at 12:04:35 on Jul 20 2021
LOMP:from Git commit 5db9696 for aarch64 by LLVM:11:0:0
LOMP:with configuration -march=armv8.1a;DEBUG=10;LOMP_WARN_API_STUBS=1;LOMP_WARN_ARCH_FEATURES=1;LOMP_HAVE_LIBATOMIC=1;LOMP_HAVE_LIBNUMA=1

Though this may be a CMAKE version issue.

Linux:

$ cmake --version
cmake version 3.15.4

MacOS:

$ cmake --version
cmake version 3.21.1

Expected behavior Show the real compiler options.

Desktop (please complete the following information):

JimCownie commented 3 years ago

Possibly related (since it refers to version.h.in) is this message which appears when running cmake

CMake Warning (dev) at src/CMakeLists.txt:10 (add_library):
  Policy CMP0115 is not set: Source file extensions must be explicit.  Run
  "cmake --help-policy CMP0115" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.

  File:

    /Users/jcownie/lomp_tasks/src/version.h.in
This warning is for project developers.  Use -Wno-dev to suppress it.
mjklemm commented 2 years ago

Moved this to the next milestone. It's not a critical bug.