]> git.pld-linux.org Git - packages/elfutils.git/commitdiff
- use gnu_inline attribute to prevent gcc 4.2.x warnings on libdw.h
authorJakub Bogusz <qboosh@pld-linux.org>
Sat, 19 May 2007 14:35:27 +0000 (14:35 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    elfutils-inline.patch -> 1.1

elfutils-inline.patch [new file with mode: 0644]

diff --git a/elfutils-inline.patch b/elfutils-inline.patch
new file mode 100644 (file)
index 0000000..917141f
--- /dev/null
@@ -0,0 +1,210 @@
+--- elfutils-0.127/src/ld.h.orig       2006-07-12 01:20:42.000000000 +0200
++++ elfutils-0.127/src/ld.h    2007-05-19 16:13:40.015849251 +0200
+@@ -1087,7 +1087,7 @@
+ /* Checked whether the symbol is undefined and referenced from a DSO.  */
+ extern bool linked_from_dso_p (struct scninfo *scninfo, size_t symidx);
+-extern inline bool
++extern __gnu_inline bool
+ linked_from_dso_p (struct scninfo *scninfo, size_t symidx)
+ {
+   struct usedfiles *file = scninfo->fileinfo;
+--- elfutils-0.127/libdwfl/dwfl_module_getsrc_file.c.orig      2006-04-11 22:52:05.000000000 +0200
++++ elfutils-0.127/libdwfl/dwfl_module_getsrc_file.c   2007-05-19 16:09:31.910875393 +0200
+@@ -79,15 +79,15 @@
+        && cu != NULL
+        && (error = __libdwfl_cu_getsrclines (cu)) == DWFL_E_NOERROR)
+     {
+-      inline const char *INTUSE(dwarf_line_file) (const Dwarf_Line *line)
++      __gnu_inline const char *INTUSE(dwarf_line_file) (const Dwarf_Line *line)
+       {
+         return line->files->info[line->file].name;
+       }
+-      inline Dwarf_Line *dwfl_line (const Dwfl_Line *line)
++      __gnu_inline Dwarf_Line *dwfl_line (const Dwfl_Line *line)
+       {
+         return &dwfl_linecu (line)->die.cu->lines->info[line->idx];
+       }
+-      inline const char *dwfl_line_file (const Dwfl_Line *line)
++      __gnu_inline const char *dwfl_line_file (const Dwfl_Line *line)
+       {
+         return INTUSE(dwarf_line_file) (dwfl_line (line));
+       }
+--- elfutils-0.127/libdwfl/elf-from-memory.c.orig      2007-03-11 03:11:55.000000000 +0100
++++ elfutils-0.127/libdwfl/elf-from-memory.c   2007-05-19 16:09:58.174735114 +0200
+@@ -215,7 +215,7 @@
+   GElf_Addr loadbase = ehdr_vma;
+   switch (ehdr.e32.e_ident[EI_CLASS])
+     {
+-      inline void handle_segment (GElf_Addr vaddr, GElf_Off offset,
++      __gnu_inline void handle_segment (GElf_Addr vaddr, GElf_Off offset,
+                                 GElf_Xword filesz, GElf_Xword align)
+       {
+         GElf_Off segment_end = ((offset + filesz + align - 1) & -align);
+@@ -276,7 +276,7 @@
+   switch (ehdr.e32.e_ident[EI_CLASS])
+     {
+-      inline bool handle_segment (GElf_Addr vaddr, GElf_Off offset,
++      __gnu_inline bool handle_segment (GElf_Addr vaddr, GElf_Off offset,
+                                 GElf_Xword filesz, GElf_Xword align)
+       {
+         GElf_Off start = offset & -align;
+--- elfutils-0.127/libdwfl/argp-std.c.orig     2007-04-05 11:12:36.000000000 +0200
++++ elfutils-0.127/libdwfl/argp-std.c  2007-05-19 16:08:04.209055832 +0200
+@@ -106,7 +106,7 @@
+ static error_t
+ parse_opt (int key, char *arg, struct argp_state *state)
+ {
+-  inline void failure (Dwfl *dwfl, int errnum, const char *msg)
++  __gnu_inline void failure (Dwfl *dwfl, int errnum, const char *msg)
+     {
+       if (errnum == -1)
+       argp_failure (state, EXIT_FAILURE, 0, "%s: %s",
+@@ -116,7 +116,7 @@
+       if (dwfl != NULL)
+       dwfl_end (dwfl);
+     }
+-  inline error_t fail (Dwfl *dwfl, int errnum, const char *msg)
++  __gnu_inline error_t fail (Dwfl *dwfl, int errnum, const char *msg)
+     {
+       failure (dwfl, errnum, msg);
+       return errnum == -1 ? EIO : errnum;
+--- elfutils-0.127/libdwfl/linux-kernel-modules.c.orig 2007-03-04 23:30:54.000000000 +0100
++++ elfutils-0.127/libdwfl/linux-kernel-modules.c      2007-05-19 16:08:38.559806212 +0200
+@@ -347,7 +347,7 @@
+ {
+   Dwarf_Addr start;
+   Dwarf_Addr end;
+-  inline int report (void)
++  __gnu_inline int report (void)
+     {
+       return INTUSE(dwfl_report_module) (dwfl, KERNEL_MODNAME,
+                                        start, end) == NULL ? -1 : 0;
+@@ -421,7 +421,7 @@
+      only '_' and one only using '-'.  */
+   char alternate_name[namelen + 1];
+-  inline bool subst_name (char from, char to)
++  __gnu_inline bool subst_name (char from, char to)
+     {
+       const char *n = memchr (module_name, from, namelen);
+       if (n == NULL)
+--- elfutils-0.127/libdwfl/linux-proc-maps.c.orig      2007-04-05 11:12:36.000000000 +0200
++++ elfutils-0.127/libdwfl/linux-proc-maps.c   2007-05-19 16:09:02.093611158 +0200
+@@ -134,7 +134,7 @@
+   char *last_file = NULL;
+   Dwarf_Addr low = 0, high = 0;
+-  inline bool report (void)
++  __gnu_inline bool report (void)
+     {
+       if (last_file != NULL)
+       {
+--- elfutils-0.127/libdwfl/dwfl_module_addrsym.c.orig  2007-03-04 23:00:19.000000000 +0100
++++ elfutils-0.127/libdwfl/dwfl_module_addrsym.c       2007-05-19 16:10:28.605345054 +0200
+@@ -59,7 +59,7 @@
+   /* Return true iff we consider ADDR to lie in the same section as SYM.  */
+   GElf_Word addr_shndx = SHN_UNDEF;
+-  inline bool same_section (const GElf_Sym *sym, GElf_Word shndx)
++  __gnu_inline bool same_section (const GElf_Sym *sym, GElf_Word shndx)
+     {
+       /* For absolute symbols and the like, only match exactly.  */
+       if (shndx >= SHN_LORESERVE)
+@@ -108,7 +108,7 @@
+       const char *name = INTUSE(dwfl_module_getsym) (mod, i, &sym, &shndx);
+       if (name != NULL && sym.st_value <= addr)
+       {
+-        inline void closest (void)
++        __gnu_inline void closest (void)
+           {
+             *closest_sym = sym;
+             closest_shndx = shndx;
+--- elfutils-0.127/backends/ia64_retval.c.orig 2006-07-21 13:28:28.000000000 +0200
++++ elfutils-0.127/backends/ia64_retval.c      2007-05-19 16:13:08.295213177 +0200
+@@ -96,7 +96,7 @@
+      If we find a datum that's not the same FP type as the first datum, punt.
+      If we count more than eight total homogeneous FP data, punt.  */
+-  inline int hfa (const Dwarf_Op *loc, int nregs)
++  __gnu_inline int hfa (const Dwarf_Op *loc, int nregs)
+     {
+       if (fpregs_used == 0)
+       *locp = loc;
+--- elfutils-0.127/libdw/libdw.h.orig  2007-04-05 12:33:43.000000000 +0200
++++ elfutils-0.127/libdw/libdw.h       2007-05-19 16:07:34.811667724 +0200
+@@ -623,15 +623,20 @@
+ /* Inline optimizations.  */
+ #ifdef __OPTIMIZE__
++# if defined(__GNUC_STDC_INLINE__) || defined(__GNUC_GNU_INLINE__)
++#  define __gnu_inline inline __attribute__ ((__gnu_inline__))
++# else
++#  define __gnu_inline inline
++# endif
+ /* Return attribute code of given attribute.  */
+-extern inline unsigned int
++extern __gnu_inline unsigned int
+ dwarf_whatattr (Dwarf_Attribute *attr)
+ {
+   return attr == NULL ? 0 : attr->code;
+ }
+ /* Return attribute code of given attribute.  */
+-extern inline unsigned int
++extern __gnu_inline unsigned int
+ dwarf_whatform (Dwarf_Attribute *attr)
+ {
+   return attr == NULL ? 0 : attr->form;
+--- elfutils-0.127/libdw/dwarf_getscopevar.c.orig      2006-04-11 22:52:05.000000000 +0200
++++ elfutils-0.127/libdw/dwarf_getscopevar.c   2007-05-19 16:11:06.586106385 +0200
+@@ -93,7 +93,7 @@
+   size_t match_file_len = match_file == NULL ? 0 : strlen (match_file);
+   bool lastfile_matches = false;
+   const char *lastfile = NULL;
+-  inline bool file_matches (Dwarf_Files *files, size_t idx)
++  __gnu_inline bool file_matches (Dwarf_Files *files, size_t idx)
+     {
+       if (idx >= files->nfiles)
+       return false;
+--- elfutils-0.127/libdw/libdw_visit_scopes.c.orig     2006-04-11 22:52:05.000000000 +0200
++++ elfutils-0.127/libdw/libdw_visit_scopes.c  2007-05-19 16:11:28.309875205 +0200
+@@ -107,7 +107,7 @@
+   if (INTUSE(dwarf_child) (&root->die, &child.die) != 0)
+     return -1;
+-  inline int recurse (void)
++  __gnu_inline int recurse (void)
+     {
+       return __libdw_visit_scopes (depth + 1, &child,
+                                  previsit, postvisit, arg);
+--- elfutils-0.127/libdw/dwarf_entry_breakpoints.c.orig        2006-04-11 22:52:05.000000000 +0200
++++ elfutils-0.127/libdw/dwarf_entry_breakpoints.c     2007-05-19 16:12:17.807534209 +0200
+@@ -64,7 +64,7 @@
+   *bkpts = NULL;
+   /* Add one breakpoint location to the result vector.  */
+-  inline int add_bkpt (Dwarf_Addr pc)
++  __gnu_inline int add_bkpt (Dwarf_Addr pc)
+     {
+       Dwarf_Addr *newlist = realloc (*bkpts, ++nbkpts * sizeof newlist[0]);
+       if (newlist == NULL)
+@@ -80,7 +80,7 @@
+     }
+   /* Fallback result, break at the entrypc/lowpc value.  */
+-  inline int entrypc_bkpt (void)
++  __gnu_inline int entrypc_bkpt (void)
+     {
+       Dwarf_Addr pc;
+       return INTUSE(dwarf_entrypc) (die, &pc) < 0 ? -1 : add_bkpt (pc);
+@@ -107,7 +107,7 @@
+   /* Search a contiguous PC range for prologue-end markers.
+      If DWARF, look for proper markers.
+      Failing that, if ADHOC, look for the ad hoc convention.  */
+-  inline int search_range (Dwarf_Addr low, Dwarf_Addr high,
++  __gnu_inline int search_range (Dwarf_Addr low, Dwarf_Addr high,
+                          bool dwarf, bool adhoc)
+     {
+       size_t l = 0, u = nlines;
This page took 0.098436 seconds and 4 git commands to generate.