So I have a WPF application that is using Prism Composition to handle modularity. One of my libraries that contains my Prism IModule, references a Portable Class Library. When I attempt to run my WPF application I get the following exception:
An unhandled exception of type 'System.IO.FileNotFoundException' occurred in Microsoft.Practices.Prism.Composition.dll Could not load file or assembly 'System.Runtime, Version=4.0.10.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
This occurs inside the InitializeModules of my UntiyBootstrapper implementation. I am pretty sure this is because Prism is trying to load all the dependencies of the library containing my Prism IModule but I don't quite understand why it can't find that dependency. So far I have tried reinstalling the Windows 8.1 SDK because I read that is where that DLL should reside.
Has anybody else encountered this before or have any suggestions?
Update: I found that if I copy the System.Runtime.dll from this location: "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETCore\v4.5.1" and place it in the same location as my WPF exe then everything runs fine. I don't quite understand why the Prism library can't load this DLL then. Is it a limitation of Prism because I don't see the System.Runtime.dll in the GAC so how does is that dependency normally resolved?