Armando Montanez | 31f0f65 | 2019-01-03 18:32:36 +0000 | [diff] [blame] | 1 | //===- ELFObjHandler.h ------------------------------------------*- C++ -*-===// |
| 2 | // |
Chandler Carruth | 2946cd7 | 2019-01-19 08:50:56 +0000 | [diff] [blame] | 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 |
Armando Montanez | 31f0f65 | 2019-01-03 18:32:36 +0000 | [diff] [blame] | 6 | // |
| 7 | //===-----------------------------------------------------------------------===/ |
| 8 | /// |
| 9 | /// This supports reading and writing of elf dynamic shared objects. |
| 10 | /// |
| 11 | //===-----------------------------------------------------------------------===/ |
| 12 | |
| 13 | #ifndef LLVM_TOOLS_ELFABI_ELFOBJHANDLER_H |
| 14 | #define LLVM_TOOLS_ELFABI_ELFOBJHANDLER_H |
| 15 | |
| 16 | #include "llvm/Object/ELFObjectFile.h" |
| 17 | #include "llvm/Object/ELFTypes.h" |
| 18 | #include "llvm/TextAPI/ELF/ELFStub.h" |
| 19 | |
| 20 | namespace llvm { |
| 21 | |
| 22 | class MemoryBuffer; |
| 23 | |
| 24 | namespace elfabi { |
| 25 | |
| 26 | /// Attempt to read a binary ELF file from a MemoryBuffer. |
| 27 | Expected<std::unique_ptr<ELFStub>> readELFFile(MemoryBufferRef Buf); |
| 28 | |
| 29 | } // end namespace elfabi |
| 30 | } // end namespace llvm |
| 31 | |
| 32 | #endif // LLVM_TOOLS_ELFABI_ELFOBJHANDLER_H |