Janitor/RFC: Xorg packages

Alan Coopersmith Alan.Coopersmith at Sun.COM
Fri Feb 6 13:26:11 PST 2009


Paulo César Pereira de Andrade wrote:
> 2. Replace most gratuitous AC_SUBST(VAR) by usage
>    of $(VAR) in the Makefile.am's. It not only allows
>    using "%make VAR=someval", but also has the
>    benefit of a cleaner configure.ac.

Sounds good to me.

> 3. In video drivers configure.ac's, there is a lot of
>    tests in the format:
>    save_FOOFLAGS="$FOOFLAGS"
>    AC_CHECK_DECL(SOME_DEFINE,
>                  SOME_DEFINE=yes, SOME_DEFINE=no,
>                  [#include "xorg-server.h"])
>    <some-shell-code>
>    FOOFLAGS="$save_FOOFLAGS"
>    Maybe, xorg-macros should be extended, to have
>    proper:
>    XORG_LIBPCIACCESS
>    XORG_XF1OR4BPP
>    XORG_HASISA
>    XORG_DRMSTUFF
>    macros, and similar? To avoid too much cut&paste,
>    and slightly different variants for every driver.

Stuff specifically for Xorg drivers should be in xserver/xorg-server.m4
not the general xorg-macros package.

I have become a fan of the "DRY" (Don't Repeat Yourself) programming
mantra - every extra copy of code is an opportunity to get out of sync
and need to spend more time maintaining it later.

-- 
	-Alan Coopersmith-           alan.coopersmith at sun.com
	 Sun Microsystems, Inc. - X Window System Engineering



More information about the xorg-devel mailing list