Fixes for .NET Portable Library