summaryrefslogtreecommitdiff
path: root/usr/src/lib/libctf/common/libctf.h
diff options
context:
space:
mode:
authorJohn Levon <john.levon@joyent.com>2019-03-08 17:40:00 +0000
committerJohn Levon <john.levon@joyent.com>2019-05-03 02:15:58 -0700
commit3eca610387779e26c8c63e26d2ba418b0cd1bf5a (patch)
tree11359001bf90df8b1a0d2fefd2185c3405f52daa /usr/src/lib/libctf/common/libctf.h
parent5bb525f494c825f138113d51f2ba7acf185093f3 (diff)
downloadillumos-joyent-3eca610387779e26c8c63e26d2ba418b0cd1bf5a.tar.gz
10816 ctf_dwarf_convert_type() relies on un-initialized id
10817 ctfconvert -i option is mis-handled 10818 Improve ctfconvert error messages 10819 ctfconvert should handle empty dies 10820 ctfconvert -i never converts 10821 bad free in ctf_dwarf_init_die 10815 shouldn't build gcore.c as part of kmdb Reviewed by: Robert Mustacchi <rm@joyent.com> Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com> Approved by: Gordon Ross <gwr@nexenta.com>
Diffstat (limited to 'usr/src/lib/libctf/common/libctf.h')
-rw-r--r--usr/src/lib/libctf/common/libctf.h18
1 files changed, 16 insertions, 2 deletions
diff --git a/usr/src/lib/libctf/common/libctf.h b/usr/src/lib/libctf/common/libctf.h
index 0951ae0606..57b8376eed 100644
--- a/usr/src/lib/libctf/common/libctf.h
+++ b/usr/src/lib/libctf/common/libctf.h
@@ -24,7 +24,7 @@
* Use is subject to license terms.
*/
/*
- * Copyright (c) 2015, Joyent, Inc.
+ * Copyright (c) 2019, Joyent, Inc.
*/
/*
@@ -44,6 +44,7 @@
#define _LIBCTF_H
#include <sys/ctf_api.h>
+#include <libelf.h>
#ifdef __cplusplus
extern "C" {
@@ -74,10 +75,23 @@ extern int ctf_diff_functions(ctf_diff_t *, ctf_diff_func_f, void *);
extern int ctf_diff_objects(ctf_diff_t *, ctf_diff_obj_f, void *);
extern void ctf_diff_fini(ctf_diff_t *);
-#define CTF_CONVERT_F_IGNNONC 0x01
+/*
+ * Normally, we return a failure if we find a C-derived compilation unit that
+ * lacks DWARF or CTF (as required). This flag over-rides this check.
+ */
+#define CTF_ALLOW_MISSING_DEBUG 0x01
+
extern ctf_file_t *ctf_fdconvert(int, const char *, uint_t, uint_t, int *,
char *, size_t);
+typedef enum ctf_hsc_ret {
+ CHR_ERROR = -1,
+ CHR_NO_C_SOURCE = 0,
+ CHR_HAS_C_SOURCE = 1
+} ctf_hsc_ret_t;
+
+extern ctf_hsc_ret_t ctf_has_c_source(Elf *, char *, size_t);
+
typedef struct ctf_merge_handle ctf_merge_t;
extern ctf_merge_t *ctf_merge_init(int, int *);
extern int ctf_merge_add(ctf_merge_t *, ctf_file_t *);