[Alignment][NFC] Use Align with TargetLowering::setMinFunctionAlignment
[llvm-core.git] / include / llvm / Support / TarWriter.h
blob71164e2ef961d1c56141e13f49db7198825d1384
1 //===-- llvm/Support/TarWriter.h - Tar archive file creator -----*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_SUPPORT_TAR_WRITER_H
10 #define LLVM_SUPPORT_TAR_WRITER_H
12 #include "llvm/ADT/StringRef.h"
13 #include "llvm/ADT/StringSet.h"
14 #include "llvm/Support/Error.h"
15 #include "llvm/Support/raw_ostream.h"
17 namespace llvm {
18 class TarWriter {
19 public:
20 static Expected<std::unique_ptr<TarWriter>> create(StringRef OutputPath,
21 StringRef BaseDir);
23 void append(StringRef Path, StringRef Data);
25 private:
26 TarWriter(int FD, StringRef BaseDir);
27 raw_fd_ostream OS;
28 std::string BaseDir;
29 StringSet<> Files;
33 #endif