libtool uses file names to name members of an static library.
Files, located in different directories and having matching name,
would have the same name inside an archive. This is not a problem
for ld, but may be a problem for ar. This patch renames files
from ObjCopy library to avoid names clashing.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Unit Tests
Event Timeline
Comment Actions
I think the main benefit is that if you open two files of the same basename in an editor, it may look better.
libtool uses file names to name members of an static library.
This is also a problem for regular (non-thin) archives in all(?) other formats, including GNU.
https://pubs.opengroup.org/onlinepubs/9699919799/utilities/ar.html says
All file operands can be pathnames. However, files within archives shall be named by a filename, which is the last component of the pathname used when the file was entered into the archive. The comparison of file operands to the names of files in archives shall be performed by comparing the last component of the operand to the name of the file in the archive.
Having / is therefore not compliant.
clang-format suggested style edits found: