aboutsummaryrefslogtreecommitdiff
path: root/libelftc
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2015-03-31 20:01:37 +0000
committerEd Maste <emaste@FreeBSD.org>2015-03-31 20:01:37 +0000
commit84d41a2986852c0d7d820f95b41c1db1cc818027 (patch)
tree58f47e5186d1b0f72f6784d004bab62d148eede8 /libelftc
parentd356830d3d227b40603d19222ab35eb8f0f5c034 (diff)
Notes
Diffstat (limited to 'libelftc')
-rw-r--r--libelftc/_libelftc.h10
-rw-r--r--libelftc/elftc_bfdtarget.c4
-rw-r--r--libelftc/elftc_demangle.c4
-rw-r--r--libelftc/libelftc.h10
-rw-r--r--libelftc/libelftc_bfdtarget.c4
5 files changed, 17 insertions, 15 deletions
diff --git a/libelftc/_libelftc.h b/libelftc/_libelftc.h
index c300f9105aee..ba0b10112a57 100644
--- a/libelftc/_libelftc.h
+++ b/libelftc/_libelftc.h
@@ -24,7 +24,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: _libelftc.h 2856 2013-01-04 16:00:26Z jkoshy $
+ * $Id: _libelftc.h 3174 2015-03-27 17:13:41Z emaste $
*/
#ifndef __LIBELFTC_H_
@@ -64,7 +64,9 @@ struct vector_str {
#define VECTOR_DEF_CAPACITY 8
-__BEGIN_DECLS
+#ifdef __cplusplus
+extern "C" {
+#endif
char *cpp_demangle_ARM(const char *_org);
char *cpp_demangle_gnu2(const char *_org);
char *cpp_demangle_gnu3(const char *_org);
@@ -84,6 +86,8 @@ bool vector_str_push_vector_head(struct vector_str *_dst,
struct vector_str *_org);
char *vector_str_substr(const struct vector_str *_vs, size_t _begin,
size_t _end, size_t *_rlen);
-__END_DECLS
+#ifdef __cplusplus
+}
+#endif
#endif /* __LIBELFTC_H */
diff --git a/libelftc/elftc_bfdtarget.c b/libelftc/elftc_bfdtarget.c
index 351e5e467e67..a5ae1a671893 100644
--- a/libelftc/elftc_bfdtarget.c
+++ b/libelftc/elftc_bfdtarget.c
@@ -24,15 +24,13 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
#include <sys/param.h>
#include <string.h>
#include <libelftc.h>
#include "_libelftc.h"
-ELFTC_VCSID("$Id: elftc_bfdtarget.c 2251 2011-11-30 16:50:06Z jkoshy $");
+ELFTC_VCSID("$Id: elftc_bfdtarget.c 3174 2015-03-27 17:13:41Z emaste $");
Elftc_Bfd_Target *
elftc_bfd_find_target(const char *tgt_name)
diff --git a/libelftc/elftc_demangle.c b/libelftc/elftc_demangle.c
index 9639d630c6e8..ff3095504286 100644
--- a/libelftc/elftc_demangle.c
+++ b/libelftc/elftc_demangle.c
@@ -24,8 +24,6 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
#include <sys/param.h>
#include <assert.h>
#include <errno.h>
@@ -35,7 +33,7 @@
#include "_libelftc.h"
-ELFTC_VCSID("$Id: elftc_demangle.c 3030 2014-05-01 06:30:48Z kaiwang27 $");
+ELFTC_VCSID("$Id: elftc_demangle.c 3174 2015-03-27 17:13:41Z emaste $");
static int
is_mangled(const char *s, int style)
diff --git a/libelftc/libelftc.h b/libelftc/libelftc.h
index 85e4feb3a710..062db318c4d2 100644
--- a/libelftc/libelftc.h
+++ b/libelftc/libelftc.h
@@ -24,7 +24,7 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* $FreeBSD: users/kaiwang27/elftc/libelftc.h 392 2009-05-31 19:17:46Z kaiwang27 $
- * $Id: libelftc.h 3031 2014-05-01 17:45:41Z jkoshy $
+ * $Id: libelftc.h 3174 2015-03-27 17:13:41Z emaste $
*/
#ifndef _LIBELFTC_H_
@@ -62,7 +62,9 @@ typedef enum {
/* Demangling behaviour control. */
#define ELFTC_DEM_NOPARAM 0x00010000U
-__BEGIN_DECLS
+#ifdef __cplusplus
+extern "C" {
+#endif
Elftc_Bfd_Target *elftc_bfd_find_target(const char *_tgt_name);
Elftc_Bfd_Target_Flavor elftc_bfd_target_flavor(Elftc_Bfd_Target *_tgt);
unsigned int elftc_bfd_target_byteorder(Elftc_Bfd_Target *_tgt);
@@ -87,6 +89,8 @@ int elftc_string_table_remove(Elftc_String_Table *_table,
const char *elftc_string_table_to_string(Elftc_String_Table *_table,
size_t offset);
const char *elftc_version(void);
-__END_DECLS
+#ifdef __cplusplus
+}
+#endif
#endif /* _LIBELFTC_H_ */
diff --git a/libelftc/libelftc_bfdtarget.c b/libelftc/libelftc_bfdtarget.c
index 31c89b74f14a..00ba2254fc16 100644
--- a/libelftc/libelftc_bfdtarget.c
+++ b/libelftc/libelftc_bfdtarget.c
@@ -24,15 +24,13 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
#include <sys/param.h>
#include <libelf.h>
#include <libelftc.h>
#include "_libelftc.h"
-ELFTC_VCSID("$Id: libelftc_bfdtarget.c 2251 2011-11-30 16:50:06Z jkoshy $");
+ELFTC_VCSID("$Id: libelftc_bfdtarget.c 3174 2015-03-27 17:13:41Z emaste $");
struct _Elftc_Bfd_Target _libelftc_targets[] = {