Update to build.sh

Dan Nicholson dbn.lists at gmail.com
Mon Apr 7 07:25:32 PDT 2008


On Sun, Apr 6, 2008 at 12:05 PM, Robert Boucher <rboucher at bcssi.com> wrote:
> Dan Nicholson wrote:
>
> > It'd be nice if the module additions and movements were in a separate
> > patch. Looks good, though.
> >
>
>  Here are three patches to the original file.  The first moves pixman so it
> will be built with the rest of the libraries.  The second adds the
> additional modules.  The third adds the tarball build feature.  They were
> created with the intention of being applied successively and not
> individually.

These are nice features. Does anyone mind if I push them?

--
Dan

> --- build.sh.orig       2008-04-06 14:50:25.951220887 -0400
>  +++ build.sh    2008-04-06 14:51:10.863221533 -0400
>  @@ -204,6 +204,7 @@
>      build lib libXxf86misc
>      build lib libXxf86vm
>      build lib libpciaccess
>  +    build pixman ""
>   }
>
>   # Most apps depend at least on libX11.
>  @@ -322,7 +323,6 @@
>   # The server requires at least the following libraries:
>   # Xfont, Xau, Xdmcp, pciaccess
>   build_xserver() {
>  -    build pixman ""
>      build xserver ""
>   }
>
>
> --- build.sh.orig       2008-04-06 14:54:22.326220107 -0400
>  +++ build.sh    2008-04-06 14:53:26.425221100 -0400
>  @@ -96,6 +96,7 @@
>      build proto compositeproto
>      build proto damageproto
>      build proto dmxproto
>  +    build proto dri2proto
>      build proto evieproto
>      build proto fixesproto
>      build proto fontcacheproto
>  @@ -246,6 +247,7 @@
>      build app viewres
>      build app x11perf
>      build app xauth
>  +    build app xbacklight
>      build app xbiff
>      build app xcalc
>      build app xclipboard
>  @@ -421,11 +423,13 @@
>      build driver xf86-video-ark
>      build driver xf86-video-ast
>      build driver xf86-video-ati
>  +    build driver xf86-video-avivo
>      build driver xf86-video-chips
>      build driver xf86-video-cirrus
>      build driver xf86-video-cyrix
>      build driver xf86-video-dummy
>      build driver xf86-video-fbdev
>  +    build driver xf86-video-geode
>   #    build driver xf86-video-glide
>      build driver xf86-video-glint
>      build driver xf86-video-i128
>  @@ -433,6 +437,7 @@
>      build driver xf86-video-mga
>      build driver xf86-video-neomagic
>      build driver xf86-video-newport
>  +    build driver xf86-video-nouveau
>      build driver xf86-video-nsc
>      build driver xf86-video-nv
>      build driver xf86-video-radeonhd
>  @@ -528,6 +533,9 @@
>      build util makedepend
>      build util gccmakedep
>      build util lndir
>  +    if test x"$USE_XCB" != xNO ; then
>  +        build xcb util
>  +    fi
>   }
>
>   # xorg-docs requires xorg-sgml-doctools
>
> --- build.sh.orig       2008-04-06 14:54:33.403470374 -0400
>  +++ build.sh    2008-04-06 14:54:47.607221588 -0400
>  @@ -20,6 +20,73 @@
>      fi
>   }
>
>  +checkfortars() {
>  +    M=$1
>  +    C=$2
>  +    case $M in
>  +        "data")
>  +            case $C in
>  +                "cursors") C="xcursor-themes" ;;
>  +                "bitmaps") C="xbitmaps" ;;
>  +            esac
>  +            ;;
>  +        "font")
>  +            if [ "$C" != "encodings" ]; then
>  +                C="font-$C"
>  +            fi
>  +            ;;
>  +        "lib")
>  +            case $C in
>  +                "libXRes") C="libXres" ;;
>  +                "libxtrans") C="xtrans" ;;
>  +            esac
>  +            ;;
>  +        "pixman")
>  +            M="lib"
>  +            C="pixman"
>  +            ;;
>  +        "proto")
>  +            case $C in
>  +                "evieproto") C="evieext" ;;
>  +                "pmproto") C="xproxymanagementprotocol" ;;
>  +                "x11proto") C="xproto" ;;
>  +            esac
>  +            ;;
>  +        "util")
>  +            case $C in
>  +                "cf") C="xorg-cf-files" ;;
>  +                "macros") C="util-macros" ;;
>  +            esac
>  +            ;;
>  +        "xcb")
>  +            case $C in
>  +                "proto") C="xcb-proto" ;;
>  +                "pthread-stubs") M="lib"; C="libpthread-stubs" ;;
>  +                "util") C="xcb-util" ;;
>  +            esac
>  +            ;;
>  +        "xserver")
>  +            C="xorg-server"
>  +            ;;
>  +    esac
>  +    for ii in $M .; do
>  +        for jj in bz2 gz; do
>  +            TARFILE=`ls -1rt $ii/$C-*.tar.$jj 2> /dev/null | tail -1`
>  +            if [ -n "$TARFILE" ]; then
>  +                SRCDIR=`echo $TARFILE | sed "s,.tar.$jj,,"`
>  +                if [ ! -d $SRCDIR ]; then
>  +                    TAROPTS=xjf
>  +                    if [ "$jj" = "gz" ]; then
>  +                        TAROPTS=xzf
>  +                    fi
>  +                    tar $TAROPTS $TARFILE -C $ii || failed tar $1 $2
>  +                fi
>  +                return
>  +            fi
>  +        done
>  +    done
>  +}
>  +
>   build() {
>      if [ -n "$RESUME" ]; then
>         if [ "$RESUME" = "$1/$2" ]; then
>  @@ -31,15 +98,25 @@
>         fi
>      fi
>
>  -    if [ ! -d $1/$2 ]; then
>  +    SRCDIR=""
>  +    CONFCMD=""
>  +    if [ -f $1/$2/autogen.sh ]; then
>  +        SRCDIR="$1/$2"
>  +        CONFCMD="autogen.sh"
>  +    else
>  +        checkfortars $1 $2
>  +        CONFCMD="configure"
>  +    fi
>  +
>  +    if [ -z $SRCDIR ]; then
>          echo "$1 module component $2 does not exist, skipping."
>  -       nonexistent_components="$nonexistent_components $2/$3"
>  +        nonexistent_components="$nonexistent_components $1/$2"
>          return
>      fi
>
>      echo "Building $1 module component $2..."
>      old_pwd=`pwd`
>  -    cd $1/$2 || failed cd $1 $2
>  +    cd $SRCDIR || failed cd1 $1 $2
>
>      # Build outside source directory
>      if [ "x$DIR_ARCH" != x ] ; then
>  @@ -68,10 +145,10 @@
>
>      # Use "sh autogen.sh" since some scripts are not executable in CVS
>      if test "x$NOAUTOGEN" != x1 ; then
>  -        sh ${DIR_CONFIG}autogen.sh --prefix=${PREFIX} ${LIB_FLAGS} \
>  +        sh ${DIR_CONFIG}/${CONFCMD} --prefix=${PREFIX} ${LIB_FLAGS} \
>             ${MOD_SPECIFIC} ${QUIET:+--quiet} \
>             ${CACHE:+--cache-file=}${CACHE} ${CONFFLAGS} "$CONFCFLAGS" || \
>  -           failed autogen $1 $2
>  +           failed ${CONFCMD} $1 $2
>      fi
>      ${MAKE} $MAKEFLAGS || failed make $1 $2
>      if test x"$CLEAN" = x1; then
>  @@ -547,7 +624,7 @@
>   usage() {
>      echo "Usage: $0 [options] prefix"
>      echo "  where options are:"
>  -    echo "  -a : do NOT run autogen.sh"
>  +    echo "  -a : do NOT run auto config tools (autogen.sh, configure)"
>      echo "  -b : use .build.$HAVE_ARCH build directory"
>      echo "  -c : run make clean in addition to others"
>      echo "  -d : run make distcheck in addition to others"
>  @@ -561,7 +638,7 @@
>
>   HAVE_ARCH="`uname -i`"
>   DIR_ARCH=""
>  -DIR_CONFIG=""
>  +DIR_CONFIG="."
>
>   # Process command line args
>   while test $# != 0
>  @@ -572,7 +649,7 @@
>         ;;
>      -b)
>         DIR_ARCH=".build.$HAVE_ARCH"
>  -       DIR_CONFIG="../"
>  +       DIR_CONFIG=".."
>         ;;
>      -c)
>         CLEAN=1
>
>



More information about the xorg mailing list