summaryrefslogtreecommitdiff
path: root/libdwarf
diff options
context:
space:
mode:
authorTheo Schlossnagle <jesus@omniti.com>2011-12-13 19:24:59 +0000
committerTheo Schlossnagle <jesus@omniti.com>2011-12-13 19:24:59 +0000
commitb72a3681aedba711dd62bc758bd876b369040828 (patch)
treef6ec08f2711c564d23296bad6223cf462fda4799 /libdwarf
parentaf70a23805917ccfb5ba212bad28e4554343249a (diff)
downloadctf-b72a3681aedba711dd62bc758bd876b369040828.tar.gz
Make this compile on Solaris again... oh, the irony
Diffstat (limited to 'libdwarf')
-rw-r--r--libdwarf/dwarf_init.c2
-rw-r--r--libdwarf/libdwarf.h8
-rw-r--r--libdwarf/queue.h2
3 files changed, 9 insertions, 3 deletions
diff --git a/libdwarf/dwarf_init.c b/libdwarf/dwarf_init.c
index 9128a76..8fd5761 100644
--- a/libdwarf/dwarf_init.c
+++ b/libdwarf/dwarf_init.c
@@ -417,7 +417,7 @@ dwarf_init_abbrev(Dwarf_Debug dbg, Dwarf_CU cu, Dwarf_Error *error)
uint64_t form;
uint64_t offset;
uint64_t tag;
- u_int8_t children;
+ uint8_t children;
d = dbg->dbg_s[DWARF_debug_abbrev].s_data;
diff --git a/libdwarf/libdwarf.h b/libdwarf/libdwarf.h
index 9918a50..c3ac0fb 100644
--- a/libdwarf/libdwarf.h
+++ b/libdwarf/libdwarf.h
@@ -111,7 +111,9 @@ typedef struct _Dwarf_Error {
#define DW_DLC_READ 0 /* read only access */
/* Function prototype definitions. */
-__BEGIN_DECLS
+#ifdef __cplusplus
+extern "C" {
+#endif
Dwarf_Abbrev dwarf_abbrev_find(Dwarf_CU, uint64_t);
Dwarf_AttrValue dwarf_attrval_find(Dwarf_Die, Dwarf_Half);
Dwarf_Die dwarf_die_find(Dwarf_Die, Dwarf_Unsigned);
@@ -157,6 +159,8 @@ void dwarf_dump_strtab(Dwarf_Debug);
void dwarf_dump_symtab(Dwarf_Debug);
void dwarf_dump_raw(Dwarf_Debug);
void dwarf_dump_tree(Dwarf_Debug);
-__END_DECLS
+#ifdef __cplusplus
+}
+#endif
#endif /* !_LIBDWARF_H_ */
diff --git a/libdwarf/queue.h b/libdwarf/queue.h
index 1fdfea3..0c42e05 100644
--- a/libdwarf/queue.h
+++ b/libdwarf/queue.h
@@ -33,7 +33,9 @@
#ifndef _SYS_QUEUE_H_
#define _SYS_QUEUE_H_
+#ifdef HAVE_SYS_CDEFS_H
#include <sys/cdefs.h>
+#endif
/*
* This file defines four types of data structures: singly-linked lists,