Skip to content

Commit

Permalink
Fix OpenMP builds with thin LTO enabled.
Browse files Browse the repository at this point in the history
When built with thin LTO enabled, LLVM produces object files containing
LLVM IR, which ld can't understand. Since we're forcing the toolchain
to clang anyway, let's also force using lld.

Fixes GitHub kraj#708

Signed-off-by: Jan Dorniak <jaskij@gmail.com>
  • Loading branch information
jaskij authored and kraj committed Dec 27, 2022
1 parent 299a5fd commit bc8388c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions recipes-devtools/clang/openmp_git.bb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ TOOLCHAIN = "clang"

LIC_FILES_CHKSUM = "file://openmp/LICENSE.TXT;md5=d75288d1ce0450b28b8d58a284c09c79"

LDFLAGS:append = " -fuse-ld=lld"

inherit cmake pkgconfig perlnative

DEPENDS += "elfutils libffi clang"
Expand Down

0 comments on commit bc8388c

Please sign in to comment.