AM_CONDITIONAL(HAVE_LIBKMS, [test "x$LIBKMS" = xyes])
AM_CONDITIONAL(HAVE_VMWGFX, [test "x$VMWGFX" = xyes])
+if test "x$VMWGFX" = xyes; then
+ AC_DEFINE(HAVE_VMWGFX, 1, [Have vmwgfx kernel headers])
+fi
AM_CONDITIONAL(HAVE_NOUVEAU, [test "x$NOUVEAU" = xyes])
libkms_la_LIBADD =
libkms_la_SOURCES = \
- api.c \
- vmwgfx.c
+ api.c
+
+if HAVE_VMWGFX
+libkms_la_SOURCES += vmwgfx.c
+endif
libkmsincludedir = ${includedir}/libkms
libkmsinclude_HEADERS = libkms.h
**************************************************************************/
+#include "config.h"
#include <errno.h>
#include <stdlib.h>
#include <string.h>
int kms_create(int fd, struct kms_driver **out)
{
+#ifdef HAVE_VMWGFX
return vmwgfx_create(fd, out);
+#else
+ return -ENOSYS;
+#endif
}
int kms_get_prop(struct kms_driver *kms, unsigned key, unsigned *out)