[OMPD] Runtime Entry Point functions for OMPD in libomp.so need C linkage as per standard. (#79246)
Adding extern "C" to all the entry point functions to make sure that
these functions are not mangled.
GitOrigin-RevId: edfc21a5759e9f5f5025885da9b0b879204aff22
diff --git a/runtime/src/include/omp-tools.h.var b/runtime/src/include/omp-tools.h.var
index a3ec030..1d1a0f7 100644
--- a/runtime/src/include/omp-tools.h.var
+++ b/runtime/src/include/omp-tools.h.var
@@ -211,6 +211,10 @@
* definitions generated from spec
*****************************************************************************/
+#if defined(__cplusplus)
+extern "C" {
+#endif
+
typedef enum ompt_callbacks_t {
ompt_callback_thread_begin = 1,
ompt_callback_thread_end = 2,
@@ -1414,4 +1418,8 @@
#define ompd_segment_none 0
+#if defined(__cplusplus)
+} // extern "C"
+#endif
+
#endif /* __OMPT__ */