Use extern C guards in all headers
The project uses a mix of C and C++ requiring
extern "C" guards from C++ code both within the
project & from C++ apps that use libcper. That
won't be required with this change.
Change-Id: I835dd05166732ca213c72eae2904815a8769599b
Signed-off-by: Karthik Rajagopalan <krajagopalan@nvidia.com>
diff --git a/cper-parse.h b/cper-parse.h
index 752036e..e50d0cc 100644
--- a/cper-parse.h
+++ b/cper-parse.h
@@ -1,5 +1,10 @@
#ifndef CPER_PARSE_H
#define CPER_PARSE_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include <json.h>
#define CPER_HEADER_VALID_BITFIELD_NAMES \
@@ -36,4 +41,8 @@
void ir_to_cper(json_object *ir, FILE *out);
void ir_single_section_to_cper(json_object *ir, FILE *out);
+#ifdef __cplusplus
+}
+#endif
+
#endif