summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorThierry Reding <treding@nvidia.com>2018-03-16 11:49:47 +0100
committerThierry Reding <treding@nvidia.com>2018-04-04 16:25:38 +0200
commit23054838e31624c426c5123694151af0754ead23 (patch)
tree284d6d2e883bf6b7bdabdfa988ad743cc172f49d /meson.build
parent5a88b4626396bc50ec1199ead11dd0ae3e11b039 (diff)
meson: Use dep_llvm when finding clang modulesHEADmaster
When cross-compiling OpenCL support, clover will encode the LLVM library path so that it can add the proper directory (containing opencl-c.h) to the include path during runtime compilation of programs. In order for that to work, the LLVM library directory needs to be an absolute path in the host filesystem. However, during cross-compilation the LLVM library directory will also be used to find the clang modules to link against. But at build time the clang modules will have to be looked up in th LLVM library directory within the host sysroot, which is a cross-compilation staging area that is located in an arbitrary directory on the build filesystem. However, the library search path provided by the dep_llvm dependency contains the correct path to the clang modules at build time, so the dependency can be passed to the cc.find_library() command to properly check for the existence of the library and whether it can actually be linked to. NOTE: This depends on a patch that hasn't been merged into Meson yet. Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'meson.build')
0 files changed, 0 insertions, 0 deletions