I want to recompile System.Web.Optimization to change the cache headers in Bundle.cs (CDN does not like the Vary header), since there appears to be no other way to override the headers. I am able to decompile the source (via Resharper), make the change, and recompile the source just fine but when I add the reference to my project all dependent Nuget packages give an error. Similar to the one below.
The type 'System.Web.Optimization.IBundleBuilder' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Web.Optimization, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
I would rather not have to compile all dependencies. I am also open to other means of overriding the cache headers. HTTPModules, IIS etc.