changeset 18731:bd21d8500afd

Use a function for help output.
author diego
date Fri, 16 Jun 2006 18:38:35 +0000
parents 93241711b635
children b3fa3772a187
files configure
diffstat 1 files changed, 11 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/configure	Fri Jun 16 18:35:31 2006 +0000
+++ b/configure	Fri Jun 16 18:38:35 2006 +0000
@@ -184,10 +184,8 @@
 
 LANGUAGES=`echo help/help_mp-??.h help/help_mp-??_??.h | sed "s:help/help_mp-\(..\).h:\1:g" | sed "s:help/help_mp-\(.....\).h:\1:g"`
 
-for parm in "$@" ; do
-  if test "$parm" = "--help" || test "$parm" = "-help" || test "$parm" = "-h" ; then
-    cat << EOF
-
+show_help(){
+cat << EOF
 Usage: $0 [OPTIONS]...
 
 Configuration:
@@ -440,10 +438,15 @@
 it will be forcefully turned on, skipping autodetection. This can break
 compilation, so you need to know what you are doing.
 EOF
-    exit 0
-  fi
-done # for parm in ...
-
+exit 0
+} #show_help()
+
+for parm in "$@" ; do
+  case $parm in
+    --help|-help|-h)
+      show_help
+  esac
+done
 
 # 1st pass checking for vital options
 _mmx=auto