Why two Microsoft.Practices.Unity.dll libraries in Nuget package?

May 19, 2014 at 5:06 AM
Hi there,

In the Prism.UnityExtensions nuget package, there is the file Microsoft.Practices.Unity.dll in two different folders.
The folder names are called 'net45' and 'portable-net45+wp80+win8+MonoAndroid10+MonoTouch10'

Why are there two different folders with exactly the same file (same name, same verison number and filesize) ? The reason I ask is that I'm using Prism 5.0 Windows 7 .NET4.5 and am confused.

May 19, 2014 at 5:38 PM
Hello jack123,

What version of the Prism.UnityExtensions nuget package are you using? I just grabbed the version 5.0.1 and it only has a folder for net45.

May 19, 2014 at 5:55 PM
Hi jack123,

I think I see the issue. You actually mean the Unity 3.5 nuget package. It has 4 folders (net45, portable-net45+wp80+win8+MonoAndroid10+MonoTouch10, win8, and wp80. Let me check with the Unity team.

May 19, 2014 at 10:47 PM
It's the same binary, but there are additional assemblies which are platform specific for using the registration by convention feature. So there needs to be platform-specific folders with the shared binary and the specific ones to take precedence over the pcl folder, which only contains the shared binary. Are you having any issues with the package?. Since nugget packages are in a compressed format there should not be a very big difference in size due to the duplication.
May 23, 2014 at 9:30 PM
Hi Manikrish,

I'm not having any issues with it's use; my question is more discussion-based (rather than a specific 'issue').
I was really wanting to know which version I should reference in my projects when using the Microsoft Prism5 Library when using Unity 3.5 on Windows 7.

Thanks for answering - it looks like I use the version of Microsoft.Practices.Unity.dll from the 'net45' folder, and when I go to Windows 8, etc, I'll use the Microsoft.Practices.Unity.dll from the 'portable-net45+wp80+win8+MonoAndroid10+MonoTouch10' folder.