xf86-video-intel: 5 commits - configure.ac src/bios_reader/Makefile.am src/i810_accel.c src/i810_driver.c src/i810.h src/i830.h src/Makefile.am src/reg_dumper/Makefile.am src/xvmc/Makefile.am uxa/Makefile.am
Remi Cardona
remi at kemper.freedesktop.org
Thu Nov 5 08:01:30 PST 2009
configure.ac | 71 ++++++--------------------------------------
src/Makefile.am | 4 --
src/bios_reader/Makefile.am | 2 -
src/i810.h | 8 ++--
src/i810_accel.c | 4 +-
src/i810_driver.c | 36 +++++++++++-----------
src/i830.h | 4 --
src/reg_dumper/Makefile.am | 2 -
src/xvmc/Makefile.am | 2 -
uxa/Makefile.am | 2 -
10 files changed, 39 insertions(+), 96 deletions(-)
New commits:
commit cbcfb711747e3637f20145aed00ac3d6256d0d1d
Author: Rémi Cardona <remi at gentoo.org>
Date: Wed Oct 28 13:12:46 2009 +0100
configure: drop some more cruft
DEBUGFLAGS wasn't used anywhere and the configure switch is useless.
"CFLAGS=-g ./configure" does the same thing and actually works.
PKG_CHECK_MODULES already calls AC_SUBST, no need to do it twice.
Signed-off-by: Rémi Cardona <remi at gentoo.org>
Acked-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/configure.ac b/configure.ac
index 6da3ee1..0a69b67 100644
--- a/configure.ac
+++ b/configure.ac
@@ -65,14 +65,6 @@ AC_ARG_ENABLE(video-debug, AC_HELP_STRING([--enable-video-debug],
[VIDEO_DEBUG="$enableval"],
[VIDEO_DEBUG=no])
-AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug],
- [Compile with debug support [[default=yes]]]))
-if test "x$enableval" == "xyes" ; then
- DEBUGFLAGS="-g"
-else
- DEBUGFLAGS=""
-fi
-
AC_ARG_ENABLE(xvmc, AC_HELP_STRING([--disable-xvmc],
[Disable XvMC support [[default=yes]]]),
[XVMC="$enableval"],
@@ -126,7 +118,6 @@ AC_MSG_RESULT([$XVMC])
AM_CONDITIONAL(XVMC, test x$XVMC = xyes)
if test "$XVMC" = yes; then
AC_DEFINE(ENABLE_XVMC,1,[Enable XvMC support])
- AC_SUBST([XVMCLIB_CFLAGS])
fi
AM_CONDITIONAL(KMS_ONLY, test x$KMS_ONLY = xyes)
@@ -134,11 +125,9 @@ if test "$KMS_ONLY" = yes; then
AC_DEFINE(KMS_ONLY,1,[Assume KMS support])
fi
-AC_SUBST([XORG_CFLAGS])
-AC_SUBST([moduledir])
-
DRIVER_NAME=intel
AC_SUBST([DRIVER_NAME])
+AC_SUBST([moduledir])
m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.3 or later before running autoconf/autogen])])
XORG_MACROS_VERSION(1.3)
commit 3c0a43b24cc7540cc139beca0ec2e4c202ff5593
Author: Rémi Cardona <remi at gentoo.org>
Date: Wed Oct 28 13:01:32 2009 +0100
configure: use CWARNFLAGS from xorg-macros.m4
Signed-off-by: Rémi Cardona <remi at gentoo.org>
Acked-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/configure.ac b/configure.ac
index 4b97abb..6da3ee1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -111,16 +111,6 @@ AM_CONDITIONAL(DRI, test x$DRI = xyes)
AC_MSG_CHECKING([whether to include DRI support])
AC_MSG_RESULT([$DRI])
-dnl Use lots of warning flags with GCC
-
-WARN_CFLAGS=""
-
-if test "x$GCC" = "xyes"; then
- WARN_CFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes \
- -Wmissing-prototypes -Wmissing-declarations \
- -Wnested-externs -fno-strict-aliasing"
-fi
-
AM_CONDITIONAL(VIDEO_DEBUG, test x$VIDEO_DEBUG = xyes)
if test "$VIDEO_DEBUG" = yes; then
AC_DEFINE(VIDEO_DEBUG,1,[Enable debug support])
@@ -145,7 +135,6 @@ if test "$KMS_ONLY" = yes; then
fi
AC_SUBST([XORG_CFLAGS])
-AC_SUBST([WARN_CFLAGS])
AC_SUBST([moduledir])
DRIVER_NAME=intel
diff --git a/src/Makefile.am b/src/Makefile.am
index 5ffb522..d8e02ff 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -26,7 +26,7 @@ SUBDIRS = xvmc bios_reader reg_dumper render_program
# _ladir passes a dummy rpath to libtool so the thing will actually link
# TODO: -nostdlib/-Bstatic/-lgcc platform magic, not installing the .a, etc.
-AM_CFLAGS = @WARN_CFLAGS@ @XORG_CFLAGS@ @DRM_CFLAGS@ \
+AM_CFLAGS = @CWARNFLAGS@ @XORG_CFLAGS@ @DRM_CFLAGS@ \
@PCIACCESS_CFLAGS@ -I$(top_srcdir)/uxa -I$(top_srcdir)/src/render_program
intel_drv_la_LTLIBRARIES = intel_drv.la
diff --git a/src/bios_reader/Makefile.am b/src/bios_reader/Makefile.am
index cff9e1a..f2f9dc0 100644
--- a/src/bios_reader/Makefile.am
+++ b/src/bios_reader/Makefile.am
@@ -1,4 +1,4 @@
-AM_CFLAGS = @WARN_CFLAGS@ @XORG_CFLAGS@ @PCIACCESS_CFLAGS@ \
+AM_CFLAGS = @CWARNFLAGS@ @XORG_CFLAGS@ @PCIACCESS_CFLAGS@ \
-DREG_DUMPER
noinst_PROGRAMS = bios_reader $(BIOS_DUMPER) $(SWF_DUMPER)
diff --git a/src/reg_dumper/Makefile.am b/src/reg_dumper/Makefile.am
index e6adce4..8f00abe 100644
--- a/src/reg_dumper/Makefile.am
+++ b/src/reg_dumper/Makefile.am
@@ -36,6 +36,6 @@ intel_statuspage_LDADD = $(PCIACCESS_LIBS)
intel_lid_LDADD = $(PCIACCESS_LIBS)
intel_audio_LDADD = $(PCIACCESS_LIBS)
-AM_CFLAGS = $(PCIACCESS_CFLAGS) $(WARN_CFLAGS) \
+AM_CFLAGS = $(PCIACCESS_CFLAGS) $(CWARNFLAGS) \
-I$(srcdir)/.. -DREG_DUMPER
diff --git a/src/xvmc/Makefile.am b/src/xvmc/Makefile.am
index 5921244..be8824b 100644
--- a/src/xvmc/Makefile.am
+++ b/src/xvmc/Makefile.am
@@ -7,7 +7,7 @@ SUBDIRS = shader
libI810XvMC_la_SOURCES = I810XvMC.c \
I810XvMC.h
-libI810XvMC_la_CFLAGS = @WARN_CFLAGS@ @XORG_CFLAGS@ @DRM_CFLAGS@ @DRI_CFLAGS@ \
+libI810XvMC_la_CFLAGS = @CWARNFLAGS@ @XORG_CFLAGS@ @DRM_CFLAGS@ @DRI_CFLAGS@ \
-I$(top_srcdir)/src -DTRUE=1 -DFALSE=0
libI810XvMC_la_LDFLAGS = -version-number 1:0:0
libI810XvMC_la_LIBADD = @DRI_LIBS@ @DRM_LIBS@ @XVMCLIB_LIBS@
diff --git a/uxa/Makefile.am b/uxa/Makefile.am
index 641b414..0dfad48 100644
--- a/uxa/Makefile.am
+++ b/uxa/Makefile.am
@@ -7,7 +7,7 @@ SOLARIS_ASM_CFLAGS=""
INCLUDES = \
$(XORG_INCS)
-AM_CFLAGS = $(WARN_CFLAGS) $(XORG_CFLAGS) $(DIX_CFLAGS)
+AM_CFLAGS = $(CWARNFLAGS) $(XORG_CFLAGS) $(DIX_CFLAGS)
libuxa_la_SOURCES = \
uxa.c \
commit a851139c2141f6da370186148f2836e18b2acf83
Author: Rémi Cardona <remi at gentoo.org>
Date: Wed Oct 28 12:37:38 2009 +0100
configure: make --disable-dri work even if the server supports DRI
XF86DRI is defined by the SDK so not defining it here just breaks the
build. Define HAVE_DRI instead to avoid collisions.
Note: DRI2 is still enabled/disabled entirely by SDK defines.
Signed-off-by: Rémi Cardona <remi at gentoo.org>
Acked-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/configure.ac b/configure.ac
index 9978958..4b97abb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -87,7 +87,7 @@ AC_ARG_ENABLE(kms-only, AC_HELP_STRING([--enable-kms-only],
XORG_DRIVER_CHECK_EXT(XINERAMA, xineramaproto)
XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
-XORG_DRIVER_CHECK_EXT(XF86DRI, xextproto x11)
+XORG_DRIVER_CHECK_EXT(XF86DRI, xextproto x11 xf86driproto glproto)
XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
# Checks for pkg-config packages
@@ -101,30 +101,15 @@ AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
sdkdir=$(pkg-config --variable=sdkdir xorg-server)
-save_CFLAGS="$CFLAGS"
-CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $DRM_CFLAGS"
-CPPFLAGS="$XORG_CFLAGS $DRI_CFLAGS $DRM_CFLAGS"
-AC_MSG_CHECKING([whether to include DRI support])
if test x$DRI != xno; then
- AC_CHECK_FILE([${sdkdir}/dri.h],
- [have_dri_h="yes"], [have_dri_h="no"])
- AC_CHECK_FILE([${sdkdir}/sarea.h],
- [have_sarea_h="yes"], [have_sarea_h="no"])
- AC_CHECK_FILE([${sdkdir}/dristruct.h],
- [have_dristruct_h="yes"], [have_dristruct_h="no"])
+ AC_CHECK_FILES([${sdkdir}/dri.h ${sdkdir}/sarea.h ${sdkdir}/dristruct.h],
+ [DRI="yes"
+ AC_DEFINE(HAVE_DRI,1,[Enable DRI driver support])],
+ [DRI="no"])
fi
+AM_CONDITIONAL(DRI, test x$DRI = xyes)
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
-fi
AC_MSG_RESULT([$DRI])
-CFLAGS="$save_CFLAGS $DEBUGFLAGS"
dnl Use lots of warning flags with GCC
@@ -136,13 +121,6 @@ if test "x$GCC" = "xyes"; then
-Wnested-externs -fno-strict-aliasing"
fi
-AM_CONDITIONAL(DRI, test x$DRI = xyes)
-if test "$DRI" = yes; then
- PKG_CHECK_MODULES(DRI, [xf86driproto glproto])
- AC_DEFINE(XF86DRI,1,[Enable DRI driver support])
- AC_DEFINE(XF86DRI_DEVEL,1,[Enable developmental DRI driver support])
-fi
-
AM_CONDITIONAL(VIDEO_DEBUG, test x$VIDEO_DEBUG = xyes)
if test "$VIDEO_DEBUG" = yes; then
AC_DEFINE(VIDEO_DEBUG,1,[Enable debug support])
@@ -166,7 +144,6 @@ if test "$KMS_ONLY" = yes; then
AC_DEFINE(KMS_ONLY,1,[Assume KMS support])
fi
-AC_SUBST([DRI_CFLAGS])
AC_SUBST([XORG_CFLAGS])
AC_SUBST([WARN_CFLAGS])
AC_SUBST([moduledir])
diff --git a/src/Makefile.am b/src/Makefile.am
index 3b6e64d..5ffb522 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -26,7 +26,7 @@ SUBDIRS = xvmc bios_reader reg_dumper render_program
# _ladir passes a dummy rpath to libtool so the thing will actually link
# TODO: -nostdlib/-Bstatic/-lgcc platform magic, not installing the .a, etc.
-AM_CFLAGS = @WARN_CFLAGS@ @XORG_CFLAGS@ @DRM_CFLAGS@ @DRI_CFLAGS@ \
+AM_CFLAGS = @WARN_CFLAGS@ @XORG_CFLAGS@ @DRM_CFLAGS@ \
@PCIACCESS_CFLAGS@ -I$(top_srcdir)/uxa -I$(top_srcdir)/src/render_program
intel_drv_la_LTLIBRARIES = intel_drv.la
@@ -99,8 +99,6 @@ EXTRA_DIST = \
if DRI
intel_drv_la_SOURCES += \
$(INTEL_DRI_SRCS)
-intel_drv_la_LIBADD += \
- $(DRI_LIBS)
endif
if XVMC
diff --git a/src/i810.h b/src/i810.h
index 93b8b76..db36882 100644
--- a/src/i810.h
+++ b/src/i810.h
@@ -52,7 +52,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "xorg-server.h"
#include <pciaccess.h>
-#ifdef XF86DRI
+#ifdef HAVE_DRI
#include "xf86drm.h"
#include "sarea.h"
#define _XF86DRI_SERVER_
@@ -229,9 +229,9 @@ typedef struct _I810Rec {
I810ReadByteFunc readStandard;
Bool directRenderingDisabled; /* DRI disabled in PreInit */
- Bool directRenderingEnabled; /* false if XF86DRI not defined. */
+ Bool directRenderingEnabled; /* false if HAVE_DRI not defined. */
-#ifdef XF86DRI
+#ifdef HAVE_DRI
int LockHeld;
DRIInfoPtr pDRIInfo;
int drmSubFD;
@@ -272,7 +272,7 @@ typedef struct _I810Rec {
#define I810_SELECT_BACK 1
#define I810_SELECT_DEPTH 2
-#ifdef XF86DRI
+#ifdef HAVE_DRI
extern Bool I810DRIScreenInit(ScreenPtr pScreen);
extern void I810DRICloseScreen(ScreenPtr pScreen);
extern Bool I810DRIFinishScreenInit(ScreenPtr pScreen);
diff --git a/src/i810_accel.c b/src/i810_accel.c
index ae4a654..9484265 100644
--- a/src/i810_accel.c
+++ b/src/i810_accel.c
@@ -213,7 +213,7 @@ I810WaitLpRing(ScrnInfoPtr pScrn, int n, int timeout_millis)
start);
I810PrintErrorState(pScrn);
ErrorF("space: %d wanted %d\n", ring->space, n);
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
DRIUnlock(screenInfo.screens[pScrn->scrnIndex]);
DRICloseScreen(screenInfo.screens[pScrn->scrnIndex]);
@@ -245,7 +245,7 @@ I810Sync(ScrnInfoPtr pScrn)
if (I810_DEBUG & (DEBUG_VERBOSE_ACCEL | DEBUG_VERBOSE_SYNC))
ErrorF("I810Sync\n");
-#ifdef XF86DRI
+#ifdef HAVE_DRI
/* VT switching tries to do this.
*/
if (!pI810->LockHeld && pI810->directRenderingEnabled) {
diff --git a/src/i810_driver.c b/src/i810_driver.c
index 68e45bb..398244e 100644
--- a/src/i810_driver.c
+++ b/src/i810_driver.c
@@ -72,7 +72,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "i810.h"
#include "i830.h"
-#ifdef XF86DRI
+#ifdef HAVE_DRI
#include "dri.h"
#endif
@@ -280,7 +280,7 @@ int I810_DEBUG = (0
#endif
#ifndef I830_ONLY
-#ifdef XF86DRI
+#ifdef HAVE_DRI
static int i810_pitches[] = {
512,
1024,
@@ -651,7 +651,7 @@ I810PreInit(ScrnInfoPtr pScrn, int flags)
}
}
-#ifdef XF86DRI
+#ifdef HAVE_DRI
pI810->directRenderingDisabled =
!xf86ReturnOptValBool(pI810->Options, OPTION_DRI, TRUE);
@@ -852,7 +852,7 @@ I810PreInit(ScrnInfoPtr pScrn, int flags)
i = xf86ValidateModes(pScrn, pScrn->monitor->Modes,
pScrn->display->modes, clockRanges,
-#ifndef XF86DRI
+#ifndef HAVE_DRI
0, 320, 1600, 64 * pScrn->bitsPerPixel,
#else
i810_pitches, 0, 0, 64 * pScrn->bitsPerPixel,
@@ -908,7 +908,7 @@ I810PreInit(ScrnInfoPtr pScrn, int flags)
pI810->allowPageFlip=FALSE;
enable = xf86ReturnOptValBool(pI810->Options, OPTION_PAGEFLIP, FALSE);
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (!pI810->directRenderingDisabled) {
pI810->allowPageFlip = enable;
if (pI810->allowPageFlip == TRUE)
@@ -946,7 +946,7 @@ I810PreInit(ScrnInfoPtr pScrn, int flags)
pI810->numSurfaces = 0;
}
-#ifdef XF86DRI
+#ifdef HAVE_DRI
/* Load the dri module if requested. */
if (xf86ReturnOptValBool(pI810->Options, OPTION_DRI, FALSE)) {
xf86LoadSubModule(pScrn, "dri");
@@ -1662,7 +1662,7 @@ I810ModeInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
if (!I810SetMode(pScrn, mode))
return FALSE;
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
DRILock(screenInfo.screens[pScrn->scrnIndex], 0);
pI810->LockHeld = 1;
@@ -1671,7 +1671,7 @@ I810ModeInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
DoRestore(pScrn, &hwp->ModeReg, &pI810->ModeReg, FALSE);
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
DRIUnlock(screenInfo.screens[pScrn->scrnIndex]);
pI810->LockHeld = 0;
@@ -1943,7 +1943,7 @@ I810ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
* memory. Wonder if this is going to be a problem...
*/
-#ifdef XF86DRI
+#ifdef HAVE_DRI
/*
* Setup DRI after visuals have been established, but before fbScreenInit
* is called. fbScreenInit will eventually call into the drivers
@@ -2011,7 +2011,7 @@ I810ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
xf86SetBlackWhitePixels(pScreen);
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->LpRing->mem.Start == 0 && pI810->directRenderingEnabled) {
pI810->directRenderingEnabled = FALSE;
driFrom = X_PROBED;
@@ -2089,7 +2089,7 @@ I810ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
I810InitVideo(pScreen);
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
/* Now that mi, fb, drm and others have done their thing,
* complete the DRI setup.
@@ -2139,7 +2139,7 @@ I810SwitchMode(int scrnIndex, DisplayModePtr mode, int flags)
* If lockups on mode switch are still seen revisit this code. (EE)
*/
-# ifdef XF86DRI
+# ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
if (I810_DEBUG & DEBUG_VERBOSE_DRI)
ErrorF("calling dri lock\n");
@@ -2154,7 +2154,7 @@ I810SwitchMode(int scrnIndex, DisplayModePtr mode, int flags)
}
I810Restore(pScrn);
-# ifdef XF86DRI
+# ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
if (!I810DRILeave(pScrn))
return FALSE;
@@ -2228,7 +2228,7 @@ I810EnterVT(int scrnIndex, int flags)
{
ScrnInfoPtr pScrn = xf86Screens[scrnIndex];
-#ifdef XF86DRI
+#ifdef HAVE_DRI
I810Ptr pI810 = I810PTR(pScrn);
#endif
@@ -2238,7 +2238,7 @@ I810EnterVT(int scrnIndex, int flags)
if (!I810BindGARTMemory(pScrn)) {
return FALSE;
}
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (!I810DRIEnter(pScrn)) {
return FALSE;
}
@@ -2266,7 +2266,7 @@ I810LeaveVT(int scrnIndex, int flags)
if (I810_DEBUG & DEBUG_VERBOSE_DRI)
ErrorF("\n\n\nLeave VT\n");
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
if (I810_DEBUG & DEBUG_VERBOSE_DRI)
ErrorF("calling dri lock\n");
@@ -2284,7 +2284,7 @@ I810LeaveVT(int scrnIndex, int flags)
if (!I810UnbindGARTMemory(pScrn))
return;
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (!I810DRILeave(pScrn))
return;
#endif
@@ -2309,7 +2309,7 @@ I810CloseScreen(int scrnIndex, ScreenPtr pScreen)
I810Restore(pScrn);
vgaHWLock(hwp);
}
-#ifdef XF86DRI
+#ifdef HAVE_DRI
if (pI810->directRenderingEnabled) {
I810DRICloseScreen(pScreen);
pI810->directRenderingEnabled = FALSE;
diff --git a/src/i830.h b/src/i830.h
index 3143e5d..47f5526 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -61,10 +61,6 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "xorg-server.h"
#include <pciaccess.h>
-#include "xf86drm.h"
-#include "sarea.h"
-#define _XF86DRI_SERVER_
-#include "dri.h"
#include "GL/glxint.h"
#include "i830_dri.h"
#include "intel_bufmgr.h"
commit 07e0b2cff6107d6c86096c7da4e31b0c976794d5
Author: Rémi Cardona <remi at gentoo.org>
Date: Wed Oct 28 11:45:55 2009 +0100
configure: group system header checks at the top
Signed-off-by: Rémi Cardona <remi at gentoo.org>
Acked-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/configure.ac b/configure.ac
index 8661887..9978958 100644
--- a/configure.ac
+++ b/configure.ac
@@ -43,6 +43,7 @@ AM_PROG_CC_C_O
PKG_CHECK_MODULES(GEN4ASM, [intel-gen4asm >= 1.0], [gen4asm=yes], [gen4asm=no])
AM_CONDITIONAL(HAVE_GEN4ASM, test x$gen4asm = xyes)
+AC_HEADER_STDC
AC_CHECK_HEADERS(sys/mman.h)
AC_CHECK_FUNCS(mprotect)
@@ -100,11 +101,6 @@ AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
sdkdir=$(pkg-config --variable=sdkdir xorg-server)
-# Checks for libraries.
-
-# Checks for header files.
-AC_HEADER_STDC
-
save_CFLAGS="$CFLAGS"
CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $DRM_CFLAGS"
CPPFLAGS="$XORG_CFLAGS $DRI_CFLAGS $DRM_CFLAGS"
commit 0401a4c3143c5b94875cb4c66c94a0d247c32da5
Author: Rémi Cardona <remi at gentoo.org>
Date: Wed Oct 28 11:42:41 2009 +0100
configure: check for libdrm and libpciaccess earlier
Signed-off-by: Rémi Cardona <remi at gentoo.org>
Acked-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/configure.ac b/configure.ac
index 19dbf13..8661887 100644
--- a/configure.ac
+++ b/configure.ac
@@ -91,13 +91,14 @@ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
# Checks for pkg-config packages
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.6 xproto fontsproto $REQUIRED_MODULES])
+PKG_CHECK_MODULES(DRM, [libdrm >= 2.4.11])
+PKG_CHECK_MODULES(PCIACCESS, [pciaccess >= 0.10])
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")
AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
sdkdir=$(pkg-config --variable=sdkdir xorg-server)
-drm_cflags=$(pkg-config --cflags libdrm)
# Checks for libraries.
@@ -105,8 +106,8 @@ drm_cflags=$(pkg-config --cflags libdrm)
AC_HEADER_STDC
save_CFLAGS="$CFLAGS"
-CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $drm_cflags"
-CPPFLAGS="$XORG_CFLAGS $DRI_CFLAGS $drm_cflags"
+CFLAGS="$XORG_CFLAGS $DRI_CFLAGS $DRM_CFLAGS"
+CPPFLAGS="$XORG_CFLAGS $DRI_CFLAGS $DRM_CFLAGS"
AC_MSG_CHECKING([whether to include DRI support])
if test x$DRI != xno; then
AC_CHECK_FILE([${sdkdir}/dri.h],
@@ -129,8 +130,6 @@ fi
AC_MSG_RESULT([$DRI])
CFLAGS="$save_CFLAGS $DEBUGFLAGS"
-PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.10])
-
dnl Use lots of warning flags with GCC
WARN_CFLAGS=""
@@ -141,7 +140,6 @@ if test "x$GCC" = "xyes"; then
-Wnested-externs -fno-strict-aliasing"
fi
-PKG_CHECK_MODULES(DRM, [libdrm >= 2.4.11])
AM_CONDITIONAL(DRI, test x$DRI = xyes)
if test "$DRI" = yes; then
PKG_CHECK_MODULES(DRI, [xf86driproto glproto])
More information about the xorg-commit
mailing list