[openchrome-devel] xf86-video-openchrome: Branch 'main' - 3 commits - configure.ac src/Makefile.am
Kevin Brace
kevinbrace at kemper.freedesktop.org
Wed Sep 2 20:09:46 UTC 2020
configure.ac | 90 +++++++++++++++++++++++-----------------
src/Makefile.am | 126 ++++++++++++++++++++++++++------------------------------
2 files changed, 111 insertions(+), 105 deletions(-)
New commits:
commit 476bdc466e0964effb4931f0f9dd0e335636e639
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Wed Sep 2 13:08:20 2020 -0700
Version bumped to 0.6.310
This version significantly improves the build script for KMS support.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/configure.ac b/configure.ac
index fdf9cf9..b64db0b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@
# Initialize Autoconf
AC_PREREQ([2.60])
AC_INIT([xf86-video-openchrome],
- [0.6.309],
+ [0.6.310],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg&component=Driver/openchrome],
[xf86-video-openchrome])
commit 0dae4fff61fc1257709a4417aa263265eb3ea5a7
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Wed Sep 2 13:07:11 2020 -0700
Add the ability to disable KMS support
This commit also fixes a build issue when DRI is disabled.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/configure.ac b/configure.ac
index e6d33b7..fdf9cf9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -58,6 +58,11 @@ AC_ARG_ENABLE(dri, AS_HELP_STRING([--disable-dri],
[DRI="$enableval"],
[DRI=auto])
+AC_ARG_ENABLE(kms, AS_HELP_STRING([--disable-kms],
+ [Disable KMS support [[default=enabled]]]),
+ [DRM_MODE="$enableval"],
+ [DRM_MODE=yes])
+
AC_ARG_ENABLE(debug, AS_HELP_STRING([--enable-debug],
[Enable debugging support [[default=no]]]),
[DEBUG="$enableval"],
@@ -143,16 +148,20 @@ if test "$DRI" = yes; then
AC_DEFINE(OPENCHROMEDRI_DEVEL, 1, [Enable developmental DRI driver support])
save_CFLAGS="$CFLAGS"
CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $CFLAGS"
- AC_CHECK_HEADER(xf86drmMode.h,
- [DRM_MODE=yes], [DRM_MODE=no],
- [#include <stdint.h>
- #include <stdlib.h>])
if test "x$DRM_MODE" = xyes; then
- PKG_CHECK_MODULES(LIBUDEV, [libudev],
- [LIBUDEV=yes], [LIBUDEV=no])
- if test "x$LIBUDEV" = xyes; then
- AC_DEFINE(HAVE_LIBUDEV, 1, [libudev support])
+ AC_CHECK_HEADER(xf86drmMode.h,
+ [DRM_KMS=yes], [DRM_KMS=no],
+ [#include <stdint.h>
+ #include <stdlib.h>])
+ if test "x$DRM_KMS" = xyes; then
+ PKG_CHECK_MODULES(LIBUDEV, [libudev],
+ [LIBUDEV=yes], [LIBUDEV=no])
+ if test "x$LIBUDEV" = xyes; then
+ AC_DEFINE(HAVE_LIBUDEV, 1, [libudev support])
+ fi
fi
+ else
+ DRM_KMS=no
fi
CFLAGS="$save_CFLAGS"
@@ -165,9 +174,13 @@ if test "$DRI" = yes; then
XVMC=no ;;
esac
else
+ DRM_KMS=no
XVMC="no"
fi
+AC_MSG_CHECKING([whether to include KMS support])
+AC_MSG_RESULT([$DRM_KMS])
+
if test "x$XVMC" = xyes; then
AC_CHECK_HEADERS(pthread.h sys/ioctl.h sys/time.h time.h,,[XVMC="no"; break],)
PKG_CHECK_MODULES(XVMC, [x11 xext xvmc])
@@ -176,6 +189,8 @@ fi
AC_MSG_CHECKING([whether to build XvMC driver support])
AC_MSG_RESULT([$XVMC])
+AM_CONDITIONAL(XF86DRM_MODE, test "x$DRM_KMS" = xyes)
+
AM_CONDITIONAL(XVMC, test x$XVMC = xyes)
AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test x$XSERVER_LIBPCIACCESS = xyes)
diff --git a/src/Makefile.am b/src/Makefile.am
index 9d47ada..8e8df29 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -26,78 +26,70 @@
SUBDIRS = xvmc
+if DRI
+OPENCHROME_DRI_SRCS = \
+ via_dri.c \
+ via_xvmc.c
+endif
+
+if XF86DRM_MODE
+OPENCHROME_KMS_SRCS = \
+ drmmode_display.c
+endif
+
AM_CFLAGS = @XORG_CFLAGS@ $(CWARNFLAGS) @DRI_CFLAGS@ @LIBUDEV_CFLAGS@
+
openchrome_drv_la_LTLIBRARIES = openchrome_drv.la
openchrome_drv_la_LDFLAGS = -module -avoid-version
openchrome_drv_ladir = @moduledir@/drivers
openchrome_drv_la_SOURCES = \
- compat-api.h \
- via_eng_regs.h \
- via_3d.c \
- via_3d.h \
- via_3d_reg.h \
- via_analog.c \
- via_rop.h \
- via_exa.c \
- via_exa_h2.c \
- via_exa_h6.c \
- via_ums.h \
- via_ch7xxx.c \
- via_ch7xxx.h \
- via_display.c \
- via_dmabuffer.h \
- via_driver.c \
- via_driver.h \
- via_i2c.c \
- via_fp.c \
- via_fp.h \
- via_memcpy.c \
- via_memmgr.h \
- via_memmgr.c \
- via_options.c \
- via_outputs.c \
- via_priv.h \
- via_regs.h \
- via_sii164.c \
- via_sii164.h \
- via_tmds.c \
- via_tv.c \
- via_xv_overlay.c \
- via_xv_overlay.h \
- via_ums.c \
- via_vgahw.c \
- via_vgahw.h \
- via_xv.c \
- via_xv.h \
- via_vt162x.c \
- via_vt162x.h \
- via_vt1632.c \
- via_vt1632.h \
- via_xvpriv.h
+ via_3d.c \
+ via_analog.c \
+ via_ch7xxx.c \
+ via_display.c \
+ via_driver.c \
+ via_exa.c \
+ via_exa_h2.c \
+ via_exa_h6.c \
+ via_fp.c \
+ via_i2c.c \
+ via_memcpy.c \
+ via_memmgr.c \
+ via_options.c \
+ via_outputs.c \
+ via_sii164.c \
+ via_tmds.c \
+ via_tv.c \
+ via_ums.c \
+ via_vgahw.c \
+ via_vt162x.c \
+ via_vt1632.c \
+ via_xv.c \
+ via_xv_overlay.c \
+ $(OPENCHROME_DRI_SRCS) \
+ $(OPENCHROME_KMS_SRCS)
-if DRI
-openchrome_drv_la_SOURCES += \
- drmmode_display.c \
- drmmode_display.h \
- via_dri.c \
- via_dri.h \
- via_drm.h \
- via_drmclient.h \
- via_xvmc.c \
- via_xvmc.h \
- drm_fourcc.h \
- openchrome_drm.h
-else
EXTRA_DIST = \
- drmmode_display.c \
- drmmode_display.h \
- via_dri.c \
- via_dri.h \
- via_drm.h \
- via_drmclient.h \
- via_xvmc.c \
- via_xvmc.h \
- drm_fourcc.h \
- openchrome_drm.h
-endif
+ compat-api.h \
+ drmmode_display.h \
+ version.h \
+ via_3d.h \
+ via_3d_reg.h \
+ via_ch7xxx.h \
+ via_dmabuffer.h \
+ via_driver.h \
+ via_eng_regs.h \
+ via_fp.c \
+ via_memmgr.h \
+ via_priv.h \
+ via_regs.h \
+ via_rop.h \
+ via_sii164.h \
+ via_ums.h \
+ via_vgahw.h \
+ via_vt162x.h \
+ via_vt1632.h \
+ via_xv.h \
+ via_xv_overlay.h \
+ via_xvpriv.h
commit 73c9771bee634c2fb980559616924be739cdce13
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Wed Sep 2 13:06:52 2020 -0700
Indentation and tab to white space conversion for configure.ac
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/configure.ac b/configure.ac
index 238d628..e6d33b7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -42,6 +42,7 @@ XORG_DEFAULT_OPTIONS
# Initialize libtool
AC_DISABLE_STATIC
AC_PROG_LIBTOOL
+
AC_SYS_LARGEFILE
AH_TOP([#include "xorg-server.h"])
@@ -82,22 +83,21 @@ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
# Checks for pkg-config packages
PKG_CHECK_MODULES(XORG, [xorg-server xproto fontsproto glproto $REQUIRED_MODULES])
PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
- HAVE_XEXTPROTO_71="yes"; AC_DEFINE(HAVE_XEXTPROTO_71, 1, [xextproto 7.1 available]),
- HAVE_XEXTPROTO_71="no")
+ HAVE_XEXTPROTO_71="yes"; AC_DEFINE(HAVE_XEXTPROTO_71, 1, [xextproto 7.1 available]),
+ HAVE_XEXTPROTO_71="no")
AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
sdkdir=$(pkg-config --variable=sdkdir xorg-server)
# Checks for libraries.
-
SAVE_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $XORG_CFLAGS"
AC_CHECK_DECL(XSERVER_LIBPCIACCESS,
- [XSERVER_LIBPCIACCESS=yes],[XSERVER_LIBPCIACCESS=no],
+ [XSERVER_LIBPCIACCESS=yes], [XSERVER_LIBPCIACCESS=no],
[#include "xorg-server.h"])
CPPFLAGS="$SAVE_CPPFLAGS"
if test x$XSERVER_LIBPCIACCESS = xyes; then
- PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
+ PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
fi
if test "$DRI" != no; then
@@ -124,54 +124,53 @@ if test "$DRI" != no; then
fi
fi
-
AC_MSG_CHECKING([whether to include DRI support])
if test x$DRI = xauto; then
- if test "$have_dri_h" = yes -a \
- "$have_sarea_h" = yes -a \
- "$have_dristruct_h" = yes; then
- DRI="yes"
- else
- DRI="no"
- fi
+ if test "$have_dri_h" = yes -a \
+ "$have_sarea_h" = yes -a \
+ "$have_dristruct_h" = yes; then
+ DRI="yes"
+ else
+ DRI="no"
+ fi
fi
AC_MSG_RESULT([$DRI])
AM_CONDITIONAL(DRI, test x$DRI = xyes)
if test "$DRI" = yes; then
- PKG_CHECK_MODULES(DRI, [libdrm xf86driproto])
- AC_DEFINE(OPENCHROMEDRI,1,[Enable DRI driver support])
- AC_DEFINE(OPENCHROMEDRI_DEVEL,1,[Enable developmental DRI driver support])
- save_CFLAGS="$CFLAGS"
- CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $CFLAGS"
- AC_CHECK_HEADER(xf86drmMode.h,
- [DRM_MODE=yes], [DRM_MODE=no],
- [#include <stdint.h>
- #include <stdlib.h>])
- if test "x$DRM_MODE" = xyes; then
- PKG_CHECK_MODULES(LIBUDEV, [libudev],
- [LIBUDEV=yes], [LIBUDEV=no])
- if test "x$LIBUDEV" = xyes; then
- AC_DEFINE(HAVE_LIBUDEV, 1, [libudev support])
- fi
+ PKG_CHECK_MODULES(DRI, [libdrm xf86driproto])
+ AC_DEFINE(OPENCHROMEDRI, 1, [Enable DRI driver support])
+ AC_DEFINE(OPENCHROMEDRI_DEVEL, 1, [Enable developmental DRI driver support])
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $CFLAGS"
+ AC_CHECK_HEADER(xf86drmMode.h,
+ [DRM_MODE=yes], [DRM_MODE=no],
+ [#include <stdint.h>
+ #include <stdlib.h>])
+ if test "x$DRM_MODE" = xyes; then
+ PKG_CHECK_MODULES(LIBUDEV, [libudev],
+ [LIBUDEV=yes], [LIBUDEV=no])
+ if test "x$LIBUDEV" = xyes; then
+ AC_DEFINE(HAVE_LIBUDEV, 1, [libudev support])
fi
- CFLAGS="$save_CFLAGS"
-
- case "$host_cpu" in
- i*86)
- XVMC=yes ;;
- amd64*|x86_64*)
- XVMC=yes ;;
- *)
- XVMC=no ;;
- esac
+ fi
+ CFLAGS="$save_CFLAGS"
+
+ case "$host_cpu" in
+ i*86)
+ XVMC=yes ;;
+ amd64*|x86_64*)
+ XVMC=yes ;;
+ *)
+ XVMC=no ;;
+ esac
else
- XVMC="no"
+ XVMC="no"
fi
if test "x$XVMC" = xyes; then
- AC_CHECK_HEADERS(pthread.h sys/ioctl.h sys/time.h time.h,,[XVMC="no"; break],)
- PKG_CHECK_MODULES(XVMC, [x11 xext xvmc])
+ AC_CHECK_HEADERS(pthread.h sys/ioctl.h sys/time.h time.h,,[XVMC="no"; break],)
+ PKG_CHECK_MODULES(XVMC, [x11 xext xvmc])
fi
AC_MSG_CHECKING([whether to build XvMC driver support])
@@ -181,22 +180,22 @@ AM_CONDITIONAL(XVMC, test x$XVMC = xyes)
AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test x$XSERVER_LIBPCIACCESS = xyes)
if test "$XSERVER_LIBPCIACCESS" = yes; then
- AC_DEFINE(XSERVER_LIBPCIACCESS,1,[Enable libpciaccess])
+ AC_DEFINE(XSERVER_LIBPCIACCESS, 1, [Enable libpciaccess])
fi
AM_CONDITIONAL(DEBUG, test x$DEBUG = xyes)
if test "$DEBUG" = yes; then
- AC_DEFINE(HAVE_DEBUG,1,[Enable debug support])
+ AC_DEFINE(HAVE_DEBUG, 1, [Enable debug support])
fi
AM_CONDITIONAL(XV_DEBUG, test x$XV_DEBUG = xyes)
if test "$XV_DEBUG" = yes; then
- AC_DEFINE(XV_DEBUG,1,[Enable XVideo debug support])
+ AC_DEFINE(XV_DEBUG, 1, [Enable XVideo debug support])
fi
AM_CONDITIONAL(TOOLS, test x$TOOLS = xyes)
if test "$TOOLS" = yes; then
- AC_DEFINE(TOOLS,1,[Enable build of registers dumper tool])
+ AC_DEFINE(TOOLS, 1, [Enable build of registers dumper tool])
fi
AC_DEFINE(X_USE_REGION_NULL, 1, [Compatibility define for older Xen])
More information about the openchrome-devel
mailing list