[llvm-bugs] [Bug 39034] New: Flatten names when converting from thin archive to regular archive
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Sep 21 03:43:44 PDT 2018
https://bugs.llvm.org/show_bug.cgi?id=39034
Bug ID: 39034
Summary: Flatten names when converting from thin archive to
regular archive
Product: tools
Version: trunk
Hardware: PC
OS: Windows NT
Status: NEW
Severity: enhancement
Priority: P
Component: llvm-ar
Assignee: unassignedbugs at nondot.org
Reporter: jh7370.2008 at my.bristol.ac.uk
CC: llvm-bugs at lists.llvm.org
In a regular archive, names are always stored as just the filename (e.g.
'bar.o'), whereas in thin archives, the path specified is stored (e.g.
'C:\Work\bar.o'). Converting from a thin archive to a regular archive with no
warning is dubious at best (GNU ar does not support it at all), since
forgetting a single 'T' is all that it takes, but assuming that we permit it,
we should probably flatten the paths to be in the regular archive style, so
that operations can be performed on them in the same way as if it had been a
regular archive all along:
C:\Work>touch test1.o
C:\Work>touch dir\test2.o
C:\Work>touch test3.o
C:\Work>llvm-ar rcT test.a .\test1.o
C:\Work>llvm-ar rT test.a TempWork\test2.o
C:\Work>llvm-ar r test.a test3.o # This silently converts it to a thin archive
C:\Work>llvm-ar t test.a
./test1.o
TempWork/test2.o
test3.o
C:\Work>llvm-ar x test.a test1.o test2.o
test1.o was not found
test2.o was not found
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180921/1502c0ce/attachment.html>
More information about the llvm-bugs
mailing list