[Openmp-commits] [llvm] [openmp] [OpenMP][Offload] Support standalone build (PR #88957)

Joseph Huber via Openmp-commits openmp-commits at lists.llvm.org
Wed Apr 17 06:17:02 PDT 2024


================
@@ -10,6 +10,13 @@
 #
 ##===----------------------------------------------------------------------===##
 
+cmake_minimum_required(VERSION 3.20.0)
+
+if (OPENMP_STANDALONE_BUILD OR "${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_SOURCE_DIR}")
+  set(OPENMP_STANDALONE_BUILD TRUE)
+  project(omptarget C CXX ASM)
+endif()
----------------
jhuber6 wrote:

I meant the `project` name as well.

What is this pattern
```cmake
if (OPENMP_STANDALONE_BUILD)
  set(OPENMP_STANDALONE_BUILD TRUE)
endif()
```
Seems wrong.

https://github.com/llvm/llvm-project/pull/88957


More information about the Openmp-commits mailing list