|
From: | Charles Wilson |
Subject: | Re: [PATCH] Cwrapper should not eat -- arguments |
Date: | Sun, 25 May 2008 17:04:23 -0400 |
User-agent: | Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.8.1.14) Gecko/20080421 Thunderbird/2.0.0.14 Mnenhy/0.7.5.666 |
Ralf Wildenhues wrote:
As discussed here: http://lists.gnu.org/archive/html/libtool-patches/2008-05/msg00067.html... this message specifies that the first argument not matching --lt-should end parsing, whereas your patch parses all arguments.
Last message in the thread, at the very bottom: > Eric wrote:
let's go ahead and implement your proposal, of scanning ALL arguments for --lt-* regardless of position then stripping them, even if they appear in between the target's option and its argument or occur after a -- argument for the target, and not worry about any prefix besides- --lt-* for now.
> Ralf wrote:
Also, it does argument parsing twice, needlessly.
About scanning the arguments twice: the first scan looks solely for --lt-dump-script, and does so very early. We want this to work even if the target executable doesn't exist...if we waited until the later parsing loop, we might hit some error that is not germane to "can I dump the script or not".
Technically, the --lt-dump-script is now superfluous, so all that stuff, including the extra argument-scanning loop, could be removed. But I'm not comfortable ripping it out just yet.
Other than that, the only thing this patch is missing is a testsuite test ensuring that "--" really is passed through. (Such an addition is preapproved.)
I tested this manually using -DDEBUGWRAPPER, but I don't know diddly about writing tests for the testsuite -- and besides, this test would be mingw/cygwin-host specific, and would fail on all cross builds unless $build has wine and binfmt... if the test is so fragile, what's the point?
-- Chuck
[Prev in Thread] | Current Thread | [Next in Thread] |