diff options
author | Kai Wang <kaiw@FreeBSD.org> | 2014-01-22 13:43:54 +0000 |
---|---|---|
committer | Kai Wang <kaiw@FreeBSD.org> | 2014-01-22 13:43:54 +0000 |
commit | 529a53abe2287eae08a3af62749273df775254e9 (patch) | |
tree | aee93f75b93285b0f21cb727e0c10598a013449e /cddl/contrib/opensolaris/tools | |
parent | 7a1e293086777baa7760ba4c8afae2c8e7190f07 (diff) | |
download | src-529a53abe2287eae08a3af62749273df775254e9.tar.gz src-529a53abe2287eae08a3af62749273df775254e9.zip |
Let ctfconvert accept DWARF version 3 and 4.
Notes
Notes:
svn path=/projects/elftoolchain/; revision=261025
Diffstat (limited to 'cddl/contrib/opensolaris/tools')
-rw-r--r-- | cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c b/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c index 15060f30e5cf..f929cde69b27 100644 --- a/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c +++ b/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c @@ -96,8 +96,10 @@ #include "list.h" #include "traverse.h" -/* The version of DWARF which we support. */ +/* The versions of DWARF which we support. */ #define DWARF_VERSION 2 +#define DWARF_VERSION3 3 +#define DWARF_VERSION4 4 /* * We need to define a couple of our own intrinsics, to smooth out some of the @@ -1981,9 +1983,10 @@ dw_read(tdata_t *td, Elf *elf, char *filename __unused) terminate("file contains too many types\n"); debug(1, "DWARF version: %d\n", vers); - if (vers != DWARF_VERSION) { + if (vers != DWARF_VERSION && vers != DWARF_VERSION3 && + vers != DWARF_VERSION4) { terminate("file contains incompatible version %d DWARF code " - "(version 2 required)\n", vers); + "(version 2, 3, or 4 required)\n", vers); } if (die_string(&dw, cu, DW_AT_producer, &prod, 0)) { |