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

Can no longer compile net451 compatible builds on linux with 1.1 tooling #7888

Closed
KallDrexx opened this issue Mar 9, 2017 · 4 comments
Closed

Comments

@KallDrexx
Copy link

Steps to reproduce

  1. Create new directory
  2. Create global.json file with the following content:
{ 
  "projects": [ "src", "test" ], 
  "sdk": { 
    "version": "1.0.0-preview2-1-003177" 
  } 
} 
  1. execute dotnet new

  2. Edit project.json and add net451 framework

  3. Execute dotnet restore then dotnet build

  4. Execute dotnet run
    ---> Observe everything works correctly

  5. rm global.json

  6. dotnet migrate

  7. dotnet build
    ---> Observe the following error:

/usr/share/dotnet/sdk/1.0.1/Microsoft.Common.CurrentVersion.targets(1111,5): error MSB3644: The reference assemblies for framework ".NETFramework,Version=v4.5.1" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend. [/home/mshapiro/Code/test/test.csproj]
/usr/share/dotnet/sdk/1.0.1/Sdks/Microsoft.NET.Sdk/build/Microsoft.NET.Sdk.targets(129,5): error : Assets file '/home/mshapiro/Code/test/obj/project.assets.json' not found. Run a NuGet package restore to generate this file. [/home/mshapiro/Code/test/test.csproj]

Environment data

dotnet --info output:


Product Information:
 Version:            1.0.1
 Commit SHA-1 hash:  005db40cd1

Runtime Environment:
 OS Name:     ubuntu
 OS Version:  16.04
 OS Platform: Linux
 RID:         ubuntu.16.04-x64
 Base Path:   /usr/share/dotnet/sdk/1.0.1
@KallDrexx KallDrexx changed the title Can no longer compile net451 builds on linux with 1.1 tooling Can no longer compile net451 compatible builds on linux with 1.1 tooling Mar 9, 2017
@markvincze
Copy link

I'm having the same problem when targeting .NET 4.6.
@KallDrexx, did you find any workaround since then?

@dasMulli
Copy link
Contributor

There is an open issue in the SDK repo about it: #335

@markvincze
Copy link

@dasMulli,

Thanks, setting export FrameworkPathOverride=/usr/lib/mono/4.5/ on Ubuntu and Debian solved the issue for me. cc @KallDrexx

@livarcocc
Copy link
Contributor

We will track this in the SDK.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants