You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I tried to run "dotnet" from a library folder, I got this error;
$ dotnet --version
bash: /C/Users/mrj00/source/repos/runtime/artifacts/bin/testhost/netcoreapp5.0-Windows_NT-Debug-x64/dotnet: No such file or directory
I thought the only valid values for -c for the libraries were "Release" and "Debug". So it should not accept "Checked".
So I tried this from the reporoot:
$ ./build.cmd -c Fizzbin
This was accepted. I interrupted the build, and the following folder was found:
artifacts/bin/coreclr/Windows_NT.x64.Fizzbin
I believe that the invalid values for -c should be rejected immediately, rather than appearing to succeed, only to produce difficulties later.
Checked used to be a valid configuration in CoreCLR. It was an intermediate flavor between Debug and Release. Actually, if you run the following command:
.\build.cmd -subset clr -configuration Checked
Things go fine without any issues. However, if you do:
.\build.cmd -configuration Checked
The build will fail at some point saying it could not open the include file version_info.h. Is Checked no longer supported in runtime and thus should we remove it? Or make it only work when building the clr subset? I ask because it's listed in the help as a valid option, but it doesn't work. @janvorli @danmosemsft
Regarding passing arbitrary values to the configuration parameter, if you use -subset clr, it fails almost immediately, which is a reasonable result. However, if you pass it to just build.cmd, it ultimately fails but takes quite some time, which is very misleading and prone to wasting time. It is worth mentioning it will also create folders for this passed configuration, which shouldn't happen.
I can work on correcting this. I would greatly appreciate feedback regarding the Checked configuration concerns.
@danmosemsft I see, so the Checked builds are a story still under debate. Then I'm planning to add a checking mechanism to make the build fail since the beginning when receiving invalid options, to avoid the problems described in the original post.
Through more experiments, I found that other parameters, such as -os and -arch also accept random values. This causes them to fail much later with huge unrelated, and therefore misleading error messages. Will work on fixing those as well. Also, I can confirm this issue is present on Linux too (build.sh).
Activity
danmoseley commentedon Apr 9, 2020
Also, does casing of the configuration matter? On Unix I'm guessing it produces an output folder with the same casing, so perhaps yes?
janvorli commentedon Apr 9, 2020
On unix, it matters. The old scripts (the src/coreclr/build.sh) accept any casing and fixes it. The new one doesn't seem to do so.
danmoseley commentedon Apr 9, 2020
It would be good to fix that too since it's just another thing to get wrong (or have to remember)
ivdiazsa commentedon Apr 16, 2020
Checked used to be a valid configuration in CoreCLR. It was an intermediate flavor between
DebugandRelease. Actually, if you run the following command:.\build.cmd -subset clr -configuration CheckedThings go fine without any issues. However, if you do:
.\build.cmd -configuration CheckedThe build will fail at some point saying it could not open the include file
version_info.h. IsCheckedno longer supported in runtime and thus should we remove it? Or make it only work when building theclrsubset? I ask because it's listed in the help as a valid option, but it doesn't work. @janvorli @danmosemsftRegarding passing arbitrary values to the
configurationparameter, if you use-subset clr, it fails almost immediately, which is a reasonable result. However, if you pass it to just build.cmd, it ultimately fails but takes quite some time, which is very misleading and prone to wasting time. It is worth mentioning it will also create folders for this passed configuration, which shouldn't happen.I can work on correcting this. I would greatly appreciate feedback regarding the Checked configuration concerns.
danmoseley commentedon Apr 16, 2020
@ivdiazsa #31852
ivdiazsa commentedon Apr 16, 2020
@danmosemsft I see, so the
Checkedbuilds are a story still under debate. Then I'm planning to add a checking mechanism to make the build fail since the beginning when receiving invalid options, to avoid the problems described in the original post.ivdiazsa commentedon Apr 17, 2020
Through more experiments, I found that other parameters, such as
-osand-archalso accept random values. This causes them to fail much later with huge unrelated, and therefore misleading error messages. Will work on fixing those as well. Also, I can confirm this issue is present on Linux too (build.sh).trylek commentedon Apr 17, 2020
Casing is hell. Sigh.
ivdiazsa commentedon May 13, 2020
Closing this as it's been fixed through issue #35222