fix quoting in win64.mak: add them only when invoking command#2438
fix quoting in win64.mak: add them only when invoking command#2438dlang-bot merged 1 commit intodlang:masterfrom
Conversation
|
Thanks for your pull request, @rainers! Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub fetch digger
dub run digger -- build "master + druntime#2438" |
ea47a72 to
037b4c2
Compare
|
Should the other makefiles be quoted as well? |
Do you mean win32.mak? IIRC DM tools don't work too well with spaces in path names to begin with. |
|
I removed auto-merege as I just noticed that I forgot to remove the quotes from the definition of CC and AR, which should be done for consistency. It will break patching by the auto-tester, though. I'll update here and hope for braddr/at-client#10 to go anywhere... |
|
OK. |
…en setting variable
037b4c2 to
4140d59
Compare
|
Oof, this broke Digger. Did not see this when it was posted. Will see if Digger can detect / patch around this. |
|
This is also unlike how it's done in Phobos and DMD: https://github.com/dlang/phobos/blob/ccfe79be52ec12c0c22c783dac69d41b7fcd5c27/win32.mak#L70 Working around this will require special handling for this Druntime makefile specifically. @rainers Would you mind going into a bit more detail for your motivations behind this change? Was it just some random cleanup opportunity you noticed, or does this PR facilitate some prior goal? Edit: Found the Phobos PR (for win64.mak only as well): dlang/phobos#6825 |
|
@CyberShadow Sorry for the breakage. How does digger invoke make? As you noticed this is for win64.mak only (it is also used to build model 32mscoff). I wouldn't expect dmc to work in a path with spaces to begin with, so there is little need to patch win32.mak. The default path for VS installations contain spaces, though. The previous version of the makefiles was quite a mess: some paths were expected to be quoted, some not. Some were forwarded with pretty broken escaping, e.g. The basic idea of the change is to unify that and simplify specifiying arguments by |
No problem, Digger's goal is to deal with breakages like these throughout D's history.
I just finished implementing the workaround:
Yes, combined with cmd.exe escaping it was quite messy:
I think at some point for |
Thanks, looks good.
Wow, that looks even worse than what I used until recently.
Yeah, that's a possible abuse. I didn't need it, and I hope noone else did ;-) |
|
@rainers @CyberShadow @wilzbach this has also broken nightly builds since about 3 weeks. |
|
Yes, you'll need to remove quoting for Phobos/Druntime makefile invocations. BTW, your |
|
Sorry for the breakage. I was already wondering why the nightlies are missing... See dlang/installer#368 |
|
Thanks for the fix :) |
...not when setting variable. This avoids having to skillfully quote variables with spaces in them: use
"CC=%cl64%"instead of"CC=\"%cl64%\""Not sure how the existing misquoting was supposed to work. Using quotes with the command is agnostic to using
/instead of\as a path separator, too.