LLVM  15.0.0git
MachOConfig.h
Go to the documentation of this file.
1 //===- MachOConfig.h --------------------------------------------*- 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 //===----------------------------------------------------------------------===//
8 
9 #ifndef LLVM_OBJCOPY_MACHO_MACHOCONFIG_H
10 #define LLVM_OBJCOPY_MACHO_MACHOCONFIG_H
11 
12 #include "llvm/ADT/DenseMap.h"
13 #include "llvm/ADT/DenseSet.h"
14 #include "llvm/ADT/StringRef.h"
15 #include <vector>
16 
17 namespace llvm {
18 namespace objcopy {
19 
20 // Mach-O specific configuration for copying/stripping a single file.
21 struct MachOConfig {
22  // Repeated options
23  std::vector<StringRef> RPathToAdd;
24  std::vector<StringRef> RPathToPrepend;
28 
29  // install-name-tool's id option
31 
32  // Segments to remove if they are empty
34 
35  // Boolean options
36  bool StripSwiftSymbols = false;
37  bool KeepUndefined = false;
38 
39  // install-name-tool's --delete_all_rpaths
40  bool RemoveAllRpaths = false;
41 };
42 
43 } // namespace objcopy
44 } // namespace llvm
45 
46 #endif // LLVM_OBJCOPY_MACHO_MACHOCONFIG_H
llvm::objcopy::MachOConfig::RPathToPrepend
std::vector< StringRef > RPathToPrepend
Definition: MachOConfig.h:24
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:17
llvm::objcopy::MachOConfig::InstallNamesToUpdate
DenseMap< StringRef, StringRef > InstallNamesToUpdate
Definition: MachOConfig.h:26
StringRef.h
llvm::objcopy::MachOConfig::EmptySegmentsToRemove
DenseSet< StringRef > EmptySegmentsToRemove
Definition: MachOConfig.h:33
llvm::objcopy::MachOConfig::KeepUndefined
bool KeepUndefined
Definition: MachOConfig.h:37
DenseMap.h
llvm::Optional
Definition: APInt.h:33
llvm::objcopy::MachOConfig::RemoveAllRpaths
bool RemoveAllRpaths
Definition: MachOConfig.h:40
llvm::objcopy::MachOConfig
Definition: MachOConfig.h:21
DenseSet.h
llvm::objcopy::MachOConfig::RPathToAdd
std::vector< StringRef > RPathToAdd
Definition: MachOConfig.h:23
llvm::objcopy::MachOConfig::SharedLibId
Optional< StringRef > SharedLibId
Definition: MachOConfig.h:30
llvm::objcopy::MachOConfig::RPathsToRemove
DenseSet< StringRef > RPathsToRemove
Definition: MachOConfig.h:27
llvm::DenseSet
Implements a dense probed hash-table based set.
Definition: DenseSet.h:268
llvm::DenseMap
Definition: DenseMap.h:716
llvm::objcopy::MachOConfig::RPathsToUpdate
DenseMap< StringRef, StringRef > RPathsToUpdate
Definition: MachOConfig.h:25
llvm::objcopy::MachOConfig::StripSwiftSymbols
bool StripSwiftSymbols
Definition: MachOConfig.h:36