This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] fix parsing of -f argument in gdb_mbuild.sh


I just ran the new gdb_mbuild.sh for the first time, and it gave a
usage error when I invoked it as

  ${BUILDGDBDIR}/gdb_mbuild.sh -k -f ${BUILDSRCDIR} ${BUILDDESTDIR}

Looking into the code for the command line parser, it turns out that
there was an extra shift in the parsing of '-f', so it never saw
${BUILDSRCDIR}.

I've committed the following patch as obvious; it makes it past that
error now.

David Carlton
carlton@math.stanford.edu

2003-02-07  David Carlton  <carlton@math.stanford.edu>

	* gdb_mbuild.sh: Delete extra shift after parsing '-f'.

Index: gdb_mbuild.sh
===================================================================
RCS file: /cvs/src/src/gdb/gdb_mbuild.sh,v
retrieving revision 1.6
diff -u -p -r1.6 gdb_mbuild.sh
--- gdb_mbuild.sh	14 Jan 2003 00:49:04 -0000	1.6
+++ gdb_mbuild.sh	8 Feb 2003 00:39:13 -0000
@@ -85,7 +85,8 @@ do
 	;;
     -f )
 	# Force a rebuild
-	force=true ; shift ;;
+	force=true ;
+	;;
     -v )
 	# Be more, and more, and more, verbose
 	verbose=`expr ${verbose} + 1`


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]