msbuild: Can't build on UNIX

Hi. I can’t build the latest xplat commit (See 5a2dcc67bff636fa8107bbf08e1852a2e34121b8) on Mac OS X 10.11.

After checking out the latest xplat, I run ./cibuild and always get the following output:

Unsupported target detected: . Configuring as if for CoreCLR
Unsupported host detected: . Configuring as if for CoreCLR
Installing dotnet cli...
Restoring BuildTools version 1.0.25-prerelease-00231-07...
ERROR: Could not restore build tools correctly. See '/Volumes/DATA/Build/msb/buildme/init-tools.log' for more details.
Initializing BuildTools...
./init-tools.sh: line 84: /Volumes/DATA/Build/msb/buildme/packages/Microsoft.DotNet.BuildTools/1.0.25-prerelease-00231-07/lib/init-tools.sh: No such file or directory
Done initializing tools.
Build Command: ./Tools/corerun  ./Tools/MSBuild.exe ./build.proj /t:Build /p:OS=OSX /p:Configuration=Debug-NetCore /verbosity:minimal  /m /fl  "/flp:v=diag;logfile=./msbuild.log"
./cibuild.sh: line 42: ./Tools/corerun: No such file or directory

After looking at init-tools.log, found the following:

unning: /Volumes/DATA/Build/msb/buildme/init-tools.sh
Installing 'https://dotnetcli.blob.core.windows.net/dotnet/beta/Binaries/1.0.0-beta-002173/dotnet-dev-osx-x64.1.0.0-beta-002173.tar.gz' to '/Volumes/DATA/Build/msb/buildme/Tools/dotnetcli/dotnet.tar'
Running: /Volumes/DATA/Build/msb/buildme/Tools/dotnetcli/dotnet restore "/Volumes/DATA/Build/msb/buildme/Tools/1.0.25-prerelease-00231-07/project.json" --packages /Volumes/DATA/Build/msb/buildme/packages --source https://dotnet.myget.org/F/dotnet-buildtools/api/v3/index.json
log  : Restoring packages for /Volumes/DATA/Build/msb/buildme/Tools/1.0.25-prerelease-00231-07/project.json...
error: Failed to retrieve information from remote source '/Volumes/DATA/Build/msb/buildme/packages'.
error: Unable to load the service index for source https://dotnet.myget.org/F/dotnet-buildtools/api/v3/index.json.
error:   The type initializer for 'Crypto' threw an exception.
error:   Unable to load DLL 'System.Security.Cryptography.Native': The specified module could not be found.
error:    (Exception from HRESULT: 0x8007007E)
Running: /Volumes/DATA/Build/msb/buildme/packages/Microsoft.DotNet.BuildTools/1.0.25-prerelease-00231-07/lib/init-tools.sh /Volumes/DATA/Build/msb/buildme /Volumes/DATA/Build/msb/buildme/Tools/dotnetcli/dotnet /Volumes/DATA/Build/msb/buildme/Tools

I notice a few things:

  1. The packages subdirectory never got created.
  2. I can browse to https://dotnet.myget.org/F/dotnet-buildtools/api/v3/index.json even when the scripts says its index can’t be loaded.
  3. Maybe package System.Security.Cryptography.Native is outdated in the dependency mappings?
  4. The same commit was built successfully on Jenkins at http://dotnet-ci.cloudapp.net/job/Microsoft_msbuild/job/innerloop_xplat_OSX/87/ .

Is there any pre-configuration I need to make in order to build locally?

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 41 (41 by maintainers)

Most upvoted comments

For OSX, I would rm -Rf bin/ Tools/ packages/ and then try the build again.