58c50f58d750c7fd7e51bf8f956e077a1dd174cf
[oota-llvm.git] / tools / llvm-readobj / llvm-readobj.h
1 //===-- llvm-readobj.h ----------------------------------------------------===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef LLVM_TOOLS_LLVM_READOBJ_LLVM_READOBJ_H
11 #define LLVM_TOOLS_LLVM_READOBJ_LLVM_READOBJ_H
12
13 #include "llvm/Support/CommandLine.h"
14 #include <string>
15
16 namespace llvm {
17   namespace object {
18     class RelocationRef;
19   }
20
21   // Various helper functions.
22   void reportError(Twine Msg);
23   void error(std::error_code ec);
24   bool relocAddressLess(object::RelocationRef A,
25                         object::RelocationRef B);
26 } // namespace llvm
27
28 namespace opts {
29   extern llvm::cl::list<std::string> InputFilenames;
30   extern llvm::cl::opt<bool> FileHeaders;
31   extern llvm::cl::opt<bool> Sections;
32   extern llvm::cl::opt<bool> SectionRelocations;
33   extern llvm::cl::opt<bool> SectionSymbols;
34   extern llvm::cl::opt<bool> SectionData;
35   extern llvm::cl::opt<bool> Relocations;
36   extern llvm::cl::opt<bool> Symbols;
37   extern llvm::cl::opt<bool> DynamicSymbols;
38   extern llvm::cl::opt<bool> UnwindInfo;
39   extern llvm::cl::opt<bool> ExpandRelocs;
40   extern llvm::cl::opt<bool> CodeView;
41   extern llvm::cl::opt<bool> CodeViewSubsectionBytes;
42   extern llvm::cl::opt<bool> ARMAttributes;
43   extern llvm::cl::opt<bool> MipsPLTGOT;
44 } // namespace opts
45
46 #define LLVM_READOBJ_ENUM_ENT(ns, enum) \
47   { #enum, ns::enum }
48
49 #endif