Move createELFObjectWriter to its own header.
authorRafael Espindola <rafael.espindola@gmail.com>
Fri, 17 Dec 2010 16:59:53 +0000 (16:59 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Fri, 17 Dec 2010 16:59:53 +0000 (16:59 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122064 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/MC/MCELFObjectWriter.h [new file with mode: 0644]
include/llvm/MC/MCObjectWriter.h
lib/MC/ELFObjectWriter.cpp
lib/Target/ARM/ARMAsmBackend.cpp
lib/Target/MBlaze/MBlazeAsmBackend.cpp
lib/Target/X86/X86AsmBackend.cpp

diff --git a/include/llvm/MC/MCELFObjectWriter.h b/include/llvm/MC/MCELFObjectWriter.h
new file mode 100644 (file)
index 0000000..2a82ec1
--- /dev/null
@@ -0,0 +1,27 @@
+//===-- llvm/MC/MCELFObjectWriter.h - ELF Object Writer ---------*- C++ -*-===//
+//
+//                     The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+#ifndef LLVM_MC_MCELFOBJECTWRITER_H
+#define LLVM_MC_MCELFOBJECTWRITER_H
+
+#include "llvm/MC/MCObjectWriter.h"
+#include "llvm/Support/DataTypes.h"
+
+namespace llvm {
+/// \brief Construct a new ELF writer instance.
+///
+/// \param OS - The stream to write to.
+/// \returns The constructed object writer.
+MCObjectWriter *createELFObjectWriter(raw_ostream &OS, bool is64Bit,
+                                      Triple::OSType OSType, uint16_t EMachine,
+                                      bool IsLittleEndian,
+                                      bool HasRelocationAddend);
+} // End llvm namespace
+
+#endif
index 60625b4b53603d602cf78471bcba983e4e319c3c..73bad2a179a3cfbd6a033fb198a25090daf857c2 100644 (file)
@@ -190,10 +190,6 @@ public:
   static void EncodeULEB128(uint64_t Value, raw_ostream &OS);
 };
 
-MCObjectWriter *createELFObjectWriter(raw_ostream &OS, bool is64Bit,
-                                      Triple::OSType OSType, uint16_t EMachine,
-                                      bool IsLittleEndian,
-                                      bool HasRelocationAddend);
 MCObjectWriter *createWinCOFFObjectWriter(raw_ostream &OS, bool is64Bit);
 
 } // End llvm namespace
index da58e38df9f4832f74949f47e272a13fa452fbb1..57ec5492cdad36d3152fca97bc0c20dc62c8382a 100644 (file)
@@ -20,6 +20,7 @@
 #include "llvm/MC/MCContext.h"
 #include "llvm/MC/MCELFSymbolFlags.h"
 #include "llvm/MC/MCExpr.h"
+#include "llvm/MC/MCELFObjectWriter.h"
 #include "llvm/MC/MCObjectWriter.h"
 #include "llvm/MC/MCSectionELF.h"
 #include "llvm/MC/MCSymbol.h"
index 7f9d3081df47adbdd5dc1a91e9e3faacf6b237eb..414c2605f5619f4e9a9994d4e1ddc920f2b986ea 100644 (file)
@@ -13,6 +13,7 @@
 #include "llvm/ADT/Twine.h"
 #include "llvm/MC/MCAssembler.h"
 #include "llvm/MC/MCDirectives.h"
+#include "llvm/MC/MCELFObjectWriter.h"
 #include "llvm/MC/MCExpr.h"
 #include "llvm/MC/MCMachObjectWriter.h"
 #include "llvm/MC/MCObjectFormat.h"
index d3be2b55aec1d74d0b152ddd4eae63b61d00353e..94b8fd8d71b20fbda6a9ddb1e4903a6067af4724 100644 (file)
@@ -13,6 +13,7 @@
 #include "llvm/ADT/Twine.h"
 #include "llvm/MC/MCAssembler.h"
 #include "llvm/MC/MCAsmLayout.h"
+#include "llvm/MC/MCELFObjectWriter.h"
 #include "llvm/MC/MCELFSymbolFlags.h"
 #include "llvm/MC/MCExpr.h"
 #include "llvm/MC/MCObjectFormat.h"
index fe894ab7a14b641a99b74c38f4b1377642ae282b..2b13c0a0049656a6026071c6f7de1d8c07f7ed34 100644 (file)
@@ -12,6 +12,7 @@
 #include "X86FixupKinds.h"
 #include "llvm/ADT/Twine.h"
 #include "llvm/MC/MCAssembler.h"
+#include "llvm/MC/MCELFObjectWriter.h"
 #include "llvm/MC/MCExpr.h"
 #include "llvm/MC/MCFixupKindInfo.h"
 #include "llvm/MC/MCMachObjectWriter.h"