[PATCH] configure: introduce --{enable,disable}-libdrm

Gaetan Nadon memsize at videotron.ca
Fri Jan 22 14:18:20 PST 2010


On Fri, 2010-01-22 at 19:04 +0200, Tiago Vignatti wrote:

> Some drivers use DRI protocol but implement their own kernel rendering
> manager. For these drivers, libdrm becomes useless.
> 
> Signed-off-by: Tiago Vignatti <tiago.vignatti at nokia.com>
> ---
>  configure.ac             |   10 +++++++---
>  include/xorg-config.h.in |    3 +++
>  2 files changed, 10 insertions(+), 3 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 8c1085b..553d61b 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -626,6 +626,7 @@ AC_ARG_ENABLE(xaa,               AS_HELP_STRING([--enable-xaa], [Build XAA (defa
>  AC_ARG_ENABLE(vgahw,          AS_HELP_STRING([--enable-vgahw], [Build Xorg with vga access (default: enabled)]), [VGAHW=$enableval], [VGAHW=yes])
>  AC_ARG_ENABLE(vbe,            AS_HELP_STRING([--enable-vbe], [Build Xorg with VBE module (default: enabled)]), [VBE=$enableval], [VBE=yes])
>  AC_ARG_ENABLE(int10-module,     AS_HELP_STRING([--enable-int10-module], [Build Xorg with int10 module (default: enabled)]), [INT10MODULE=$enableval], [INT10MODULE=yes])
> +AC_ARG_ENABLE(libdrm, AS_HELP_STRING([--enable-libdrm], [Build Xorg with libdrm support (default: enabled)]), [DRM=$enableval],[DRM=yes])

                                nit: indentation of all the statements
was nearly perfect.

>  
>  dnl DDXes.
>  AC_ARG_ENABLE(xorg,    	      AS_HELP_STRING([--enable-xorg], [Build Xorg server (default: auto)]), [XORG=$enableval], [XORG=auto])
> @@ -1007,9 +1008,12 @@ esac
>  AM_CONDITIONAL(DRI2, test "x$DRI2" = xyes)
>  
>  if test "x$DRI" = xyes || test "x$DRI2" = xyes; then
> -	PKG_CHECK_MODULES([LIBDRM], $LIBDRM)
> -	AC_SUBST(LIBDRM_CFLAGS)
> -	AC_SUBST(LIBDRM_LIBS)
> +	if test "x$DRM" = xyes; then
> +		AC_DEFINE(WITH_LIBDRM, 1, [Building with libdrm support])
> +		PKG_CHECK_MODULES([LIBDRM], $LIBDRM)
> +		AC_SUBST(LIBDRM_CFLAGS)
> +		AC_SUBST(LIBDRM_LIBS)

                    nit:        AC_SUBST not required, already done by
PKG_CHECK_MODULES

> +	fi
>  fi
>  
>  if test "x$DRI2" = xyes; then
> diff --git a/include/xorg-config.h.in b/include/xorg-config.h.in
> index 8946a65..56ffda2 100644
> --- a/include/xorg-config.h.in
> +++ b/include/xorg-config.h.in
> @@ -139,4 +139,7 @@
>  /* Support PC98 */
>  #undef SUPPORT_PC98
>  
> +/* Build with libdrm support */
> +#undef WITH_LIBDRM
> +
>  #endif /* _XORG_CONFIG_H_ */



Tested-by: Gaetan Nadon <memsize at videotron.ca>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.x.org/archives/xorg-devel/attachments/20100122/2a41220e/attachment.html 


More information about the xorg-devel mailing list