X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=include%2Fctf-api.h;h=efc49896c76e8132e23649d283cc3e70ca60028f;hb=1a20473059c7a088b9f3c4188c09976eebbc3ab4;hp=4ac5fea8bc697420674d6cffca6d7d92a5d8fcf7;hpb=49ea9b450bb1ca97f6e40c420c8cde5878e11048;p=deliverable%2Fbinutils-gdb.git diff --git a/include/ctf-api.h b/include/ctf-api.h index 4ac5fea8bc..efc49896c7 100644 --- a/include/ctf-api.h +++ b/include/ctf-api.h @@ -1,5 +1,5 @@ /* Public API to libctf. - Copyright (C) 2019 Free Software Foundation, Inc. + Copyright (C) 2019-2020 Free Software Foundation, Inc. This file is part of libctf. @@ -24,7 +24,6 @@ #ifndef _CTF_API_H #define _CTF_API_H -#include #include #include #include @@ -204,7 +203,8 @@ enum ECTF_DUMPSECTUNKNOWN, /* Unknown section number in dump. */ ECTF_DUMPSECTCHANGED, /* Section changed in middle of dump. */ ECTF_NOTYET, /* Feature not yet implemented. */ - ECTF_INTERNAL /* Internal error in link. */ + ECTF_INTERNAL, /* Internal error in link. */ + ECTF_NONREPRESENTABLE /* Type not representable in CTF. */ }; /* The CTF data model is inferred to be the caller's data model or the data @@ -286,10 +286,10 @@ extern int ctf_arc_write_fd (int, ctf_file_t **, size_t, const char **, size_t); extern const char *ctf_cuname (ctf_file_t *); -extern void ctf_cuname_set (ctf_file_t *, const char *); +extern int ctf_cuname_set (ctf_file_t *, const char *); extern ctf_file_t *ctf_parent_file (ctf_file_t *); extern const char *ctf_parent_name (ctf_file_t *); -extern void ctf_parent_name_set (ctf_file_t *, const char *); +extern int ctf_parent_name_set (ctf_file_t *, const char *); extern int ctf_type_isparent (ctf_file_t *, ctf_id_t); extern int ctf_type_ischild (ctf_file_t *, ctf_id_t); @@ -409,6 +409,8 @@ extern int ctf_gzwrite (ctf_file_t *fp, gzFile fd); extern int ctf_compress_write (ctf_file_t * fp, int fd); extern unsigned char *ctf_write_mem (ctf_file_t *, size_t *, size_t threshold); +/* The ctf_link interfaces are not stable yet. No guarantees! */ + extern int ctf_link_add_ctf (ctf_file_t *, ctf_archive_t *, const char *); extern int ctf_link (ctf_file_t *, int share_mode); typedef const char *ctf_link_strtab_string_f (uint32_t *offset, void *arg);