[PATCH] xlibs/build-em

David Pashley david@davidpashley.com
Wed, 10 Mar 2004 20:21:31 +0000


--pQhZXvAqiZgbeUkD
Content-Type: multipart/mixed; boundary="qtZFehHsKgwS5rPz"
Content-Disposition: inline


--qtZFehHsKgwS5rPz
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Here is a quick patch to the build-em script to:
  * enable use of automake 1.8
  * simpler comment removal from Packages (was this done the old way for
    portability reasons?) and change to building from the root of the
    checkout
  * only update a directory if you already have it checked out

flames/comments welcome.

--=20
David Pashley
david@davidpashley.com
Nihil curo de ista tua stulta superstitione.

--qtZFehHsKgwS5rPz
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="build-em.diff"
Content-Transfer-Encoding: quoted-printable

Index: build-em
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /cvs/xlibs/xlibs/build-em,v
retrieving revision 1.6
diff -u -3 -p -r1.6 build-em
--- build-em	11 Nov 2003 19:10:03 -0000	1.6
+++ build-em	10 Mar 2004 19:14:24 -0000
@@ -6,10 +6,10 @@ set -e
 ## Uncomment this to perform the "make install" step using sudo
 #BUILD_EM_SUDO=3Dsudo
=20
-if automake --version | grep 'automake' | grep -q '1\.7'; then
-	echo 'found automake 1.7'
+if automake --version | grep 'automake' | grep -q '1\.[78]'; then
+	echo 'found automake 1.7 or 1.8'
 else
-	echo 'automake is not version 1.7'
+	echo 'automake is not version 1.7 or 1.8'
 	exit 1
 fi
 if autoconf --version | grep 'autoconf' | grep -q '2\.5'; then
@@ -23,27 +23,25 @@ if libtoolize --version | grep 'libtool'
 else
 	echo 'libtool 1.5 is not or better'
 fi
-PACKAGES=3D`cat Packages | while read i; do
-	case "$i" in
-	'#'*)
-		;;
-	*)
-		echo $i
-		;;
-	esac
-done`
+PACKAGES=3D`grep -v ^# xlibs/Packages`
 for i in $PACKAGES; do
-	echo "Checking out package $i"
-	cvs co $i
 	cwd=3D`pwd`
-	cd $i
+   if [ ! -d $i ]; then
+      echo "Checking out package $i"
+      cvs co $i
+      cd $i
+   else=20
+      cd $i
+      echo "Updating package $i"
+      cvs update
+   fi
 	if  [ $# -gt 0 ] ||
 	    [ configure.ac -nt config.status ] ||
 	    [ Makefile.am -nt config.status ]; then
 	    ./autogen.sh "$@"
 	fi
 	make -j2
-	$BUILD_EM_SUDO make install
+	$BUILD_EM_SUDO make install=20
 	cd $cwd
 done
=20

--qtZFehHsKgwS5rPz--

--pQhZXvAqiZgbeUkD
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQFAT3jLYsCKa6wDNXYRAsyZAJ4h4B7Ng3YEVbiWfSpCI0OA0qo5igCdEWWd
NwRtzmDdJcxzS+TSRhN5Ltc=
=QbBq
-----END PGP SIGNATURE-----

--pQhZXvAqiZgbeUkD--