Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build fails on Mac/Linux/Windows #14644

Closed
cnblogs-dudu opened this issue May 30, 2015 · 5 comments
Closed

Build fails on Mac/Linux/Windows #14644

cnblogs-dudu opened this issue May 30, 2015 · 5 comments
Assignees
Milestone

Comments

@cnblogs-dudu
Copy link
Contributor

Fails on Mac OS X:

/git/dotnet/corefx/dir.props(214,5): warning : The Roslyn targets do not exist- Roslyn will not be used for this build, but the package should be restored if you build again. [/git/dotnet/corefx/src/dirs.proj]
/git/dotnet/corefx/dir.props(214,5): warning : The Roslyn targets do not exist- Roslyn will not be used for this build, but the package should be restored if you build again. [/git/dotnet/corefx/src/Microsoft.CSharp/src/Microsoft.CSharp.csproj]
  /var/folders/c4/lf8cm6lx5178xsswpzfs2f_c0000gn/T/tmp257bf798c8da46a7baf3954722152b21.exec.cmd: line 3: /git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu: Permission denied
/git/dotnet/corefx/packages/Microsoft.DotNet.BuildTools.1.0.25-prerelease-00050/lib/packageresolve.targets(31,5): error MSB3073: The command ""/git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu" restore --packages "/git/dotnet/corefx/packages" "/git/dotnet/corefx/src/Microsoft.CSharp/src/project.json"" exited with code 126. [/git/dotnet/corefx/src/Microsoft.CSharp/src/Microsoft.CSharp.csproj]
/git/dotnet/corefx/dir.props(214,5): warning : The Roslyn targets do not exist- Roslyn will not be used for this build, but the package should be restored if you build again. [/git/dotnet/corefx/src/Microsoft.Win32.Primitives/src/Microsoft.Win32.Primitives.csproj]
  /var/folders/c4/lf8cm6lx5178xsswpzfs2f_c0000gn/T/tmp89e5d691ac6446dabae4c083d92fd9bd.exec.cmd: line 3: /git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu: Permission denied
/git/dotnet/corefx/packages/Microsoft.DotNet.BuildTools.1.0.25-prerelease-00050/lib/packageresolve.targets(31,5): error MSB3073: The command ""/git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu" restore --packages "/git/dotnet/corefx/packages" "/git/dotnet/corefx/src/Microsoft.Win32.Primitives/src/project.json"" exited with code 126. [/git/dotnet/corefx/src/Microsoft.Win32.Primitives/src/Microsoft.Win32.Primitives.csproj]
/git/dotnet/corefx/dir.props(214,5): warning : The Roslyn targets do not exist- Roslyn will not be used for this build, but the package should be restored if you build again. [/git/dotnet/corefx/src/Microsoft.Win32.Registry/src/Microsoft.Win32.Registry.csproj]
  /var/folders/c4/lf8cm6lx5178xsswpzfs2f_c0000gn/T/tmpba5e44afbb9c48f3ab1bf163cbddabb8.exec.cmd: line 3: /git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu: Permission denied
/git/dotnet/corefx/packages/Microsoft.DotNet.BuildTools.1.0.25-prerelease-00050/lib/packageresolve.targets(31,5): error MSB3073: The command ""/git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu" restore --packages "/git/dotnet/corefx/packages" "/git/dotnet/corefx/src/Microsoft.Win32.Registry/src/project.json"" exited with code 126. [/git/dotnet/corefx/src/Microsoft.Win32.Registry/src/Microsoft.Win32.Registry.csproj]
/git/dotnet/corefx/dir.props(214,5): warning : The Roslyn targets do not exist- Roslyn will not be used for this build, but the package should be restored if you build again. [/git/dotnet/corefx/src/System.Collections.Concurrent/src/System.Collections.Concurrent.csproj]
  /var/folders/c4/lf8cm6lx5178xsswpzfs2f_c0000gn/T/tmpa8d1d413c9b042f49cd65c851cd46177.exec.cmd: line 3: /git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu: Permission denied
