summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Wegener <swegener@gentoo.org>2009-11-14 09:14:35 +0000
committerSven Wegener <swegener@gentoo.org>2009-11-14 09:14:35 +0000
commit4f34a61f7f5e320f68d8d188bad555f147901d82 (patch)
tree7f5dfa3262b389240e5b1f0d4aa4f0320ce31f62 /dev-util/debugedit
parentVersion bump via perl-bump experimental tool. (diff)
downloadgentoo-2-4f34a61f7f5e320f68d8d188bad555f147901d82.tar.gz
gentoo-2-4f34a61f7f5e320f68d8d188bad555f147901d82.tar.bz2
gentoo-2-4f34a61f7f5e320f68d8d188bad555f147901d82.zip
Instead od pulling in one big update, bump the whole tarball to debugedit taken
from rpm-5.1.9. Also include support for build-id, which has been dropped on purpose in the last update, but portage supports this for over a year now. (Portage version: 2.2_rc49/cvs/Linux x86_64)
Diffstat (limited to 'dev-util/debugedit')
-rw-r--r--dev-util/debugedit/ChangeLog12
-rw-r--r--dev-util/debugedit/debugedit-5.1.9.ebuild34
-rw-r--r--dev-util/debugedit/files/debugedit-5.1.9-DWARF-3.patch152
-rw-r--r--dev-util/debugedit/files/debugedit-5.1.9-cleanup.patch34
4 files changed, 231 insertions, 1 deletions
diff --git a/dev-util/debugedit/ChangeLog b/dev-util/debugedit/ChangeLog
index 08239bc1b9a6..3dd038043824 100644
--- a/dev-util/debugedit/ChangeLog
+++ b/dev-util/debugedit/ChangeLog
@@ -1,6 +1,16 @@
# ChangeLog for dev-util/debugedit
# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-util/debugedit/ChangeLog,v 1.21 2009/10/21 07:40:50 loki_val Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-util/debugedit/ChangeLog,v 1.22 2009/11/14 09:14:33 swegener Exp $
+
+*debugedit-5.1.9 (14 Nov 2009)
+
+ 14 Nov 2009; Sven Wegener <swegener@gentoo.org> +debugedit-5.1.9.ebuild,
+ +files/debugedit-5.1.9-DWARF-3.patch,
+ +files/debugedit-5.1.9-cleanup.patch:
+ Instead od pulling in one big update, bump the whole tarball to debugedit
+ taken from rpm-5.1.9. Also include support for build-id, which has been
+ dropped on purpose in the last update, but portage supports this for over
+ a year now.
*debugedit-4.4.6-r2 (21 Oct 2009)
diff --git a/dev-util/debugedit/debugedit-5.1.9.ebuild b/dev-util/debugedit/debugedit-5.1.9.ebuild
new file mode 100644
index 000000000000..ff51d05acd06
--- /dev/null
+++ b/dev-util/debugedit/debugedit-5.1.9.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-util/debugedit/debugedit-5.1.9.ebuild,v 1.1 2009/11/14 09:14:33 swegener Exp $
+
+EAPI="2"
+
+inherit toolchain-funcs eutils
+
+DESCRIPTION="Standalone debugedit taken from rpm"
+
+HOMEPAGE="http://www.rpm5.org/"
+SRC_URI="http://dev.gentoo.org/~swegener/distfiles/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
+IUSE=""
+
+DEPEND="dev-libs/popt
+ dev-libs/elfutils
+ dev-libs/beecrypt"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-{cleanup,DWARF-3}.patch
+}
+
+src_compile() {
+ emake CC="$(tc-getCC)" || die "emake failed"
+}
+
+src_install() {
+ dobin debugedit || die "dobin failed"
+}
diff --git a/dev-util/debugedit/files/debugedit-5.1.9-DWARF-3.patch b/dev-util/debugedit/files/debugedit-5.1.9-DWARF-3.patch
new file mode 100644
index 000000000000..ab7bbb422c09
--- /dev/null
+++ b/dev-util/debugedit/files/debugedit-5.1.9-DWARF-3.patch
@@ -0,0 +1,152 @@
+Index: rpm/tools/debugedit.c
+RCS File: /v/rpm/cvs/rpm/tools/debugedit.c,v
+rcsdiff -q -kk '-r2.21' '-r2.22' -u '/v/rpm/cvs/rpm/tools/debugedit.c,v' 2>/dev/null
+--- debugedit.c 2008/12/25 17:21:43 2.21
++++ debugedit.c 2009/06/15 14:16:21 2.22
+@@ -1,4 +1,4 @@
+-/* Copyright (C) 2001, 2002, 2003, 2005, 2007 Red Hat, Inc.
++/* Copyright (C) 2001, 2002, 2003, 2005, 2007, 2009 Red Hat, Inc.
+ Written by Alexander Larsson <alexl@redhat.com>, 2002
+ Based on code by Jakub Jelinek <jakub@redhat.com>, 2001.
+
+@@ -114,6 +114,7 @@
+ static void (*write_32) (unsigned char *ptr, GElf_Addr val);
+
+ static int ptr_size;
++static int cu_version;
+
+ static inline rpmuint16_t
+ buf_read_ule16 (unsigned char *data)
+@@ -239,16 +240,18 @@
+ #define DEBUG_LINE 2
+ #define DEBUG_ARANGES 3
+ #define DEBUG_PUBNAMES 4
+-#define DEBUG_MACINFO 5
+-#define DEBUG_LOC 6
+-#define DEBUG_STR 7
+-#define DEBUG_FRAME 8
+-#define DEBUG_RANGES 9
++#define DEBUG_PUBTYPES 5
++#define DEBUG_MACINFO 6
++#define DEBUG_LOC 7
++#define DEBUG_STR 8
++#define DEBUG_FRAME 9
++#define DEBUG_RANGES 10
+ { ".debug_info", NULL, NULL, 0, 0, 0 },
+ { ".debug_abbrev", NULL, NULL, 0, 0, 0 },
+ { ".debug_line", NULL, NULL, 0, 0, 0 },
+ { ".debug_aranges", NULL, NULL, 0, 0, 0 },
+ { ".debug_pubnames", NULL, NULL, 0, 0, 0 },
++ { ".debug_pubtypes", NULL, NULL, 0, 0, 0 },
+ { ".debug_macinfo", NULL, NULL, 0, 0, 0 },
+ { ".debug_loc", NULL, NULL, 0, 0, 0 },
+ { ".debug_str", NULL, NULL, 0, 0, 0 },
+@@ -328,7 +331,7 @@
+ }
+ if (*slot != NULL)
+ {
+- error (0, 0, "%s: Duplicate DWARF-2 abbreviation %d", dso->filename,
++ error (0, 0, "%s: Duplicate DWARF abbreviation %d", dso->filename,
+ t->entry);
+ free (t);
+ htab_delete (h);
+@@ -348,7 +351,7 @@
+ form = read_uleb128 (ptr);
+ if (form == 2 || form > DW_FORM_indirect)
+ {
+- error (0, 0, "%s: Unknown DWARF-2 DW_FORM_%d", dso->filename, form);
++ error (0, 0, "%s: Unknown DWARF DW_FORM_%d", dso->filename, form);
+ htab_delete (h);
+ return NULL;
+ }
+@@ -358,7 +361,7 @@
+ }
+ if (read_uleb128 (ptr) != 0)
+ {
+- error (0, 0, "%s: DWARF-2 abbreviation does not end with 2 zeros",
++ error (0, 0, "%s: DWARF abbreviation does not end with 2 zeros",
+ dso->filename);
+ htab_delete (h);
+ return NULL;
+@@ -510,7 +513,7 @@
+ }
+
+ value = read_16 (ptr);
+- if (value != 2)
++ if (value != 2 && value != 3)
+ {
+ error (0, 0, "%s: DWARF version %d unhandled", dso->filename,
+ value);
+@@ -855,7 +858,12 @@
+
+ switch (form)
+ {
+- case DW_FORM_ref_addr: /* ptr_size in DWARF 2, offset in DWARF 3 */
++ case DW_FORM_ref_addr:
++ if (cu_version == 2)
++ ptr += ptr_size;
++ else
++ ptr += 4;
++ break;
+ case DW_FORM_addr:
+ ptr += ptr_size;
+ break;
+@@ -907,7 +915,7 @@
+ assert (len < UINT_MAX);
+ break;
+ default:
+- error (0, 0, "%s: Unknown DWARF-2 DW_FORM_%d", dso->filename,
++ error (0, 0, "%s: Unknown DWARF DW_FORM_%d", dso->filename,
+ form);
+ return NULL;
+ }
+@@ -1204,11 +1212,11 @@
+ return 1;
+ }
+
+- value = read_16 (ptr);
+- if (value != 2)
++ cu_version = read_16 (ptr);
++ if (cu_version != 2 && cu_version != 3)
+ {
+ error (0, 0, "%s: DWARF version %d unhandled", dso->filename,
+- value);
++ cu_version);
+ return 1;
+ }
+
+@@ -1218,7 +1226,7 @@
+ if (debug_sections[DEBUG_ABBREV].data == NULL)
+ error (0, 0, "%s: .debug_abbrev not present", dso->filename);
+ else
+- error (0, 0, "%s: DWARF-2 CU abbrev offset too large",
++ error (0, 0, "%s: DWARF CU abbrev offset too large",
+ dso->filename);
+ return 1;
+ }
+@@ -1228,14 +1236,14 @@
+ ptr_size = read_1 (ptr);
+ if (ptr_size != 4 && ptr_size != 8)
+ {
+- error (0, 0, "%s: Invalid DWARF-2 pointer size %d",
++ error (0, 0, "%s: Invalid DWARF pointer size %d",
+ dso->filename, ptr_size);
+ return 1;
+ }
+ }
+ else if (read_1 (ptr) != ptr_size)
+ {
+- error (0, 0, "%s: DWARF-2 pointer size differs between CUs",
++ error (0, 0, "%s: DWARF pointer size differs between CUs",
+ dso->filename);
+ return 1;
+ }
+@@ -1253,7 +1261,7 @@
+ t = htab_find_with_hash (abbrev, &tag, tag.entry);
+ if (t == NULL)
+ {
+- error (0, 0, "%s: Could not find DWARF-2 abbreviation %d",
++ error (0, 0, "%s: Could not find DWARF abbreviation %d",
+ dso->filename, tag.entry);
+ htab_delete (abbrev);
+ return 1;
diff --git a/dev-util/debugedit/files/debugedit-5.1.9-cleanup.patch b/dev-util/debugedit/files/debugedit-5.1.9-cleanup.patch
new file mode 100644
index 000000000000..f83123f69ffc
--- /dev/null
+++ b/dev-util/debugedit/files/debugedit-5.1.9-cleanup.patch
@@ -0,0 +1,34 @@
+This patch is a hand-edited CVS patch covering only minor important cleanup changes.
+--- debugedit.c
++++ debugedit.c
+@@ -153,7 +153,7 @@
+ {
+ if (data->d_buf
+ && offset >= data->d_off
+- && offset < data->d_off + data->d_size)
++ && offset < data->d_off + (off_t)data->d_size)
+ return (const char *) data->d_buf + (offset - data->d_off);
+ }
+ }
+@@ -468,8 +465,8 @@
+ has_prefix (const char *str,
+ const char *prefix)
+ {
+- int str_len;
+- int prefix_len;
++ size_t str_len;
++ size_t prefix_len;
+
+ str_len = strlen (str);
+ prefix_len = strlen (prefix);
+@@ -747,8 +747,8 @@
+ for (i = 0; i < t->nattr; ++i)
+ {
+ uint_32 form = t->attr[i].form;
+- uint_32 len = 0;
+- int base_len, dest_len;
++ size_t len = 0;
++ size_t base_len, dest_len;
+
+
+ while (1)