[Glibc-bsd-commits] r4231 - in trunk/kfreebsd-kernel-headers/debian: . patches

Robert Millan rmh at alioth.debian.org
Sun Apr 22 09:14:01 UTC 2012


Author: rmh
Date: 2012-04-22 09:14:01 +0000 (Sun, 22 Apr 2012)
New Revision: 4231

Modified:
   trunk/kfreebsd-kernel-headers/debian/changelog
   trunk/kfreebsd-kernel-headers/debian/patches/011_wine.diff
Log:
011_wine.diff: Only disable ELF declarations that collide with GNU ones.

Modified: trunk/kfreebsd-kernel-headers/debian/changelog
===================================================================
--- trunk/kfreebsd-kernel-headers/debian/changelog	2012-04-22 08:34:14 UTC (rev 4230)
+++ trunk/kfreebsd-kernel-headers/debian/changelog	2012-04-22 09:14:01 UTC (rev 4231)
@@ -14,8 +14,10 @@
     <elf.h>.
   * Remove out[bwl] regex rule. Instead, error out in
     <machine/cpufunc.h> when <sys/io.h> has been included.
+  * 011_wine.diff: Only disable ELF declarations that collide with GNU
+    ones.
 
- -- Robert Millan <rmh at debian.org>  Sun, 22 Apr 2012 10:34:06 +0200
+ -- Robert Millan <rmh at debian.org>  Sun, 22 Apr 2012 11:13:55 +0200
 
 kfreebsd-kernel-headers (0.79) unstable; urgency=low
 

Modified: trunk/kfreebsd-kernel-headers/debian/patches/011_wine.diff
===================================================================
--- trunk/kfreebsd-kernel-headers/debian/patches/011_wine.diff	2012-04-22 08:34:14 UTC (rev 4230)
+++ trunk/kfreebsd-kernel-headers/debian/patches/011_wine.diff	2012-04-22 09:14:01 UTC (rev 4231)
@@ -1,429 +1,131 @@
 --- a/sys/sys/elf32.h
 +++ b/sys/sys/elf32.h
-@@ -35,11 +35,9 @@
+@@ -30,16 +30,19 @@
+ #define _SYS_ELF32_H_ 1
+ 
+ #include <sys/elf_common.h>
++#include <elf.h>
+ 
+ /*
   * ELF definitions common to all 32-bit architectures.
   */
  
--typedef uint32_t	Elf32_Addr;
--typedef uint16_t	Elf32_Half;
--typedef uint32_t	Elf32_Off;
--typedef int32_t		Elf32_Sword;
--typedef uint32_t	Elf32_Word;
-+#include <elf.h>
-+
-+
++#if 0
+ typedef uint32_t	Elf32_Addr;
+ typedef uint16_t	Elf32_Half;
+ typedef uint32_t	Elf32_Off;
+ typedef int32_t		Elf32_Sword;
+ typedef uint32_t	Elf32_Word;
++#endif
  typedef uint64_t	Elf32_Lword;
  
  typedef Elf32_Word	Elf32_Hashelt;
-@@ -48,198 +46,4 @@
+@@ -48,6 +51,7 @@
  typedef Elf32_Word	Elf32_Size;
  typedef Elf32_Sword	Elf32_Ssize;
  
