dri_inteface: add define for checking presence of drm.h

__NOT_HAVE_DRM_H is a like a feature, defined by default on specific platforms
and allows to be defined externally as well.

__NOT_HAVE_DRM_H should only be used by xserver and mesa swrast_dri drivers
This commit is contained in:
George Sapountzis
2010-03-19 02:38:09 +02:00
parent 2b5a6e083c
commit 0b932284f2
2 changed files with 9 additions and 1 deletions

View File

@@ -41,7 +41,13 @@
#define DRI_INTERFACE_H
/* For archs with no drm.h */
#if !defined(__APPLE__) && !defined(__CYGWIN__) && !defined(__GNU__)
#if defined(__APPLE__) || defined(__CYGWIN__) || defined(__GNU__)
#ifndef __NOT_HAVE_DRM_H
#define __NOT_HAVE_DRM_H
#endif
#endif
#ifndef __NOT_HAVE_DRM_H
#include <drm.h>
#else
typedef unsigned int drm_context_t;