/git/dotnet/corefx/packages/Microsoft.DotNet.BuildTools.1.0.25-prerelease-00050/lib/packageresolve.targets(31,5): error MSB3073: The command ""/git/dotnet/corefx/packages/dnx-mono.1.0.0-beta5-11760/bin/dnu" restore --packages "/git/dotnet/corefx/packages" "/git/dotnet/corefx/src/System.Collections.Concurrent/src/project.json"" exited with code 126. [/git/dotnet/corefx/src/System.Collections.Concurrent/src/System.Collections.Concurrent.csproj]
/git/dotnet/corefx/dir.props(214,5): warning : The Roslyn targets do not exist- Roslyn will not be used for this build, but the package should be restored if you build again. [/git/dotnet/corefx/src/System.Collections.Immutable/src/System.Collections.Immutable.csproj]
Attempting to cancel the build...
/git/dotnet/corefx/packages/Microsoft.Build.Mono.Debug.14.1.0.0-prerelease/lib/Microsoft.CSharp.CurrentVersion.targets(383,9): error MSB6006: "csc2.exe" exited with code 130. [/git/dotnet/corefx/src/System.Collections.Immutable/src/System.Collections.Immutable.csproj]

    6 Warning(s)
    5 Error(s)

Fails on Linux CentOS:

Restoring MSBuild...
WARNING: Error: SendFailure (Error writing headers)
WARNING: Error: SendFailure (Error writing headers)
WARNING: The request timed out
WARNING: Error: SendFailure (Error writing headers)
Unable to find version '14.1.0.0-prerelease' of package 'Microsoft.Build.Mono.Debug'.
Failed to restore MSBuild.

Fails on Windows with VS2015:

error CS0117: 'SR' does not contain a definition for 'ResourceType'

33 errors, see https://gist.github.com/cnblogs-dudu/d74afabd6849121c395e

@JeremyKuhne
Copy link
Member

It looks like you're having issues restoring the dependencies for Mac/Linux.

The Linux problem is listed on the wiki: https://github.com/dotnet/corefx/wiki/Building%20On%20Unix. Try mozroots --import --sync as listed there and see if that helps.

For the Mac/Windows we can look at it with more details- can you delete your /packages directory and follow the instructions on the wiki? Please describe exactly what you've done and what output you get. I assume for the Mac it just failed to download the Roslyn package (Microsoft.Net.ToolsetCompilers).

Also helpful:

  • On Windows do you have Visual Studio 2013 installed as well?
  • What is your head at for CoreFx and Mono?

@JeremyKuhne JeremyKuhne self-assigned this May 30, 2015
@cnblogs-dudu
Copy link
Contributor Author

@JeremyKuhne
Thanks.

For Linux, mozroots --import --sync fixes it.

For Mac, when delete /packages directory and build, get the error Unable to read package from path 'Microsoft.Net.ToolsetCompilers.1.0.0-rc3-20150510-01.nupkg'(see detail). Then build again, get the same error The Roslyn targets do not exist.
Mono version on Mac: Mono JIT compiler version 4.1.0 (master/35fd7cd Thu May 21 20:04:25 CST 2015)

For Windows, build corefx on another computer that has Visual Studio 2013, get more errors(see detail).

@cnblogs-dudu
Copy link
Contributor Author

Build failure on Mac is caused by network problem between China and NuGet server.
When I downloaded all packages from a server at Silicon Valley to my Mac, the build got succeeded.

scp -r root@us_silicon_valley_server:/git/corefx/packages/ /git/dotnet/corefx
./build.sh
...
System.Xml.XPath.Tests -> /git/dotnet/corefx/bin/OSX.AnyCPU.Debug/System.Xml.XPath.Tests/System.Xml.XPath.Tests.dll
    1 Warning(s)
    0 Error(s)
Time Elapsed 00:07:33.93
Build Exit Code = 0

@JeremyKuhne
Copy link
Member

@cnblogs-dudu Thanks for the extra details. Looks like your issues are primarily related to network issues pulling down the required packages.

@ericstj Some thoughts: Not sure what sort of retry configurability we have or will have, but here is an example of where retry functionality might be useful.

Also, perhaps an initial step confirming the ability to even communicate with servers we know were going to hit? And maybe a more complete package audit as part of the build? Anything to get stronger feedback before compilation starts would help avoid confusion. :)

@cnblogs-dudu
Copy link
Contributor Author

Fix build failure on Windows by deleting bin directory in corefx and rebuilding.

@msftgits msftgits transferred this issue from dotnet/corefx Jan 31, 2020
@msftgits msftgits added this to the 1.0.0-rtm milestone Jan 31, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Jan 6, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants