move keystonemiddleware to pypi libs

Make keystonemiddleware install from pypi releases by default

Change-Id: I3dc4b096b4184f4cf00fb0df66b76fcc8f19785b
diff --git a/lib/keystone b/lib/keystone
index e2c823a..72a79be 100644
--- a/lib/keystone
+++ b/lib/keystone
@@ -34,6 +34,7 @@
 
 # Set up default directories
 GITDIR["python-keystoneclient"]=$DEST/python-keystoneclient
+GITDIR["keystonemiddleware"]=$DEST/keystonemiddleware
 
 KEYSTONE_DIR=$DEST/keystone
 KEYSTONE_CONF_DIR=${KEYSTONE_CONF_DIR:-/etc/keystone}
@@ -46,8 +47,6 @@
     KEYSTONE_WSGI_DIR=${KEYSTONE_WSGI_DIR:-/var/www/keystone}
 fi
 
-KEYSTONEMIDDLEWARE_DIR=$DEST/keystonemiddleware
-
 # Set up additional extensions, such as oauth1, federation
 # Example of KEYSTONE_EXTENSIONS=oauth1,federation
 KEYSTONE_EXTENSIONS=${KEYSTONE_EXTENSIONS:-}
@@ -489,8 +488,10 @@
 
 # install_keystonemiddleware() - Collect source and prepare
 function install_keystonemiddleware {
-    git_clone $KEYSTONEMIDDLEWARE_REPO $KEYSTONEMIDDLEWARE_DIR $KEYSTONEMIDDLEWARE_BRANCH
-    setup_install $KEYSTONEMIDDLEWARE_DIR
+    if use_library_from_git "keystonemiddleware"; then
+        git_clone_by_name "keystonemiddleware"
+        setup_dev_lib "keystonemiddleware"
+    fi
 }
 
 # install_keystone() - Collect source and prepare