]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Automagically setup submodules on first run. 2069/head
authorThorsten Behrens <tbehrens@suse.com>
Mon, 2 Jun 2014 20:11:24 +0000 (22:11 +0200)
committerThorsten Behrens <tbehrens@suse.com>
Wed, 2 Jul 2014 22:51:23 +0000 (00:51 +0200)
I mean, who's reading the README, anyway?

Signed-off-by: Thorsten Behrens <tbehrens@suse.com>
README
autogen.sh

diff --git a/README b/README
index f5a71bea4b08f3bbcde699a7b5250033b4cf2821..e947add40d20cf03a7e1d88e78042ab46c7210ad 100644 (file)
--- a/README
+++ b/README
@@ -26,10 +26,6 @@ contributed under the terms of the applicable license.
 Building Ceph
 =============
 
-To prepare the source tree after it has been git cloned,
-
-       git submodule update --init
-
 To build the server daemons, and FUSE client, execute the following:
 
        ./autogen.sh
index 43b5cc439e38d2c89faa3f3f6f2fda683b443f25..13e6d9c7f22d8c6825fba5271ca3314352023ced 100755 (executable)
@@ -28,6 +28,14 @@ else
   exit 1
 fi
 
+if test -d ".git" ; then
+  if ! git submodule update --init; then
+    echo "Error: could not initialize submodule projects"
+    echo "  Network connectivity might be required."
+    exit 1
+  fi
+fi
+
 rm -f config.cache
 aclocal -I m4 --install
 check_for_pkg_config