* Pass -Wl,-no_weak_imports to the linker so that we don't accidentally use
symbols weakly. This would cause problems on older OSes where the symbol
isn't there, because our code is not prepared to deal with weakly linked
symbols.
* Manually disable fstatat and readlinkat (introduced with Xcode 7 in iOS 8 /
macOS 10.10), found by the above.
* Manually disable __thread support for a few targets, since mono's configure
script doesn't properly detect it's not supported.
* Manually disable clock_nanosleep, since mono's configure script doesn't
properly detect it's not supported.
* [builds] Don't install symlinks to iOS/Classic assemblies in the iOS/Unified profile.
* [fsharp] Don't install symlinks to iOS/Classic assemblies in the iOS/Unified profile.
The symlinks won't quite work once we remove the iOS/Classic assemblies.
* [C8] Bump to latest Mono 4.6.0 commit
Brings in the netstandard updates from https://github.com/mono/mono/pull/3394
We also had to add a new assembly System.IdentityModel.dll to the mobile profiles while doing that work.
* Add System.IdentityModel to Sdk assemblies
Fixes the following mtouch test failure:
```
Xamarin.Linker.SdkTest.iOS_Classic : BCL
Expected:
But was: < "System.IdentityModel" >
at NUnit.Framework.CollectionAssert.IsEmpty (IEnumerable collection, System.String message, System.Object[] args) <0x47bec88 + 0x00047> in :0
at NUnit.Framework.CollectionAssert.IsEmpty (IEnumerable collection, System.String message) <0x47bec58 + 0x0001f> in :0
at Xamarin.Linker.SdkTest.BCL (System.String path) <0x47bccf0 + 0x003f3> in :0
at Xamarin.Linker.SdkTest.iOS_Classic () <0x47bcc50 + 0x0001b> in :0
```
Brings in the netstandard updates from https://github.com/mono/mono/pull/3394
We also had to add a new assembly System.IdentityModel.dll to the mobile profiles while doing that work.
Since eaf2ceb532 there can be .dll.mdb files
for Facades as well which broke the Facades check.
The fix is to only include files ending in .dll and ignore the others.
Instead of having a symlink of the entire Facades directory for
Unified, we must now create a real directory and symlink each Facade
assembly, because there's one Facade assembly that can't be shared
between Unified and Classic (System.Drawing.Primitives.dll) because
it references monotouch.dll/Xamarin.iOS.dll.
If no sdk version (-sdk_version) is passed to the native
linker, it tries to infer the SDK version from the
path to the -syslibroot argument.
In our case we use a versioned path to Xcode, but a general
symlink without the SDK version:
/Applications/Xcode73.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk
which means ld picked up the Xcode version as the SDK version,
since that's the first number part of the path [1], so we'd
end up with libraries whose SDK version was 73.
So instead use an SDK path with the SDK version, so that ld
finds the SDK version instead of the Xcode version.
[1] 266f4401b9/src/ld/Options.cpp (L4005-L4020)https://bugzilla.xamarin.com/show_bug.cgi?id=41597
watchbcl uses mdb rebase from tools64, but adding a more "correct"
dependency when the mdb rebase occurs causes tools64 to be built
twice simultaneously (probably because we use submakes, so a different
make process also tries to build tools64).
So instead use a bigger hammer and just build tools64 completely
before building watchbcl.