[libc-commits] [PATCH] D145912: [libc] Set the stub filename to the target name instead of the source

Joseph Huber via Phabricator via libc-commits libc-commits at lists.llvm.org
Mon Mar 13 02:37:22 PDT 2023


jhuber6 created this revision.
jhuber6 added reviewers: sivachandra, michaelrj, lntue.
Herald added subscribers: libc-commits, ecnelises, tschuett.
Herald added projects: libc-project, All.
jhuber6 requested review of this revision.

The GPU target requires some weird special case handling to create fat
binaries. CMake offers no way to set the name of an object library. The
only way to do this is to create a file with the desired name and use
that. Currently we name it after the source filename. However, this
breaks if there is more than a single source. This patch changes the
logic to instead look up the object target name and use that. E.g.
`src.__support.OSUtil.osutil` will be `osutil.cpp`.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D145912

Files:
  libc/cmake/modules/LLVMLibCObjectRules.cmake

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D145912.504562.patch
Type: text/x-patch
Size: 7552 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230313/35c84ca2/attachment.bin>


More information about the libc-commits mailing list