This is the mail archive of the binutils-cvs@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Add Elf_Internal_Chdr and ElfXX_External_Chdr


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=6aa76120296414774436cc14c60fe10fef86aa0f

commit 6aa76120296414774436cc14c60fe10fef86aa0f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Apr 3 12:49:45 2015 -0700

    Add Elf_Internal_Chdr and ElfXX_External_Chdr
    
    	* external.h (Elf32_External_Chdr): New.
    	(Elf64_External_Chdr): Likewise.
    	* internal.h (Elf_Internal_Chdr): Likewise.

Diff:
---
 include/elf/ChangeLog  |  6 ++++++
 include/elf/external.h | 14 ++++++++++++++
 include/elf/internal.h |  8 ++++++++
 3 files changed, 28 insertions(+)

diff --git a/include/elf/ChangeLog b/include/elf/ChangeLog
index 2c7139d..55bc60c 100644
--- a/include/elf/ChangeLog
+++ b/include/elf/ChangeLog
@@ -1,3 +1,9 @@
+2015-04-03  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* external.h (Elf32_External_Chdr): New.
+	(Elf64_External_Chdr): Likewise.
+	* internal.h (Elf_Internal_Chdr): Likewise.
+
 2015-03-26  H.J. Lu  <hongjiu.lu@intel.com>
 
 	* common.h (ELFOSABI_CLOUDABI): New.
diff --git a/include/elf/external.h b/include/elf/external.h
index cd93c3c..b6057b5 100644
--- a/include/elf/external.h
+++ b/include/elf/external.h
@@ -135,6 +135,20 @@ typedef struct {
   unsigned char	sh_entsize[8];		/* Entry size if section holds table */
 } Elf64_External_Shdr;
 
+/* Compression header */
+
+typedef struct {
+  unsigned char	ch_type[4];		/* Type of compression */
+  unsigned char	ch_size[4];		/* Size of uncompressed data in bytes */
+  unsigned char	ch_addralign[4];	/* Alignment of uncompressed data  */
+} Elf32_External_Chdr;
+
+typedef struct {
+  unsigned char	ch_type[8];		/* Type of compression */
+  unsigned char	ch_size[8];		/* Size of uncompressed data in bytes */
+  unsigned char	ch_addralign[8];	/* Alignment of uncompressed data  */
+} Elf64_External_Chdr;
+
 /* Symbol table entry */
 
 typedef struct {
diff --git a/include/elf/internal.h b/include/elf/internal.h
index 04e0582..b2492f5 100644
--- a/include/elf/internal.h
+++ b/include/elf/internal.h
@@ -115,6 +115,14 @@ typedef struct elf_internal_shdr {
   unsigned char *contents;		/* Section contents.  */
 } Elf_Internal_Shdr;
 
+/* Compression header */
+
+typedef struct elf_internal_chdr {
+  unsigned int	ch_type;		/* Type of compression */
+  bfd_size_type	ch_size;		/* Size of uncompressed data in bytes */
+  bfd_vma	ch_addralign;		/* Alignment of uncompressed data */
+} Elf_Internal_Chdr;
+
 /* Symbol table entry */
 
 struct elf_internal_sym {


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]