[Openmp-commits] [PATCH] D31055: [OpenMP] libomptarget: Disable on MacOS X

Jonas Hahnfeld via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Mon Mar 20 00:09:41 PDT 2017


Hahnfeld requested changes to this revision.
Hahnfeld added inline comments.
This revision now requires changes to proceed.


================
Comment at: CMakeLists.txt:10
+# there is no point in trying to compile libomptarget on other OSes.
+if (NOT (WIN32 OR ${CMAKE_SYSTEM_NAME} MATCHES "Darwin"))
   add_subdirectory(libomptarget)
----------------
grokos wrote:
> Hahnfeld wrote:
> > Should we do this the other way around and say `CMAKE_SYSTEM_NAME MATCHES "Linux"`?
> Technically, the plugins' CMakeLists.txt's require that the build system is Linux, however there is no reason I'm aware of why they cannot be built on any Unix system, as long as it supports the ELF executable format (e.g. FreeBSD). So maybe the best choice is to leave the condition above as-is (!win32 && !darwin) and change the plugins' CMakeLists to support general Unices. Any thoughts?
Darwin is also Unix-like. If I see that correctly, only the linker doesn't support `--version-script` which is only needed for public / private symbols. In that case, it would be best to have a `config-ix.cmake` check and only add the flag in `libomptarget/CMakeLists.txt` and `libomptarget/plugins/CMakeLists.txt` if supported by the building environment.


Repository:
  rL LLVM

https://reviews.llvm.org/D31055





More information about the Openmp-commits mailing list