[sanitizer] Improve FreeBSD ASLR detection
[llvm-project.git] / llvm / tools / llvm-objcopy / MultiFormatConfig.h
blob31d9883d6d3a3e01817892bf279fa3ee130a84db
1 //===- MultiFormatConfig.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 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_TOOLS_LLVM_OBJCOPY_MULTIFORMATCONFIG_H
10 #define LLVM_TOOLS_LLVM_OBJCOPY_MULTIFORMATCONFIG_H
12 #include "llvm/Support/Error.h"
14 namespace llvm {
15 namespace objcopy {
17 struct CommonConfig;
18 struct ELFConfig;
19 struct COFFConfig;
20 struct MachOConfig;
21 struct WasmConfig;
23 class MultiFormatConfig {
24 public:
25 virtual ~MultiFormatConfig() {}
27 virtual const CommonConfig &getCommonConfig() const = 0;
28 virtual Expected<const ELFConfig &> getELFConfig() const = 0;
29 virtual Expected<const COFFConfig &> getCOFFConfig() const = 0;
30 virtual Expected<const MachOConfig &> getMachOConfig() const = 0;
31 virtual Expected<const WasmConfig &> getWasmConfig() const = 0;
34 } // namespace objcopy
35 } // namespace llvm
37 #endif // LLVM_TOOLS_LLVM_OBJCOPY_MULTIFORMATCONFIG_H