sna: Guard use of DRM_MODE_OBJECT type ids
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 14 Feb 2014 15:11:21 +0000 (15:11 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 14 Feb 2014 15:12:27 +0000 (15:12 +0000)
commit699bde3991624c25d3b731caf7129ed87710b3b3
treee2ac68676e4eaa8684fe66d5f056b26fc49cd3f6
parent37dbd669415ac82a79b3699da0450aaf68cb1c4c
sna: Guard use of DRM_MODE_OBJECT type ids

These are not currently exported on OpenBSD and cause the build to fail.
Hide their use behind an ifdef guard for the time being.

"I noticed the following when trying to compile xf86-video-intel git on OpenBSD:

/usr/users/jsg/src/xf86-video-intel/src/sna/sna_display.c:2106: error: 'DRM_MODE_OBJECT_CRTC' undeclared (first use in this function)
/usr/users/jsg/src/xf86-video-intel/src/sna/sna_display.c:2106: error: (Each undeclared identifier is reported only once
/usr/users/jsg/src/xf86-video-intel/src/sna/sna_display.c:2106: error: for each function it appears in.)
/usr/users/jsg/src/xf86-video-intel/src/sna/sna_display.c:2107: error: 'DRM_MODE_OBJECT_PLANE' undeclared (first use in this function)"

Reported-by: Jonathan Gray
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
src/sna/sna_display.c