mirror of
https://github.com/intel/llvm.git
synced 2026-01-22 15:41:35 +08:00
Without this change the problem is that flangOmpReport and
flangPrintFunctionNames libraries are not built under 'all',
but they are imported targets via LLVMExports.cmake so that
any out-of-tree build that configures upon LLVM+Flang package
will get this CMake error:
```
The imported target "flangPrintFunctionNames" references the file
".../lib/flangPrintFunctionNames.so"
but this file does not exist.
```
flang-aarch64-out-of-tree buildbot (https://lab.llvm.org/buildbot/#/builders/175)
does not catch this issue, because it does not enable Flang on the first stage.
This change gets rid of FLANG_BUILD_EXAMPLES in favor of LLVM_BUILD_EXAMPLES
and uses available LLVM CMake macros to add example executables/libraries.
Differential Revision: https://reviews.llvm.org/D145992
12 lines
274 B
CMake
12 lines
274 B
CMake
# TODO: Note that this is currently only available on Linux.
|
|
# On Windows, we would also have to specify e.g. `PLUGIN_TOOL`.
|
|
add_llvm_example_library(flangPrintFunctionNames
|
|
MODULE
|
|
PrintFlangFunctionNames.cpp
|
|
|
|
DEPENDS
|
|
acc_gen
|
|
flangFrontend
|
|
omp_gen
|
|
)
|