Update packaging script with the new noredist flag

Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/4d461d5e
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/4d461d5e
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/4d461d5e

Branch: refs/heads/master
Commit: 4d461d5ef279fdabffdf96144ca5af8e6d0eb208
Parents: 7f24814
Author: Hugo Trippaers <[email protected]>
Authored: Wed Sep 18 19:34:32 2013 +0800
Committer: Hugo Trippaers <[email protected]>
Committed: Sat Sep 21 12:32:09 2013 +0800

----------------------------------------------------------------------
 packaging/centos63/package.sh | 22 ++++++----------------
 1 file changed, 6 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/4d461d5e/packaging/centos63/package.sh
----------------------------------------------------------------------
diff --git a/packaging/centos63/package.sh b/packaging/centos63/package.sh
index f30a0e7..8337944 100755
--- a/packaging/centos63/package.sh
+++ b/packaging/centos63/package.sh
@@ -18,14 +18,14 @@
 
 function usage() {
  echo ""
- echo "usage: ./package.sh [-p|--pack] [-h|--help] [ARGS]"
+ echo "usage: ./package.sh [-p|e-pack] [-h|--help] [ARGS]"
  echo ""
  echo "The commonly used Arguments are:"
- echo "oss|OSS         To package OSS specific"
- echo "nonoss|NONOSS   To package NONOSS specific"
+ echo "oss|OSS             To package OSS specific"
+ echo "noredist|NOREDIST   To package with no redistributable libraries"
  echo ""
  echo "Examples: ./package.sh -p|--pack oss|OSS"
- echo "          ./package.sh -p|--pack nonoss|NONOSS"
+ echo "          ./package.sh -p|--pack noredist|NOREDIST"
  echo "          ./package.sh (Default OSS)"
  exit 1
 }
@@ -114,6 +114,7 @@ elif [ $# -gt 0 ] ; then
        eval set -- "$ARGS"
 
        while [ $# -gt 0 ] ; do
+        echo $1
        case "$1" in
        -h | --help)
                usage
@@ -124,7 +125,7 @@ elif [ $# -gt 0 ] ; then
                packageval=$2
                if [ "$packageval" == "oss" -o "$packageval" == "OSS" ] ; then
                        defaultPackaging
-               elif [ "$packageval" == "nonoss" -o "$packageval" == "NONOSS" ] 
; then
+               elif [ "$packageval" == "noredist" -o "$packageval" == 
"NOREDIST" ] ; then
                        packaging
                else
                        echo "Error: Incorrect value provided in package.sh 
script, Please see help ./package.sh --help|-h for more details."
@@ -136,19 +137,8 @@ elif [ $# -gt 0 ] ; then
                usage
                exit 1
                ;;
-       --)
-               echo "Unrecognized option..."
-               usage
-               exit 1
-               ;;
-       -*)
-               echo "Unrecognized option..."
-               usage
-               exit 1
-               ;;
        *)
                shift
-               break
                ;;
        esac
        done

Reply via email to