diff options
author | Jeremy Kuhne <jeremy.kuhne@microsoft.com> | 2017-04-21 05:54:45 +0300 |
---|---|---|
committer | Dan Moseley <danmose@microsoft.com> | 2017-04-21 05:54:45 +0300 |
commit | c2d98347e4a0cbd5d4fe497cb4e7e7797e35502b (patch) | |
tree | 6a5484419f5a569a4ed658b763e6a11165b11525 /run.cmd | |
parent | 1c79b3e7492d69097ff23509dd75e2babc5dd872 (diff) |
Fix building with only VS2017 installed. (#18700)
We weren't passing the right setting to CMAKE.
Also fixes issue with current working directory getting changed during the build. Run.exe currently must be run
with the current working directory set to the repo root. One part of this was the config.json file- which I've explicitly specified now.
The other (as of yet unfixable) problem is that we specify the location of the binclash logger as a relative path. Afaik there currently is no way to make this happen with run.cmd without making this logger an explicit (as opposed to default) option. Could possibly extend run.exe's parsing to allow specifying environment variables or reference to other parameters...
I haven't nailed down who is changing the working directory- while it appears to be a 2017 specific problem I can't guarantee that it isn't some other variable.
Diffstat (limited to 'run.cmd')
-rw-r--r-- | run.cmd | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -43,6 +43,13 @@ xcopy %~dp0Tools-Override\* %~dp0Tools /y >nul set _toolRuntime=%~dp0Tools set _dotnet=%_toolRuntime%\dotnetcli\dotnet.exe +set _json=%~dp0config.json + +:: run.exe depends on running in the root directory, notably because the config.json specifies +:: a relative path to the binclash logger + +pushd %~dp0 +call %_dotnet% %_toolRuntime%\run.exe "%_json%" %* +popd -call %_dotnet% %_toolRuntime%\run.exe %* exit /b %ERRORLEVEL% |