When libudev.h is included from C++ code, wrap the declarations in an
extern "C" { ... } block. This tells the C++ compiler that symbols
are exported with C linkage and no name-mangling.
#include <sys/types.h>
#include <sys/stat.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* udev - library context
*
unsigned long long int start, unsigned long long int end);
struct udev_list_entry *udev_queue_get_queued_list_entry(struct udev_queue *udev_queue);
struct udev_list_entry *udev_queue_get_failed_list_entry(struct udev_queue *udev_queue);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
#endif