summaryrefslogtreecommitdiff
path: root/xf86drm.h
diff options
context:
space:
mode:
authorTapani Pälli <tapani.palli@intel.com>2011-09-23 14:17:42 +0300
committerChris Wilson <chris@chris-wilson.co.uk>2011-09-23 12:58:56 +0100
commitcfee5218b17a2741e5519ed44091171e01f0dbb2 (patch)
tree13c01740f919b2ef99ecac9bdfc3c4da8e37cfe9 /xf86drm.h
parent194aa1bee632c6dce19238664eb8373e3483de55 (diff)
downloaddrm-cfee5218b17a2741e5519ed44091171e01f0dbb2.tar.gz
xf86drm.h : wrap C code for C++ compilation/linking
To enable usage of xf86drm.h from C++ programs/frameworks. Signed-off-by: Tapani Pälli <tapani.palli@intel.com> [ickle: also wrap xf86drmMode.h] Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'xf86drm.h')
-rw-r--r--xf86drm.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/xf86drm.h b/xf86drm.h
index 20f4c783..76eb94e2 100644
--- a/xf86drm.h
+++ b/xf86drm.h
@@ -39,6 +39,10 @@
#include <stdint.h>
#include <drm.h>
+#if defined(__cplusplus) || defined(c_plusplus)
+extern "C" {
+#endif
+
#ifndef DRM_MAX_MINOR
#define DRM_MAX_MINOR 16
#endif
@@ -723,4 +727,8 @@ extern int drmHandleEvent(int fd, drmEventContextPtr evctx);
extern char *drmGetDeviceNameFromFd(int fd);
+#if defined(__cplusplus) || defined(c_plusplus)
+}
+#endif
+
#endif