This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH for COLLECT2 (revised)
- To: "Mark E." <snowball3 at usa dot net>
- Subject: Re: PATCH for COLLECT2 (revised)
- From: Jason Merrill <jason at cygnus dot com>
- Date: 29 Oct 1998 18:48:26 -0800
- Cc: egcs-patches at cygnus dot com
- References: "Mark E."'s message of Thu, 29 Oct 1998 10:18:37 +0000 <199810292127.VAA09160@out1.ibm.net>
>>>>> Mark E <snowball3@usa.net> writes:
>> Is it actually necessary to change / to \? I thought DOS accepted both.
> The file system in both DOS and Win95 can indeed handle / , but
> command.com (the default shell) in both can't. The system() function
> eventually calls the shell and if the shell is command.com, / will
> definitely not work because it's considered an option switch. DJGPP's
> system() provides a workaround when the proper flags are set (which I
> do in collect2.c's main() ).
If DJGPP works around it, why do you need to fix it up?
>> I don't think it'll work to do
>>
>> system ("cd foo");
>> system ("do stuff in foo");
>>
>> On Unix, at least, the first call has no effect. I think you should
>> change the code to use chdir(3) instead. That way you won't need to
>> conditionalize it.
> I should have put in some comments on what the parts of my patch
> does and why they're neccessary. The code you mention is
> conditionalized for Win95 and DOS (except DJGPP) to send the
> commands one at a time because command.com (both in DOS and
> Win95) doesn't support executing multiple commands on the
> command line.
Yes, I understand the purpose. I just don't think it'll do what you want
it to do.
I don't think we need to worry about Win95 without Cygwin32 or DOS without
DJGPP, so the FIXUP patches are unnecessary.
Jason