subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From danie...@apache.org
Subject svn commit: r1139599 - /subversion/trunk/get-deps.sh
Date Sat, 25 Jun 2011 19:39:38 GMT
Author: danielsh
Date: Sat Jun 25 19:39:38 2011
New Revision: 1139599

URL: http://svn.apache.org/viewvc?rev=1139599&view=rev
Log:
* get-deps.sh: Break out helper functions for each dependency.

Modified:
    subversion/trunk/get-deps.sh

Modified: subversion/trunk/get-deps.sh
URL: http://svn.apache.org/viewvc/subversion/trunk/get-deps.sh?rev=1139599&r1=1139598&r2=1139599&view=diff
==============================================================================
--- subversion/trunk/get-deps.sh (original)
+++ subversion/trunk/get-deps.sh Sat Jun 25 19:39:38 2011
@@ -41,40 +41,75 @@ TEMPDIR=$BASEDIR/temp
 # be downloaded are no longer available on the general mirrors.
 APACHE_MIRROR=http://archive.apache.org/dist
 
-get_deps() {
-    mkdir -p $TEMPDIR
+get_apr() {
     cd $TEMPDIR
-
-    for d in neon zlib serf sqlite-amalgamation apr apr-util; do
-      if [ -d $i ]; then
-        echo "Local directory '$i' already exists; the downloaded copy won't be used" >&2
-      fi
-    done
-
     wget -nc $APACHE_MIRROR/apr/$APR.tar.bz2
     wget -nc $APACHE_MIRROR/apr/$APR_UTIL.tar.bz2
+    cd $BASEDIR
+
+    bzip2 -dc $TEMPDIR/$APR.tar.bz2 | tar -xf -
+    bzip2 -dc $TEMPDIR/$APR_UTIL.tar.bz2 | tar -xf -
+
+    mv $APR apr
+    mv $APR_UTIL apr-util
+}
+
+get_neon() {
+    cd $TEMPDIR
     wget -nc http://webdav.org/neon/$NEON.tar.gz
+    cd $BASEDIR
+
+    gzip  -dc $TEMPDIR/$NEON.tar.gz | tar -xf -
+
+    mv $NEON neon
+}
+
+get_serf() {
+    cd $TEMPDIR
     wget -nc http://serf.googlecode.com/files/$SERF.tar.bz2
-    wget -nc http://www.zlib.net/$ZLIB.tar.bz2
-    wget -nc http://www.sqlite.org/$SQLITE.zip
+    cd $BASEDIR
 
+    bzip2 -dc $TEMPDIR/$SERF.tar.bz2 | tar -xf -
+
+    mv $SERF serf
+}
+
+get_zlib() {
+    cd $TEMPDIR
+    wget -nc http://www.zlib.net/$ZLIB.tar.bz2
     cd $BASEDIR
-    gzip  -dc $TEMPDIR/$NEON.tar.gz | tar -xf -
+
     bzip2 -dc $TEMPDIR/$ZLIB.tar.bz2 | tar -xf -
-    bzip2 -dc $TEMPDIR/$SERF.tar.bz2 | tar -xf -
-    unzip -q $TEMPDIR/$SQLITE.zip
 
-    mv $NEON neon
     mv $ZLIB zlib
-    mv $SERF serf
-    mv $SQLITE sqlite-amalgamation
+}
 
-    bzip2 -dc $TEMPDIR/$APR.tar.bz2 | tar -xf -
-    bzip2 -dc $TEMPDIR/$APR_UTIL.tar.bz2 | tar -xf -
-    mv $APR apr
-    mv $APR_UTIL apr-util
+get_sqlite() {
+    cd $TEMPDIR
+    wget -nc http://www.sqlite.org/$SQLITE.zip
     cd $BASEDIR
 
+    unzip -q $TEMPDIR/$SQLITE.zip
+
+    mv $SQLITE sqlite-amalgamation
+
+}
+
+get_deps() {
+    mkdir -p $TEMPDIR
+
+    for d in neon zlib serf sqlite-amalgamation apr apr-util; do
+      if [ -d $i ]; then
+        echo "Local directory '$i' already exists; the downloaded copy won't be used" >&2
+      fi
+    done
+
+    get_apr
+    get_neon
+    get_serf
+    get_zlib
+    get_sqlite
+
     echo
     echo "If you require mod_dav_svn, the recommended version of httpd is:"
     echo "   $APACHE_MIRROR/httpd/$HTTPD.tar.bz2"



Mime
View raw message