--/*
-- * ELF header.
-- */
--
--typedef struct {
--	unsigned char	e_ident[EI_NIDENT];	/* File identification. */
--	Elf32_Half	e_type;		/* File type. */
--	Elf32_Half	e_machine;	/* Machine architecture. */
--	Elf32_Word	e_version;	/* ELF format version. */
--	Elf32_Addr	e_entry;	/* Entry point. */
--	Elf32_Off	e_phoff;	/* Program header file offset. */
--	Elf32_Off	e_shoff;	/* Section header file offset. */
--	Elf32_Word	e_flags;	/* Architecture-specific flags. */
--	Elf32_Half	e_ehsize;	/* Size of ELF header in bytes. */
--	Elf32_Half	e_phentsize;	/* Size of program header entry. */
--	Elf32_Half	e_phnum;	/* Number of program header entries. */
--	Elf32_Half	e_shentsize;	/* Size of section header entry. */
--	Elf32_Half	e_shnum;	/* Number of section header entries. */
--	Elf32_Half	e_shstrndx;	/* Section name strings section. */
--} Elf32_Ehdr;
--
--/*
-- * Section header.
-- */
--
--typedef struct {
--	Elf32_Word	sh_name;	/* Section name (index into the
--					   section header string table). */
--	Elf32_Word	sh_type;	/* Section type. */
--	Elf32_Word	sh_flags;	/* Section flags. */
--	Elf32_Addr	sh_addr;	/* Address in memory image. */
--	Elf32_Off	sh_offset;	/* Offset in file. */
--	Elf32_Word	sh_size;	/* Size in bytes. */
--	Elf32_Word	sh_link;	/* Index of a related section. */
--	Elf32_Word	sh_info;	/* Depends on section type. */
--	Elf32_Word	sh_addralign;	/* Alignment in bytes. */
--	Elf32_Word	sh_entsize;	/* Size of each entry in section. */
--} Elf32_Shdr;
--
--/*
-- * Program header.
-- */
--
--typedef struct {
--	Elf32_Word	p_type;		/* Entry type. */
--	Elf32_Off	p_offset;	/* File offset of contents. */
--	Elf32_Addr	p_vaddr;	/* Virtual address in memory image. */
--	Elf32_Addr	p_paddr;	/* Physical address (not used). */
--	Elf32_Word	p_filesz;	/* Size of contents in file. */
--	Elf32_Word	p_memsz;	/* Size of contents in memory. */
--	Elf32_Word	p_flags;	/* Access permission flags. */
--	Elf32_Word	p_align;	/* Alignment in memory and file. */
--} Elf32_Phdr;
--
--/*
-- * Dynamic structure.  The ".dynamic" section contains an array of them.
-- */
--
--typedef struct {
--	Elf32_Sword	d_tag;		/* Entry type. */
--	union {
--		Elf32_Word	d_val;	/* Integer value. */
--		Elf32_Addr	d_ptr;	/* Address value. */
--	} d_un;
--} Elf32_Dyn;
--
--/*
-- * Relocation entries.
-- */
--
--/* Relocations that don't need an addend field. */
--typedef struct {
--	Elf32_Addr	r_offset;	/* Location to be relocated. */
--	Elf32_Word	r_info;		/* Relocation type and symbol index. */
--} Elf32_Rel;
--
--/* Relocations that need an addend field. */
--typedef struct {
--	Elf32_Addr	r_offset;	/* Location to be relocated. */
--	Elf32_Word	r_info;		/* Relocation type and symbol index. */
--	Elf32_Sword	r_addend;	/* Addend. */
--} Elf32_Rela;
--
--/* Macros for accessing the fields of r_info. */
--#define ELF32_R_SYM(info)	((info) >> 8)
--#define ELF32_R_TYPE(info)	((unsigned char)(info))
--
--/* Macro for constructing r_info from field values. */
--#define ELF32_R_INFO(sym, type)	(((sym) << 8) + (unsigned char)(type))
--
--/*
-- *	Note entry header
-- */
--typedef Elf_Note Elf32_Nhdr;
--
--/*
-- *	Move entry
-- */
--typedef struct {
--	Elf32_Lword	m_value;	/* symbol value */
--	Elf32_Word 	m_info;		/* size + index */
--	Elf32_Word	m_poffset;	/* symbol offset */
--	Elf32_Half	m_repeat;	/* repeat count */
--	Elf32_Half	m_stride;	/* stride info */
--} Elf32_Move;
--
--/*
-- *	The macros compose and decompose values for Move.r_info
-- *
-- *	sym = ELF32_M_SYM(M.m_info)
-- *	size = ELF32_M_SIZE(M.m_info)
-- *	M.m_info = ELF32_M_INFO(sym, size)
-- */
--#define	ELF32_M_SYM(info)	((info)>>8)
--#define	ELF32_M_SIZE(info)	((unsigned char)(info))
--#define	ELF32_M_INFO(sym, size)	(((sym)<<8)+(unsigned char)(size))
--
--/*
-- *	Hardware/Software capabilities entry
-- */
--typedef struct {
--	Elf32_Word	c_tag;		/* how to interpret value */
--	union {
--		Elf32_Word	c_val;
--		Elf32_Addr	c_ptr;
--	} c_un;
--} Elf32_Cap;
--
--/*
-- * Symbol table entries.
-- */
--
--typedef struct {
--	Elf32_Word	st_name;	/* String table index of name. */
--	Elf32_Addr	st_value;	/* Symbol value. */
--	Elf32_Word	st_size;	/* Size of associated object. */
--	unsigned char	st_info;	/* Type and binding information. */
--	unsigned char	st_other;	/* Reserved (not used). */
--	Elf32_Half	st_shndx;	/* Section index of symbol. */
--} Elf32_Sym;
--
--/* Macros for accessing the fields of st_info. */
--#define ELF32_ST_BIND(info)		((info) >> 4)
--#define ELF32_ST_TYPE(info)		((info) & 0xf)
--
--/* Macro for constructing st_info from field values. */
--#define ELF32_ST_INFO(bind, type)	(((bind) << 4) + ((type) & 0xf))
--
--/* Macro for accessing the fields of st_other. */
--#define ELF32_ST_VISIBILITY(oth)	((oth) & 0x3)
--
--/* Structures used by Sun & GNU symbol versioning. */
--typedef struct
--{
--	Elf32_Half	vd_version;
--	Elf32_Half	vd_flags;
--	Elf32_Half	vd_ndx;
--	Elf32_Half	vd_cnt;
--	Elf32_Word	vd_hash;
--	Elf32_Word	vd_aux;
--	Elf32_Word	vd_next;
--} Elf32_Verdef;
--
--typedef struct
--{
--	Elf32_Word	vda_name;
--	Elf32_Word	vda_next;
--} Elf32_Verdaux;
--
--typedef struct
--{
--	Elf32_Half	vn_version;
--	Elf32_Half	vn_cnt;
--	Elf32_Word	vn_file;
--	Elf32_Word	vn_aux;
--	Elf32_Word	vn_next;
--} Elf32_Verneed;
--
--typedef struct
--{
--	Elf32_Word	vna_hash;
--	Elf32_Half	vna_flags;
--	Elf32_Half	vna_other;
--	Elf32_Word	vna_name;
--	Elf32_Word	vna_next;
--} Elf32_Vernaux;
--
--typedef Elf32_Half Elf32_Versym;
--
--typedef struct {
--	Elf32_Half	si_boundto;	/* direct bindings - symbol bound to */
--	Elf32_Half	si_flags;	/* per symbol flags */
--} Elf32_Syminfo;
--
++#if 0
+ /*
+  * ELF header.
+  */
+@@ -165,6 +169,8 @@
+ #define	ELF32_M_SIZE(info)	((unsigned char)(info))
+ #define	ELF32_M_INFO(sym, size)	(((sym)<<8)+(unsigned char)(size))
+ 
++#endif
++
+ /*
+  *	Hardware/Software capabilities entry
+  */
+@@ -176,6 +182,7 @@
+ 	} c_un;
+ } Elf32_Cap;
+ 
++#if 0
+ /*
+  * Symbol table entries.
+  */
+@@ -234,12 +241,15 @@
+ 	Elf32_Word	vna_name;
+ 	Elf32_Word	vna_next;
+ } Elf32_Vernaux;
++#endif
+ 
+ typedef Elf32_Half Elf32_Versym;
+ 
++#if 0
+ typedef struct {
+ 	Elf32_Half	si_boundto;	/* direct bindings - symbol bound to */
+ 	Elf32_Half	si_flags;	/* per symbol flags */
+ } Elf32_Syminfo;
++#endif
+ 
  #endif /* !_SYS_ELF32_H_ */
 --- a/sys/sys/elf64.h
 +++ b/sys/sys/elf64.h
