Properly convert COM error codes to C# exceptions

Also use additional information provided by IErrorInfo to fill in
exception details.

To make use of IErrorInfo on Linux a suitable implementation has to be
provided, e.g. by including libcom plus adding a mapping from
oleauth32.dll to the shared library that provides the implementation.

This completes mono bug 496138
(https://bugzilla.novell.com/show_bug.cgi?id=496138)
Set ErrorInfo in Marshal.GetHRForException

Marshal.GetHRForException had a MonoTODO because it needs to set
the errorinfo object so that exceptions get properly passed to
unmanaged code. Since not all managed exceptions have a corresponding
HR value but we might need to get to the original thrown exception
we implement a ManagedErrorInfo helper class that implements the
IErrorInfo interface but also stores the exception.

In GetExceptionForHR we check if the errorinfo we get is a
ManagedErrorInfo. If it is we return the exception stored in there
(if it converts to the same error code), otherwise we construct a new
exception.
KeyPairPresistence now tries to fix folder permissions.
An exception is no longer thrown if the folder permissions can be fixed.
Fixes bug 19274.
Fix scrolling in SWF.ListView.EnsureVisible(int index)

This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=22483
[mdoc] New make test for the --dropns functionality
[mdoc] New make test, reproduces issue with --dropns when run with a secondary assembly that doesn't drop the specified namespace
[mdoc] added -dropns-assemblies parameter.
Will now only replace the namespace when the type or member is in a listed assembly
[mdoc] Formatting feedback from pull #1273
Maximum large object size should be limited by SSIZE_MAX not SIZE_MAX.
The latter appears to be a hangover from 32-bit systems.
[mdoc] consolidated dropns and dropns-assemblies into a single parameter.

Based on pull request feedback, this is a simpler usage, and meets our required use-case. A sample version of this parameter would be: `--dropns MyUnifiedAssembly=MyDroppedPrefix`
Missing setting disposed to true
Missing Args checks.
[System] Add performanceCounters element to System.Diagnostics app.config configuration section

See http://msdn.microsoft.com/en-us/library/ms229387(v=vs.110).aspx for details about the element.
The value that is set by the element isn't currently used in Mono, but applications using it in their app.config crash otherwise (e.g. http://stackoverflow.com/questions/25741651).
[xbuild] Use ToolPath when building ToolTask execution path. Fixes #22981
Fixed NullReferenceException.
Added test for optional {V}Specified and ShouldSerialize{V}.
{V}Specified is a property or field and ShouldSerialize{V} is a method that can be set to false if we do not want to serialize an attribute with name {V}.
Added optional serialization based on ShouldSerialize{V}.
SerializationCodeGenerator and XmlSerializationWriterInterpreter will no longer serialize an attribute named {V} if its object has a method named ShouldSerialize{V}() that returns false.
{V}Specified now is also checked to be true before serializating the attribute even if it is a property that is not settable.
Fixes #1852.
Test serialization wen class has method bool ShouldSerialize<T>().
.NET throws an exception but it should have no effect on the serialization.
Ignore method ShouldSerialize if it is a generic.
Merge pull request #1257 from esdrubal/xmloptional

Added optional serialization based on ShouldSerialize{V}.