delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2000/07/04/01:35:56

Date: Tue, 4 Jul 2000 08:32:36 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: "Mark E." <snowball3 AT bigfoot DOT com>
cc: djgpp-workers AT delorie DOT com
Subject: Re: DJGPP problem executing a script
In-Reply-To: <3960DCAC.13929.3BA35B@localhost>
Message-ID: <Pine.SUN.3.91.1000704083219.818F-100000@is>
MIME-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Mon, 3 Jul 2000, Mark E. wrote:

> I received a bug report about 'perldoc' (from the perl distribution) failing 
> because it has '#!perl' at the top. script_exec in dosexec.c turns 'perl' 
> into 'c:\djgpp\bin/perl.exe' (depending on your installation of course).
> 
> If I change script_exec to change backslashes to forward slashes before 
> calling the selected spawn function, perldoc gets 'c:/djgpp/bin/perl.exe' and 
> everything works. Would a patch to do this conversion be welcome or, as Eli 
> likes to say, am I missing something?

I don't think you miss something, but perhaps I am: why doesn't
"c:\djgpp\bin/perl.exe" work?  Is it because the script is run from
Bash, and Bash takes the backslashes as escapes?

And one more thing: djgpp.env forcibly mirrors the backslashes in PATH
in its [bash] and [sh] sections, to prevent these very problems.  So
why does dosexec.c still come up with backslashes?

In any case, I don't think that mirroring the backslashes inside
script_exec will do any harm.  I just would like to understand the
problem better.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019