-@@ -35,14 +35,10 @@
+@@ -30,19 +30,24 @@
+ #define _SYS_ELF64_H_ 1
+ 
+ #include <sys/elf_common.h>
++#include <elf.h>
+ 
+ /*
   * ELF definitions common to all 64-bit architectures.
   */
  
--typedef uint64_t	Elf64_Addr;
--typedef uint16_t	Elf64_Half;
--typedef uint64_t	Elf64_Off;
--typedef int32_t		Elf64_Sword;
--typedef int64_t		Elf64_Sxword;
--typedef uint32_t	Elf64_Word;
-+#include <elf.h>
-+
-+
++#if 0
+ typedef uint64_t	Elf64_Addr;
+ typedef uint16_t	Elf64_Half;
+ typedef uint64_t	Elf64_Off;
+ typedef int32_t		Elf64_Sword;
+ typedef int64_t		Elf64_Sxword;
+ typedef uint32_t	Elf64_Word;
++#endif
  typedef uint64_t	Elf64_Lword;
--typedef uint64_t	Elf64_Xword;
++#if 0
+ typedef uint64_t	Elf64_Xword;
++#endif
  
  /*
   * Types of dynamic symbol hash table bucket and chain elements.
-@@ -57,192 +53,4 @@
+@@ -57,6 +62,7 @@
  typedef Elf64_Xword	Elf64_Size;
  typedef Elf64_Sxword	Elf64_Ssize;
  
--/*
-- * ELF header.
-- */
--
--typedef struct {
--	unsigned char	e_ident[EI_NIDENT];	/* File identification. */
--	Elf64_Half	e_type;		/* File type. */
--	Elf64_Half	e_machine;	/* Machine architecture. */
--	Elf64_Word	e_version;	/* ELF format version. */
--	Elf64_Addr	e_entry;	/* Entry point. */
--	Elf64_Off	e_phoff;	/* Program header file offset. */
--	Elf64_Off	e_shoff;	/* Section header file offset. */
--	Elf64_Word	e_flags;	/* Architecture-specific flags. */
--	Elf64_Half	e_ehsize;	/* Size of ELF header in bytes. */
--	Elf64_Half	e_phentsize;	/* Size of program header entry. */
--	Elf64_Half	e_phnum;	/* Number of program header entries. */
--	Elf64_Half	e_shentsize;	/* Size of section header entry. */
--	Elf64_Half	e_shnum;	/* Number of section header entries. */
--	Elf64_Half	e_shstrndx;	/* Section name strings section. */
--} Elf64_Ehdr;
--
--/*
-- * Section header.
-- */
--
--typedef struct {
--	Elf64_Word	sh_name;	/* Section name (index into the
--					   section header string table). */
--	Elf64_Word	sh_type;	/* Section type. */
--	Elf64_Xword	sh_flags;	/* Section flags. */
--	Elf64_Addr	sh_addr;	/* Address in memory image. */
--	Elf64_Off	sh_offset;	/* Offset in file. */
--	Elf64_Xword	sh_size;	/* Size in bytes. */
--	Elf64_Word	sh_link;	/* Index of a related section. */
--	Elf64_Word	sh_info;	/* Depends on section type. */
--	Elf64_Xword	sh_addralign;	/* Alignment in bytes. */
--	Elf64_Xword	sh_entsize;	/* Size of each entry in section. */
--} Elf64_Shdr;
--
--/*
-- * Program header.
-- */
--
--typedef struct {
--	Elf64_Word	p_type;		/* Entry type. */
--	Elf64_Word	p_flags;	/* Access permission flags. */
--	Elf64_Off	p_offset;	/* File offset of contents. */
--	Elf64_Addr	p_vaddr;	/* Virtual address in memory image. */
--	Elf64_Addr	p_paddr;	/* Physical address (not used). */
--	Elf64_Xword	p_filesz;	/* Size of contents in file. */
--	Elf64_Xword	p_memsz;	/* Size of contents in memory. */
--	Elf64_Xword	p_align;	/* Alignment in memory and file. */
--} Elf64_Phdr;
--
--/*
-- * Dynamic structure.  The ".dynamic" section contains an array of them.
-- */
--
--typedef struct {
--	Elf64_Sxword	d_tag;		/* Entry type. */
--	union {
--		Elf64_Xword	d_val;	/* Integer value. */
--		Elf64_Addr	d_ptr;	/* Address value. */
--	} d_un;
--} Elf64_Dyn;
--
--/*
-- * Relocation entries.
-- */
--
--/* Relocations that don't need an addend field. */
--typedef struct {
--	Elf64_Addr	r_offset;	/* Location to be relocated. */
--	Elf64_Xword	r_info;		/* Relocation type and symbol index. */
--} Elf64_Rel;
--
--/* Relocations that need an addend field. */
--typedef struct {
--	Elf64_Addr	r_offset;	/* Location to be relocated. */
--	Elf64_Xword	r_info;		/* Relocation type and symbol index. */
--	Elf64_Sxword	r_addend;	/* Addend. */
--} Elf64_Rela;
--
--/* Macros for accessing the fields of r_info. */
--#define	ELF64_R_SYM(info)	((info) >> 32)
--#define	ELF64_R_TYPE(info)	((info) & 0xffffffffL)
--
--/* Macro for constructing r_info from field values. */
--#define	ELF64_R_INFO(sym, type)	(((sym) << 32) + ((type) & 0xffffffffL))
--
--#define	ELF64_R_TYPE_DATA(info)	(((Elf64_Xword)(info)<<32)>>40)
--#define	ELF64_R_TYPE_ID(info)	(((Elf64_Xword)(info)<<56)>>56)
--#define	ELF64_R_TYPE_INFO(data, type)	\
--				(((Elf64_Xword)(data)<<8)+(Elf64_Xword)(type))
--
--/*
-- *	Note entry header
-- */
--typedef Elf_Note Elf64_Nhdr;
--
--/*
-- *	Move entry
-- */
--typedef struct {
--	Elf64_Lword	m_value;	/* symbol value */
--	Elf64_Xword 	m_info;		/* size + index */
--	Elf64_Xword	m_poffset;	/* symbol offset */
--	Elf64_Half	m_repeat;	/* repeat count */
--	Elf64_Half	m_stride;	/* stride info */
--} Elf64_Move;
--
--#define	ELF64_M_SYM(info)	((info)>>8)
--#define	ELF64_M_SIZE(info)	((unsigned char)(info))
--#define	ELF64_M_INFO(sym, size)	(((sym)<<8)+(unsigned char)(size))
--
--/*
-- *	Hardware/Software capabilities entry
-- */
--typedef struct {
--	Elf64_Xword	c_tag;		/* how to interpret value */
--	union {
--		Elf64_Xword	c_val;
--		Elf64_Addr	c_ptr;
--	} c_un;
--} Elf64_Cap;
--
--/*
-- * Symbol table entries.
-- */
--
--typedef struct {
--	Elf64_Word	st_name;	/* String table index of name. */
--	unsigned char	st_info;	/* Type and binding information. */
--	unsigned char	st_other;	/* Reserved (not used). */
--	Elf64_Half	st_shndx;	/* Section index of symbol. */
--	Elf64_Addr	st_value;	/* Symbol value. */
--	Elf64_Xword	st_size;	/* Size of associated object. */
--} Elf64_Sym;
--
--/* Macros for accessing the fields of st_info. */
--#define	ELF64_ST_BIND(info)		((info) >> 4)
--#define	ELF64_ST_TYPE(info)		((info) & 0xf)
--
--/* Macro for constructing st_info from field values. */
--#define	ELF64_ST_INFO(bind, type)	(((bind) << 4) + ((type) & 0xf))
--
--/* Macro for accessing the fields of st_other. */
--#define	ELF64_ST_VISIBILITY(oth)	((oth) & 0x3)
--
--/* Structures used by Sun & GNU-style symbol versioning. */
--typedef struct {
--	Elf64_Half	vd_version;
--	Elf64_Half	vd_flags;
--	Elf64_Half	vd_ndx;
--	Elf64_Half	vd_cnt;
--	Elf64_Word	vd_hash;
--	Elf64_Word	vd_aux;
--	Elf64_Word	vd_next;
--} Elf64_Verdef;
--
--typedef struct {
--	Elf64_Word	vda_name;
--	Elf64_Word	vda_next;
--} Elf64_Verdaux;
--
--typedef struct {
--	Elf64_Half	vn_version;
--	Elf64_Half	vn_cnt;
--	Elf64_Word	vn_file;
--	Elf64_Word	vn_aux;
--	Elf64_Word	vn_next;
--} Elf64_Verneed;
--
--typedef struct {
--	Elf64_Word	vna_hash;
--	Elf64_Half	vna_flags;
--	Elf64_Half	vna_other;
--	Elf64_Word	vna_name;
--	Elf64_Word	vna_next;
--} Elf64_Vernaux;
--
--typedef Elf64_Half Elf64_Versym;
--
--typedef struct {
--	Elf64_Half	si_boundto;	/* direct bindings - symbol bound to */
--	Elf64_Half	si_flags;	/* per symbol flags */
--} Elf64_Syminfo;
--
++#if 0
+ /*
+  * ELF header.
+  */
+@@ -172,6 +178,8 @@
+ #define	ELF64_M_SIZE(info)	((unsigned char)(info))
+ #define	ELF64_M_INFO(sym, size)	(((sym)<<8)+(unsigned char)(size))
+ 
++#endif
++
+ /*
+  *	Hardware/Software capabilities entry
+  */
+@@ -183,6 +191,7 @@
+ 	} c_un;
+ } Elf64_Cap;
+ 
++#if 0
+ /*
+  * Symbol table entries.
+  */
+@@ -237,12 +246,15 @@
+ 	Elf64_Word	vna_name;
+ 	Elf64_Word	vna_next;
+ } Elf64_Vernaux;
++#endif
+ 
+ typedef Elf64_Half Elf64_Versym;
+ 
++#if 0
+ typedef struct {
+ 	Elf64_Half	si_boundto;	/* direct bindings - symbol bound to */
+ 	Elf64_Half	si_flags;	/* per symbol flags */
+ } Elf64_Syminfo;
++#endif
+ 
  #endif /* !_SYS_ELF64_H_ */




More information about the Glibc-bsd-commits mailing list