This is an archive of the discontinued LLVM Phabricator instance.

[libcxxabi/runtimes] Set LLVM_HOST_TRIPLE in runtimes build
ClosedPublic

Authored by DavidSpickett on Nov 11 2021, 4:31 AM.

Details

Reviewers
ldionne
phosek
Group Reviewers
Restricted Project
Restricted Project
Commits
rG5beec6fb04e7: [libcxxabi/runtimes] Set LLVM_HOST_TRIPLE in runtimes build
Summary

This allows tests to tell if they're running natively.

Those tests are libcxxabi/test/native/arm-linux-eabi.
Which were running on Linaro's bots but became unsupported
when we switched to the runtimes build.

Diff Detail

Event Timeline

DavidSpickett created this revision.Nov 11 2021, 4:31 AM
DavidSpickett requested review of this revision.Nov 11 2021, 4:31 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptNov 11 2021, 4:31 AM
Herald added a reviewer: Restricted Project. · View Herald Transcript
Herald added a reviewer: Restricted Project. · View Herald Transcript
phosek added a subscriber: phosek.Nov 11 2021, 10:12 PM
phosek added inline comments.
runtimes/CMakeLists.txt
113–118

We can simplify this by getting the host triple unconditionally.

phosek added inline comments.Nov 11 2021, 10:31 PM
runtimes/CMakeLists.txt
113–118

In llvm/CMakeLists.txt, we cache LLVM_DEFAULT_TARGET_TRIPLE and use LLVM_HOST_TRIPLE as the default value, see https://github.com/llvm/llvm-project/blob/2ca45adf24d8ede45b9f600d13a4b4f7005e13af/llvm/CMakeLists.txt#L707. We could use the same approach here.

  • Get host triple unconditionally
  • Set default triple to host triple by default
DavidSpickett marked 2 inline comments as done.Nov 12 2021, 1:53 AM
phosek accepted this revision.Nov 15 2021, 1:14 AM

LGTM

This revision was not accepted when it landed; it landed in state Needs Review.Nov 16 2021, 8:30 AM
This revision was automatically updated to reflect the committed changes.