if gnu getopt is not available, don't bother processing any options
authorAndy Wingo <wingo@pobox.com>
Mon, 6 May 2002 18:15:36 +0000 (18:15 +0000)
committerAndy Wingo <wingo@pobox.com>
Mon, 6 May 2002 18:15:36 +0000 (18:15 +0000)
Original commit message from CVS:
if gnu getopt is not available, don't bother processing any options

gst-autogen.sh

index dcf4266..6c7c54b 100644 (file)
@@ -162,6 +162,11 @@ die_check ()
 
 autogen_options ()
 {
+  if test `getopt --version | cut -d' ' -f2` != "(enhanced)"; then
+    echo "- non-gnu getopt(1) detected, not running getopt on autogen command-line options"
+    return 0
+  fi
+
   # we use getopt stuff here, copied things from the example example.bash
   TEMP=`getopt -o h --long noconfigure,nocheck,debug,help,with-automake:,with-autoconf:,prefix:\
        -- "$@"`