opensm/include/osm_prefix_route.h: Support C++ inclusion
Also, make define name consistent with file name
Signed-off-by: Hal Rosenstock <[EMAIL PROTECTED]>
diff --git a/opensm/include/opensm/osm_prefix_route.h
b/opensm/include/opensm/osm_prefix_route.h
index 10b9aa4..aa3ad62 100644
--- a/opensm/include/opensm/osm_prefix_route.h
+++ b/opensm/include/opensm/osm_prefix_route.h
@@ -33,12 +33,22 @@
*
*/
-#ifndef _OSM_PREFIX_ROUTES_H_
-#define _OSM_PREFIX_ROUTES_H_
+#ifndef _OSM_PREFIX_ROUTE_H_
+#define _OSM_PREFIX_ROUTE_H_
#include <complib/cl_types.h>
#include <complib/cl_qlist.h>
+#ifdef __cplusplus
+# define BEGIN_C_DECLS extern "C" {
+# define END_C_DECLS }
+#else /* !__cplusplus */
+# define BEGIN_C_DECLS
+# define END_C_DECLS
+#endif /* __cplusplus */
+
+BEGIN_C_DECLS
+
typedef struct {
cl_list_item_t list_item; /* must be first */
uint64_t prefix; /* network order, zero means "any" */
@@ -49,4 +59,5 @@ typedef struct {
#error ROUTER_EXP is deprecated, specify prefix routes at runtime instead (see
opensm man page for details)
#endif
-#endif /* _OSM_PREFIX_ROUTES_H_ */
+END_C_DECLS
+#endif /* _OSM_PREFIX_ROUTE_H_ */
_______________________________________________
general mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general
To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general