Hi,

There are 41 driver modules with the line:

        sdkdir=$(pkg-config --variable=sdkdir xorg-server)


Following up on review
http://lists.x.org/archives/xorg-devel/2009-November/003711.html


        From Dan Nicholson:
        This should be
        
        sdkdir=`$PKG_CONFIG --variable=sdkdir xorg-server`
        
        1. The user may need to use a specific pkg-config or pass custom
        arguments to it. Think multiarch or cross-compiling scenarios.
        
        2. Backticks (``) are supported by all shells while $() command
        substitution is for strictly POSIX conforming shells. We don't
        need to
        limit ourselves to that subset.

There are 4 modules who are not using that line at all. Rather than
making dead code more portable, this patch removes this statement. I
have done extensive grepping and tested with make distcheck:


        apm, ark, dummy, vesa


In addition, the sdkdir was passed in INCLUDES. The sdkdir is already
included in XORG_CFLAGS. There were 2 copies of sdkdir in the Makefile
and after the patch there is only one.

The reference patch is video-vesa



>From d91d2a7b799638bdb47e73dcb331b4d640beff75 Mon Sep 17 00:00:00 2001
From: Gaetan Nadon <[email protected]>
Date: Tue, 15 Dec 2009 21:00:15 -0500
Subject: [PATCH] configure.ac: sdkdir usage duplicates the sdk include dir

The sdkdir variable provides a duplicate copy of the include/xorg
directory. The statement is removed as this was it's only used.
In the Makefile, there is now only one instance of the -I sdkdir

Signed-off-by: Gaetan Nadon <[email protected]>
---
 configure.ac |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index 548810a..fe47a60 100644
--- a/configure.ac
+++ b/configure.ac
@@ -64,7 +64,6 @@ 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)
 
 save_CFLAGS="$CFLAGS"
 CFLAGS="$XORG_CFLAGS"
@@ -95,7 +94,7 @@ fi
 AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
 
 CFLAGS="$CFLAGS $XORG_CFLAGS "' -I$(top_srcdir)/src'
-INCLUDES="$XORG_INCS -I${sdkdir} "'-I$(top_srcdir)/src'
+INCLUDES="$XORG_INCS "'-I$(top_srcdir)/src'
 AC_SUBST([CFLAGS])
 AC_SUBST([INCLUDES])
 
-- 
1.6.0.4

_______________________________________________
xorg-devel mailing list
[email protected]
http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to