This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


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

Re: DJGPP stage 2 C++ makefile failure


> From: "Mark E." <snowball3@bigfoot.com>
> Date: Sun, 16 Jul 2000 17:39:29 -0400
>
> CC will contain that pesky backslash and this is as you explained. It's set 
> by this line in gcc's configure:
> 	quoted_cc_set_by_configure="\\\`case '\\\$(CC)' in stage*) echo '\\\$(CC)' | 
> sed -e 's|stage|../stage|g';; *) echo '\\\$(CC)';; esac\\\`"
> 
> which is then substituted into the generated Makefile. If this line is 
> changed to use one backslash before $(CC) instead of three, then the lone 
> backslash goes away in the Makefile. From reading the comment in the 
> configure script, I think the idea is to quote CC so it survives into a sub-
> make when you have CC="stage1/xgcc -Bstage1/". To make that work, I think 
> quoted_cc_* above needs to be changed to:
> 	quoted_cc_set_by_configure="\\\`case '\$(CC)' in stage*) echo '\$(CC)' | sed 
> -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\\\`"
> 
> with that change, I get a definition of SUBDIR_FLAGS_TO_PASS that doesn't 
> introduce a backslash:

If this solution works on Unix, I think it's a good idea.

If not, we will need to force Make to run that command through the
shell.  As I understand it, right now, nothing in the offending
command which invokes $(CC) requires a shell, since a backslash alone
is not enough (on MSDOS) to cause that.  Adding some kind of
(redundant) quotes might be all you need.

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