[PATCH] D59425: Explicitly Craft a Path to Compiler-RT Builtins on Bare Metal Targets

Robert Widmann via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 15 11:56:31 PDT 2019


CodaFi created this revision.
CodaFi added reviewers: georgemorgan, mehdi_amini, kristina.
Herald added subscribers: cfe-commits, jdoerfert, kristof.beyls, javed.absar, dberris.
Herald added a project: clang.

D33259 <https://reviews.llvm.org/D33259> hard-coded a linker flag relative to a linker library search path that should have allowed it to find `libclang_rt.builtins-$ARCH.a` under the resource directory automatically.  Unfortunately, both the flag and the search path are incorrect, which leads to workarounds like double-suffixes <https://github.com/eblot/homebrew-armeabi/blob/master/armv6m-cortex-m0plus.rb#L138> in linker invocations.

The bare metal toolchain now uses a more standard hook to get the right arch-specific compiler-rt, and constructs a full path relative to the resource directory for the linker input.


Repository:
  rC Clang

https://reviews.llvm.org/D59425

Files:
  clang/lib/Driver/ToolChains/BareMetal.cpp
  clang/lib/Driver/ToolChains/BareMetal.h
  clang/test/Driver/baremetal.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D59425.190863.patch
Type: text/x-patch
Size: 5412 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190315/b650f4bb/attachment.bin>


More information about the cfe-commits mailing list