question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

csproj class libraries don't copy resource dll's to parent projects output folder

See original GitHub issue

Moving from https://github.com/dotnet/cli/issues/4153 on behalf @ryanbrandenburg.


This is a continuation of aspnet/Home#1707 with a little more information after investigation.

Steps to reproduce

  1. Build the app from the zip in aspnet/Home#1707.
  2. Run the Console Application and verify that it will iterate through the supported cultures and print out “Hello World” in that culture.
  3. Run the Web App and land on the home page. You should see “Hello World” in the culture specified in the request by the browser or the culture specified in the query string. Instead you will always see “Hello World”. There are links on the home page that allow the user to reload the page in one of the supported languages by adding it to the query string. They will all show “Hello World” even though it is clear that the current culture info has changed on the executing thread.
  4. Copy the language folders from the console application into the appropriate location in the web application and reload the page, observing that the non-base localization now works.

This appears to work fine if you create an equivalent class library using project.json.

Expected behavior

Old style class libraries should copy their resource dll’s to the appropriate location, allowing them to localize.

Actual behavior

The resources are not copied, and therefor cannot be used in localization.

Environment data

dotnet --info output: .NET Command Line Tools (1.0.0-preview2-003121)

Product Information: Version: 1.0.0-preview2-003121 Commit SHA-1 hash: 1e9d529bc5

Runtime Environment: OS Name: Windows OS Version: 10.0.10586 OS Platform: Windows RID: win10-x64

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
DanielLabergecommented, Dec 5, 2016

This is quite problematic for us. Any known workaround other than manually copying the files?

We’ll be using a build event to copy the files, but it seems like quite a hack given that the target folder (\bin\Debug\net46\win7-x64) can change from one environment to another.

1reaction
DanielLabergecommented, Dec 6, 2016

So this will not get fixed for VS2015, correct?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Dependent DLL is not getting copied to the build output ...
I have a visual studio solution. I have many projects in the solution. There is one main project which acts as the start...
Read more >
Dependencies of project reference not copied to output ...
NET Standard library to solution and add that library as project ... it not to copy the right transitive dependencies into the bin...
Read more >
Getting .NET Library Projects to Output Dependent Assemblies
NET Core Library projects output dependencies into the build folder. The new behavior doesn't output depdencies, unlike full framework .
Read more >
Change the build output directory - Visual Studio (Windows)
Learn how you can specify the location of output generated by your project on a per-configuration basis (for debug, release, or both).
Read more >
NET Build Improvement: Stop Wasting Resources
Dealing with Nx copies of a DLL is necessarily slower than dealing with a single instance. Case Study: The Roslyn \bin\artifacts directory ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found