sdk icon indicating copy to clipboard operation
sdk copied to clipboard

Dotnet publish does not detect OSX El Capitan RID correctly

Open schellap opened this issue 10 years ago • 12 comments

Follow these repro steps:

Obtain latest CLI from: https://dotnetcli.blob.core.windows.net/dotnet/dev/Binaries/Latest/dotnet-osx-x64.latest.tar.gz

mkdir temp
cd temp
dotnet init
dotnet restore
dotnet publish

Error:

'' cannot be published for '' 'osx.10.10-x64' 

@brthor, @piotrpMSFT route to appropriate owner. Blocks dotnet scenario and https://github.com/dotnet/corert/pull/498

schellap avatar Dec 09 '15 00:12 schellap

@schellap

This is on El Capitan, correct?

brthor avatar Dec 09 '15 00:12 brthor

This is on El Capitan. Yes.

schellap avatar Dec 09 '15 00:12 schellap

Is the rid different?

schellap avatar Dec 09 '15 00:12 schellap

RID for El Capitan is 'osx.10.11-x64' IIRC

brthor avatar Dec 09 '15 00:12 brthor

But I am not specifying any RID. Just running these steps. Should work or no?

schellap avatar Dec 09 '15 00:12 schellap

Can you try explicitly specifying the RID during restore and publish?

mkdir temp
cd temp
dotnet init
dotnet restore --runtime osx.10.11-x64 
dotnet publish --runtime osx.10.11-x64 

brthor avatar Dec 09 '15 00:12 brthor

This is only on el-capitan. It doesn't block the CoreRT PR as I specified because it is using Yosemite.

schellap avatar Dec 09 '15 00:12 schellap

Works with the RID.

schellap avatar Dec 09 '15 00:12 schellap

This needs to be fixed here. We have a naive way to find the current RID and its broken.

https://github.com/dotnet/cli/blob/master/src/Microsoft.DotNet.ProjectModel/RuntimeIdentifier.cs#L10

Sridhar-MS avatar Dec 09 '15 01:12 Sridhar-MS

Tracking in dotnet/cli#498

TheRealPiotrP avatar Dec 14 '15 23:12 TheRealPiotrP

This worked for me:

dotnet restore --runtime osx.10.10.10-x64

richlander avatar Dec 15 '15 18:12 richlander

@richlander That didnt work for me on OSX 10.11. The thing that actually works is that I specify "--runtime osx.10.11-x64".

gkhanna79 avatar Dec 15 '15 20:12 gkhanna79