Change how the registrar calls mtouch a bit, so that we don't use API that
throws an exception with the entire output in the exception message.
The problem is that if the process has a lot of output, XS slows down to a
crawl when showing the exception message in the test result pad.
Instead print the output to the terminal.
* [tests/link sdk] Remove defines that are set by default.
And these defines varies by platform, which means they're not correct for tvOS/watchOS.
* [tests/link sdk] Fix watchOS version check.
* [generator] Explicitly load NSNumber from the api assembly for core builds.
This fixes an issue where we'd run into a type comparison failure otherwise,
when using the `BindAs` attribute in the api definition for our platform
assemblies, because we end up with NSNumber loaded from two different
assemblies:
Foundation.NSNumber, **temp**, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
Foundation.NSNumber, **core**, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
* [generator] Explicitly load NSValue too from the api assembly for core builds.
It looks like mono master has become incompatible, builds now fail with:
error: File '/Users/builder/jenkins/workspace/xamarin-macios-pr-builder/external/guiunit/bin/net_4_5/GuiUnit.exe.mdb' is missing.
make[4]: *** [build-mac-classic-introspection] Error 1
so restrict to C9 only, until we can fix these issues.
Sometimes, when the stars align, fastsim can build an app in less than a
second.
Coupled with the fact that HFS+'s filestamp resolution is 1 second, we can't
assert that filestamps change without making sure enough time passes by.
So sleep for a second.
https://bugzilla.xamarin.com/show_bug.cgi?id=47696
Cecil cannot save an assembly more than once without reloading its
debugging symbols. There was code for this, in the special case where
an assembly could be saved more than once. However the order of the
operations changed and the code to reload symbols was now located too
late.
https://bugzilla.xamarin.com/show_bug.cgi?id=51667
IKVM's API to get attributes does not match System.Reflection's API, so
abstract all we need out to a separate class to make it easier to port it to
IKVM later.
* [XM] Seperate parsing from compilation in AOT code
- Parsing command line options was too entangled with actually compiling
- Refactor test code to centralize Compile, reducing some complexity of tests
- Groundwork for hybrid vs non-hybrid AOT work
* Add hybrid/standard AOT support
* Add xammac_tests to makefile/jenkins
* Add flag to force AOT
* Disable MonoTouchFixtures.Contacts.ContactStoreTest.GetUnifiedContacts on XM due to prompts on Jenkins
* [generator] Add type manager.
`typeof` expressions can't be used with IKVM, so add a type manager that
handles all the type lookup. For now it just uses `typeof`s to find types, but
that'll change to be a string-based lookup instead (which would be IKVM-
compatible).
* [generator] Move the type manager to its own file.
* [generator] Load missing type.
Mono's fork of msbuild uses a `$(_DebugFileExt)` property to specify
the debug file extension (.pdb/.mdb) to use. It defaults to .pdb. So,
with XI/XM, .mdb files don't get copied to the output folder.
We also add a `$(FscDebugFileExt)` property, which allows our default of
`.mdb` to be overridden.
But the `$(_DebugFileExt)` support is not in upstream msbuild yet. So,
we can't ask the F# upstream to add it. Hence, this is being added to
our FSharp target files. Once, all this is upstream, we can remove the
overrides from our files.
Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=51148
If the user makes changes to an App Extension or Watch app,
then those bundles would change within the main app bundle
but the main app bundle would not get re-codesigned because
it was not properly considering those files as inputs in the
_CodesignAppBundle target.
Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=52165
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=52238
If you give mtouch/mmp a linker xml file with bad input for
example a Xamarin.iOS app and the linker.xml has a reference
to Xamarin.Mac instead of X.I.dll i.e.
<?xml version="1.0" encoding="UTF-8" ?>
<linker>
<assembly fullname="Xamarin.Mac">
<type fullname="ObjCRuntime.Constants"/>
</assembly>
</linker>
You will get a not so helpful generic error
MT2001 Could not link assemblies. Reason: Failed to process XML description: <unspecified>
It seems that when you use a xml file for linker you get a
`XmlResolutionException` from cecil when it fails to resolve
and the better error comes from the inner exception so we use
that instead.
New error output for XmlResolutionException:
MT2017: Could not process XML description: Failed to resolve assembly: 'Xamarin.Mac, Culture=neutral, PublicKeyToken=null'
We disabled fastdev for tvOS/watchOS projects with binding projects in
bac02538, and that broke the FastDev_LinkWithTest:
Errors and Failures:
1) Test Failure : Xamarin.MTouch.FastDev_LinkWithTest(TVOS)
Binding symbol not in executable
Expected: no item String ending with " T _theUltimateAnswer"
But was: < ... >
So adjust the test to match the new behavior.
Resource files for mac should be copied to the app bundle
* Move the Satellite code used by mac to tools/common/Assembly.cs
* Add EmbeddedResources test to xammac_tests
Fix NSOpenGLPixelFormat ConvertToAttributes
* Add OpenGLProfile to list of NSOpenGLPixelFormatAttributes that require a value. Check for 0 terminating the array
* Use InitializeHandle instead of 'Handle = '
* Add tests
a. System.Net.Http.Primitives.dll is user code *and* contains type
forwarders (it's like a facade) to another facade assembly,
System.Net.Primitives.dll, that ships with the SDK;
b. The former, System.Net.Http.Primitives.dll, is not processed by
the linker, e.g. no code is removed and the assembly cannot be deleted.
However we save back (as much as we can [1]) the result of any type
being resolved;
c. It also means the later, System.Net.Primitives.dll, is fully linked
and (in many cases) can be removed from the final application (as it's
mostly forwarders).
d. This means the final, re-saved, System.Net.Http.Primitives.dll binary
could point to non-existing metadata, i.e. the removed
System.Net.Primitives.dll, because of [1].
Because we resolve (and save) the forwarders *and* because we do not
allow code downloads or generation (Apple restriction) it is possible to
remove the forwarders, which will fix the issue for XI.
[1] The scope of exported types cannot be updated
abb4e902da/Mono.Cecil/ExportedType.cs (L41)
There is also a enhancement bug, #11165, about this but it predated our
PCL support and the resolve-n-save that we now do for forwarders. This
is now _fully_ fixed.
References:
* https://bugzilla.xamarin.com/show_bug.cgi?id=11165 (enhancement)
* https://bugzilla.xamarin.com/show_bug.cgi?id=51805
The latest Sierra had a few surprises:
* CITextFeature is now 64bits only;
* The MediaPlayer framework is now 64bits only [1]
Both made the classic tests fails for XM.
[1] https://bugzilla.xamarin.com/show_bug.cgi?id=52065
Most projects building to bitcode (any kind of bitcode, this includes the
marker-only version as well), will fail to link when linking with third-party
libraries and incremental builds are enabled.
So automatically disable incremental builds when we detect this scenario.
This is only a workaround until we can make this scenario build correctly.
https://bugzilla.xamarin.com/show_bug.cgi?id=51710