aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/LibDriver/LibDriver.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2015-07-08 20:47:32 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2015-07-08 20:47:32 +0000
commita2ed0b0babca5c82ac547feb1502e7392db98066 (patch)
tree2df61304a4453719fe4106b0aa69521185b639c5 /llvm/lib/LibDriver/LibDriver.cpp
parentdcb46d6a74ba8b04408afa6c088e529a4254a95c (diff)
downloadllvm-a2ed0b0babca5c82ac547feb1502e7392db98066.zip
llvm-a2ed0b0babca5c82ac547feb1502e7392db98066.tar.gz
llvm-a2ed0b0babca5c82ac547feb1502e7392db98066.tar.bz2
Start adding support for writing archives in BSD format.
No support for the symbol table yet (but will hopefully add it today). We always use the long filename format so that we can align the member, which is an advantage of the BSD format. llvm-svn: 241721
Diffstat (limited to 'llvm/lib/LibDriver/LibDriver.cpp')
-rw-r--r--llvm/lib/LibDriver/LibDriver.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/LibDriver/LibDriver.cpp b/llvm/lib/LibDriver/LibDriver.cpp
index bc3ed46..4a9fa28 100644
--- a/llvm/lib/LibDriver/LibDriver.cpp
+++ b/llvm/lib/LibDriver/LibDriver.cpp
@@ -139,8 +139,10 @@ int llvm::libDriverMain(llvm::ArrayRef<const char*> ArgsArr) {
llvm::sys::path::filename(Arg->getValue()));
}
- std::pair<StringRef, std::error_code> Result = llvm::writeArchive(
- getOutputPath(&Args, Members[0]), Members, /*WriteSymtab=*/true);
+ std::pair<StringRef, std::error_code> Result =
+ llvm::writeArchive(getOutputPath(&Args, Members[0]), Members,
+ /*WriteSymtab=*/true, object::Archive::K_GNU);
+
if (Result.second) {
if (Result.first.empty())
Result.first = ArgsArr[0];