Граф коммитов

288 Коммитов

Автор SHA1 Сообщение Дата
Rolf Bjarne Kvinge cbaa5890da [builds] More .NET workarounds. 2022-09-06 10:21:43 +02:00
Rolf Bjarne Kvinge d4f5979f3f [dotnet] Skip installing the custom dotnet/runtime workloads when installing on test bots.
It seems to work locally for some reason 🤷‍♂️
2022-09-02 18:42:36 +02:00
Rolf Bjarne Kvinge a0ebd954c3 Bump to dotnet/runtime/release/7.0@608da95f.
Stop relying on dotnet/installer to provide dotnet/runtime bumps.

Ref: https://github.com/xamarin/xamarin-android/pull/7319
2022-09-01 18:39:22 +02:00
Rolf Bjarne Kvinge 5e993ebe49 Merge remote-tracking branch 'origin/main' into net7.0 2022-07-12 11:18:39 +02:00
Rolf Bjarne Kvinge 3751d37a99
[dotnet] Use an arm64-based .NET local install on arm64 machines. Fixes #15375. (#15389)
Fixes https://github.com/xamarin/xamarin-macios/issues/15375.

Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2022-07-11 20:00:53 +02:00
Rolf Bjarne Kvinge ea1419d6fc [dotnet] We don't need to download the nfloat reference assembly anymore. 2022-07-01 11:56:34 +02:00
Rolf Bjarne Kvinge b44632a7dc [dotnet] It doesn't look like we need to download the mono toolchain anymore either. 2022-07-01 11:56:02 +02:00
Rolf Bjarne Kvinge d8eea30918 [dotnet] Remove emscripten dependency.
It doesn't seem to be needed anymore.
2022-07-01 11:54:22 +02:00
Rolf Bjarne Kvinge 352a7cb104 Merge remote-tracking branch 'origin/main' into net7.0 2022-06-30 23:54:10 +02:00
Rolf Bjarne Kvinge 3be1d9d760
Use unix-style line endings in project files. (#15303)
This also removes the BOM in a few project files.

This is a whitespace-only change, as can be seen here: https://github.com/xamarin/xamarin-macios/pull/15303/files?w=1
2022-06-21 17:22:58 +02:00
Rolf Bjarne Kvinge be0f63615e Merge remote-tracking branch 'origin/main' into net7.0 2022-06-13 10:12:57 +02:00
Rolf Bjarne Kvinge 78c7918929
[build] Fix invalid cache management by 'dotnet tool restore'. (#15227)
Fix invalid cache management by 'dotnet tool restore' by deleting 'dotnet tool's cache.
2022-06-09 15:38:59 +02:00
Rolf Bjarne Kvinge db91c70f41 Merge remote-tracking branch 'origin/main' into net7.0 2022-06-07 11:10:24 +02:00
Rolf Bjarne Kvinge a1d0b6eba9
Make our local .NET the default .NET for the build. (#15086)
Make our local .NET the default .NET (in the root's global.json), and then if
a directory wants to use the system .NET, then that directory would have to
opt-in (using its own global.json).

This way we don't have to copy global.json/NuGet.config files around to run
tests with the correct .NET setup.
2022-06-07 10:11:02 +02:00
Rolf Bjarne Kvinge db36bd83c1 Merge remote-tracking branch 'origin/main' into net7.0 2022-05-25 09:34:42 +02:00
Rolf Bjarne Kvinge e3a03d2804
Remove the Visual Studio dependency. (#15102)
Remove our dependency on Visual Studio. Use the 'dotnet-t4' tool instead of
invoking the t4 tool embedded in Visual Studio.

Fixes this build error after installing VS Mac 2022:

> Cannot open assembly '/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/AddIns/MonoDevelop.TextTemplating/TextTransform.exe': No such file or directory.
2022-05-25 08:26:51 +02:00
Rolf Bjarne Kvinge caeb05ec27 Merge remote-tracking branch 'origin/main' into net7.0 2022-04-06 09:03:21 +02:00
Rolf Bjarne Kvinge 969b54b24d
[builds] Don't use DOTNET6_VERSION anymore, it's DOTNET_VERSION. (#14655)
This wasn't caught when we renamed DOTNET6_VERSION to DOTNET_VERSION (probably
because it was in the process of being added in a different PR).
2022-04-05 20:38:53 +02:00
Rolf Bjarne Kvinge c4f0087c98 Merge remote-tracking branch 'origin/main' into darc-main-fc6e47e2-7b69-4464-b65f-8f67ca26b4e8 2022-03-25 09:46:57 +01:00
Rolf Bjarne Kvinge 2dd1c26f0e
[builds] Add a makefile target to print the pkg url for the current .NET we're using. (#14473) 2022-03-25 09:01:04 +01:00
Rolf Bjarne Kvinge cb1189e2fa Merge remote-tracking branch 'origin/main' into darc-main-fc6e47e2-7b69-4464-b65f-8f67ca26b4e8 2022-03-23 09:06:27 +01:00
Rolf Bjarne Kvinge e44d0fd047
[.NET] Rename several DOTNET6_* variables to to DOTNET_*. (#14463)
Also rename DOTNET_VERSION to SYSTEM_DOTNET_VERSION to make it clear what it's
referring to (and to not clash with DOTNET6_VERSION which has now been renamed
to DOTNET_VERSION).

.NET 7 is right around the corner.
2022-03-23 08:07:34 +01:00
Rolf Bjarne Kvinge 5c482c6d23 Try a fix for resolving to the wrong aot compiler. 2022-03-22 17:55:41 +01:00
Rolf Bjarne Kvinge 24eff5d8ff Merge remote-tracking branch 'origin/main' into darc-main-fc6e47e2-7b69-4464-b65f-8f67ca26b4e8 2022-03-22 08:20:30 +01:00
Rolf Bjarne Kvinge e369f466f7
[dotnet] Rename the DOTNET6 make variable to DOTNET. (#14441)
This is the follow-up to where the DOTNET variable was renamed SYSTEM_DOTNET.
2022-03-21 15:56:57 +01:00
Rolf Bjarne Kvinge 3f4cbb5e44 Merge remote-tracking branch 'origin/main' into darc-main-fc6e47e2-7b69-4464-b65f-8f67ca26b4e8 2022-03-11 14:34:02 +01:00
Rolf Bjarne Kvinge bd97933b60
[runtime] Remove ObjCRuntime.nfloat in favor of System.Runtime.InteropServices.NFloat. (#14197)
* Remove ObjCRuntime.nfloat (in favor of   System.Runtime.InteropServices.NFloat).
* Automatically add a reference to the System.Runtime.InteropServices.Internal
  package, so that developers get the new NFloat API (with operators) we've
  added post .NET 6 (but don't do this for .NET 7).
* Automatically add a global using alias for
  System.Runtime.InteropServices.NFloat -> nfloat. This is not behind the
  usual `ImplicitUsings` condition our other implicit usings are, because
  they're off by default for existing projects, and the main target for the
  global using alias for nfloat is upgraded projects.
* Automatically generate a global using alias (like above) in the generator
  for all code the generator compiles.
* Update xtro entries to reference System.Runtime.InteropServices.NFloat
  instead of ObjCRuntime.nfloat.
* Add a workaround for a hopefully temporary issue with .NET/CoreCLR where the
  wrong runtime pack is selected otherwise (without the new NFloat API, so
  nothing works at runtime).

Ref: https://github.com/xamarin/xamarin-macios/issues/13087
2022-02-24 16:51:12 +01:00
Rolf Bjarne Kvinge c0074d0c79
[dotnet] Hardcode the version band instead of inferring it. (#14225) 2022-02-23 20:43:27 +01:00
Rolf Bjarne Kvinge da50fd46fc Bumpetibumpbumpbump 2022-02-21 20:59:09 +01:00
dotnet-maestro[bot] 1273190e5f
[main] Update dependencies from dotnet/installer (#14156)
* Update dependencies from https://github.com/dotnet/installer build 20220211.11

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.201-servicing.22111.7 -> To Version 6.0.300-preview.22111.11

Dependency coherency updates

Microsoft.NET.ILLink.Tasks
 From Version 6.0.200-1.22069.1 -> To Version 6.0.100-1.21519.4 (parent: Microsoft.Dotnet.Sdk.Internal

* Update dependencies from https://github.com/dotnet/installer build 20220216.1

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.201-servicing.22111.7 -> To Version 6.0.300-preview.22116.1

Dependency coherency updates

Microsoft.NET.ILLink.Tasks
 From Version 6.0.200-1.22069.1 -> To Version 6.0.100-1.21519.4 (parent: Microsoft.Dotnet.Sdk.Internal

* Use the preview csc.

* Hardcode the toolchain version band to 6.0.200 for now.

* Bump dotnet/runtime to get nfloat changes.

* Add a dependency on Microsoft.NET.Workload.Emscripten.Manifest-6.0.100, and use it.

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2022-02-17 15:29:41 +01:00
dotnet-maestro[bot] 60e9d7bbb6
[main] Update dependencies from dotnet/runtime (#13648)
* Update dependencies from https://github.com/dotnet/runtime build 20220104.8

Microsoft.NETCore.App.Ref
 From Version 6.0.2-mauipre.1.21622.4 -> To Version 6.0.2-mauipre.1.22054.8

* [builds] Remove hardcoded Microsoft.NET.Workload.Mono.ToolChain.Manifest version.

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2022-01-11 07:21:19 +01:00
dotnet-maestro[bot] 298c8089e8
[main] Update dependencies from dotnet/installer (#13561)
This pull request updates the following dependencies

## From https://github.com/dotnet/installer

- **Subscription**: 9d0987bd-c9b3-4f3a-a267-08d9ba6248b0
- **Build**: 20211215.3
- **Date Produced**: December 15, 2021 9:16:41 PM UTC
- **Commit**: 2dc0c5a0c9e30b861916e288676dc81d09ec9454
- **Branch**: refs/heads/release/6.0.2xx

- **Updates**:
  - **Microsoft.Dotnet.Sdk.Internal**: [from 6.0.102-servicing.21609.9 to 6.0.200-preview.21614.17][3]

[3]: 65bbb44...0ce201e

---

# .net ChangeLog for https://github.com/xamarin/xamarin-macios/pull/13561
## Level 1
* https://github.com/dotnet/installer [65bbb44...0ce201e](65bbb444f8...0ce201ed68)

## Level 2
* https://github.com/dotnet/templating [7d94161...7c35333](7d94161304...7c35333b66)
* https://github.com/dotnet/sdk [2c798cb...4a935da](2c798cbf6b...4a935da067)
* https://github.com/dotnet/fsharp [6d626ff...c12acdb](6d626ff075...c12acdbfa5)
* https://github.com/microsoft/vstest [68bd10d...a809880](68bd10d3ae...a809880e02)
* https://github.com/dotnet/roslyn [c7d6f9f...8183134](c7d6f9fab8...8183134263)
* https://github.com/dotnet/msbuild [c9eb9dd...96a618c](c9eb9dd64e...96a618ca59)
* https://github.com/nuget/nuget.client [078701b...9187a50](078701b97e...9187a50dae)
* https://github.com/dotnet/arcade [ee9b7f1...7421b55](ee9b7f1985...7421b55f46)
* https://github.com/dotnet/source-build-reference-packages [897a970...9c7c56c](897a9709eb...9c7c56c010)

Generated using https://github.com/spouliot/dotnet-tools/tree/master/changelog

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-12-16 17:35:17 +01:00
Rolf Bjarne Kvinge cc75748c90 [builds] Download & install the Mono workload as well. 2021-12-07 20:59:52 +01:00
Rolf Bjarne Kvinge d0da8354cd Download the correct .NET runtime version. 2021-12-07 11:33:33 +01:00
Rolf Bjarne Kvinge 88eb5e1ac8
Rename any *OSX_SDK_VERSION variables to *MACOS_SDK_VERSION. (#13411)
This makes it easier to iterate over all the *_SDK_VERSION variables in
template code, because they're all named using the standard platform names we
use elsewhere.
2021-11-22 18:48:05 +01:00
Manuel de la Pena d9f7e3b224
[CI] Allow to pass extra args to the donet install. (#12910) 2021-10-02 11:48:35 -04:00
Rolf Bjarne Kvinge 2972e1b715
Fix some whitespace issues in various files. (#12399)
* Remove BOM
* Add EOL at end of file.
2021-08-11 10:06:46 +02:00
Rolf Bjarne Kvinge ad7d08a63d
Always create binlogs during the build. (#12331)
On CI we'll collect all the binlogs in the repository and make them available
for post-build analysis if need be, so this will make it easier to diagnose
build problems.
2021-08-04 09:30:16 +02:00
dotnet-maestro[bot] 68476989f4
[main] Update dependencies from dotnet/installer (#12245)
* Update dependencies from https://github.com/dotnet/installer build 20210727.4

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-rc.1.21376.3 -> To Version 6.0.100-rc.1.21377.4

Dependency coherency updates

Microsoft.NET.ILLink.Tasks
 From Version 6.0.100-preview.6.21370.1 -> To Version 6.0.100-preview.6.21376.2 (parent: Microsoft.Dotnet.Sdk.Internal

* Bump Mono.Cecil from 0.11.3 to 0.11.4.

* [dotnet-linker] Reference Mono.Cecil 0.11.4 directly.

Works around https://github.com/mono/linker/issues/2173.

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-07-28 09:46:36 +02:00
Rolf Bjarne Kvinge 732c27afb3
[builds] Use the dotnet-install.sh script to install .NET locally. (#12050)
Hopefully this will solve issues with random curl errors (56) that happens
when trying to download .NET (and which break the build randomly).
2021-06-30 14:02:12 -04:00
Rolf Bjarne Kvinge aa7e9d06d1
[configure] Add option to use a locally built dotnet/runtime. (#11643)
* Add a configure option to use a locally built dotnet/runtime.
* Add documentation how to build dotnet/runtime the way we need it built.
* Modify our build to consume the custom dotnet/runtime if so configured.

This is useful when trying to debug the runtime locally, or trying out new
features there are no packages for yet.

Co-authored-by: TJ Lambert <50846373+tj-devel709@users.noreply.github.com>
2021-05-21 22:18:25 +02:00
Rolf Bjarne Kvinge 6225cac669
[msbuild/dotnet] Fix build logic when using .NET to not try to use nor require any version of installed Xamarin.iOS/Xamarin.Mac. Fixes #10827. (#11433)
* [dotnet] Ship the buildinfo file.

* [msbuild/dotnet] Fix build logic when using .NET to not try to use nor require any version of installed Xamarin.iOS/Xamarin.Mac. Fixes #10827.

We do this by setting the _XamarinSdkRoot variable in our .NET logic, which
our existing shared build logic reads, passes to the DetectSdkLocations task,
and then sets our override environment variable
(MD_MTOUCH_SDK_ROOT/XAMMAC_FRAMEWORK_PATH) to the install location, so that
existing code (which honors the override variable) continues to work as-is.

Fixes https://github.com/xamarin/xamarin-macios/issues/10827.
2021-05-04 21:36:48 -04:00
dotnet-maestro[bot] e8f437319a
[main] Update dependencies from dotnet/installer (#11175)
* Update dependencies from https://github.com/dotnet/installer build 20210408.1

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21208.1

* Update dependencies from https://github.com/dotnet/installer build 20210409.4

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21209.4

* Update dependencies from https://github.com/dotnet/installer build 20210410.1

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21210.1

* same P4 specific fix as ccb43cba56
but the ICU support was added based on P3 but merged after ^

* Update dependencies from https://github.com/dotnet/installer build 20210412.5

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21212.5

* Update dependencies from https://github.com/dotnet/installer build 20210413.70

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21213.70

* Update dependencies from https://github.com/dotnet/installer build 20210414.14

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21214.14

* Update to new package names

Thanks @pjcollins for the heads up https://github.com/xamarin/xamarin-macios/pull/11175#issuecomment-819936692

* Update dependencies from https://github.com/dotnet/installer build 20210415.1

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21215.1

* Fix build (path changed to include '.mono')

* remove more '.mono' special case that are not needed anymore

* Update dependencies from https://github.com/dotnet/installer build 20210415.12

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21215.12

* Fix building apps (it now finds the native libs)

Credits to @filipnavara

8325f8dadc

* Add back IsTrimmable (or nothing gets linked)

* Update dependencies from https://github.com/dotnet/installer build 20210418.6

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.3.21202.5 -> To Version 6.0.100-preview.4.21218.6

* Keep downloading the CoreCLR runtime packs.

* [runtime] Adjust the build to link with the correct runtime library for CoreCLR.

* [tests][monotouch-test] Ignore NSTimeZoneTest / All_28300 on dotnet as it hangs

Introduced with https://github.com/dotnet/runtime/pull/48931

Issue https://unicode-org.atlassian.net/browse/ICU-21591
PR https://github.com/unicode-org/icu/pull/1699

* [dotnet][msbuild] Add more (missing) '\'

Fix satellite/location assemblies and some unit tests

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Alex Soto <alex@alexsoto.me>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
Co-authored-by: Sebastien Pouliot <sebastien.pouliot@microsoft.com>
Co-authored-by: Sebastien Pouliot <sebastien.pouliot@gmail.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-04-20 09:09:56 -04:00
Rolf Bjarne Kvinge c8b6bc6c85
[dotnet] Build macOS/.NET for ARM64 as well. (#10959)
Partial fix for #10959.
2021-03-25 07:26:48 +01:00
mathieubourgeois a921ee2fb1
Xamarin.Mac native Apple Silicon targetting support (#10115)
* Add support for Xamarin.Mac arm64

* Add compile product definition task

Xamarin.Mac can be provided with a ProductDefinition file for the generated pkg. Normally, providing a product definition was optional. However, with Apple Silicon, we have an extra issue : `productbuild` needs to know what architectures your package target. If not provided with them, it will guess to the best of its abilities. However, on Catalina and lower, the guess is x86_64, even if you have an arm64 slice. To fix this, we add a new task to compile the product definition and use this file to create the pkg. If you provide your own Product Definition, we can check and warn if the architectures don't match what we expect. If the file doesn't exist or there is no architecture, we set it ourselves based on our target architectures.

* Don't reference dynamic objC_send on arm64

When building in debug, we currently try to link dynamic objC_send symbols when targeting a 64-bit architecture. However, this is actually only defined on Intel architectures, not on arm64, so we end up failing because we're referring symbols that don't exist. Rework the `GetRequiredSymbols` to take an abi, and tag those symbols to only be valid on i386/x86_64, so they don't get referred at all when building on arm64, but still get referred in x86_64.

* Fix improper delete/move with already existing directories

* Fix stret requirement for Xamarin.Mac in arm64.

The generator supposes that we're running in x64 mode, refactor to take into account the possibility of running in arm64.

* Implement OS version generation in Product.plist, based on MinimumSystemVersion of the app

* Re-generalize some mmp registrar rules

`Microsoft.macOS.registrar` was missed by the current rule set

* Fix mmp tests

* Set E7072 as not translated

Tests were failing otherwise

* Rename Xamarin.Mac lib/x86_64 folder to 64bits (currently all targeted archs are the same)

* Fix style issues

* Fix `ToLower` usage for invariant usage

* Fix xtro-sharpie test
2021-03-17 21:48:02 -04:00
Rolf Bjarne Kvinge e53176383e
[builds] Remove the code to optionally inject an x64 slice into our binaries. (#10846)
It's been disabled for a while, which indicates that Apple has fixed the issue
on their side, and we don't need this code anymore.
2021-03-12 07:38:07 +01:00
mathieubourgeois 480d168287
Fix building Mono MacCatalyst sdk from source (#10824)
Currently, if building from source, we don't actually try to build the mac catalyst sdk, but we rely on its presence to do the install, which is problematic. Now package it like we do for ios & mac packages. Also adapted MacCatalyst assembly fix to work if we build from source instead of supposing we work from a downloaded package.
2021-03-10 22:51:35 +01:00
Rolf Bjarne Kvinge bf7c3268bc
[dotnet] Use the reference assemblies from the .NET 6 version we're referencing. (#10813) 2021-03-09 14:57:56 +01:00
Rolf Bjarne Kvinge f06e4a2e06
[builds] We have mac catalyst packs now. (#10766) 2021-03-03 17:55:46 +01:00
Rolf Bjarne Kvinge e84984a883
[builds] Remove debug code. (#10670) 2021-02-22 08:20:35 +01:00
Rolf Bjarne Kvinge 946f92dca6
[builds] Download the runtime packs for our platforms. (#10671)
These will soon be used to build a .NET version of libxamarin (we need the
dylibs shipped with the runtime packs to link libxamarin.dylib).

We also write out the version of the runtime packs
(BundledNETCorePlatformsPackageVersion) so that we can use the version later
in our Makefiles.
2021-02-22 08:16:41 +01:00
Rolf Bjarne Kvinge f127e614c9
[dotnet] Templateify some build logic. (#10618)
* [dotnet-linker] Templateify the install logic.

* [builds] Templateify the Versions.plist install logic.

* [dotnet] Create a per-platform Versions.props file with only the values applicable to that platform.

Also move the definition of the default TargetPlatformVersion to Make.versions, where we have other versions.

* [dotnet] Templateify some build code.
2021-02-11 20:17:12 +01:00
Rolf Bjarne Kvinge 28791b6e2a
[builds] Create the cache directory if needed. (#10372) 2021-01-11 16:25:56 +01:00
Rolf Bjarne Kvinge 15a2ebc2b7 [builds] Add a tool that fixes Mac Catalyst BCL assemblies.
The BCL assemblies we're using for Mac Catalyst for now are the ones built for Xamarin.iOS.
So we need to fix: InternalsVisibleToAttribute (to point to Xamarin.MacCatalyst.dll)
and references to Xamarin.iOS.dll
2020-12-03 10:43:19 +01:00
Rolf Bjarne Kvinge 42687be5d5 [tools] OS Versions are messy in Mac Catalyst 😡
In some places we have to provide the macOS version, and in other places the
iOS version. Add a map and the corresponding code to convert between the two,
and use them when needed.
2020-12-03 10:43:19 +01:00
Rolf Bjarne Kvinge 14f89da787 [builds] Install the Mac Catalyst BCL assemblies 2020-12-03 10:42:25 +01:00
Rolf Bjarne Kvinge 0a2d8f3e5f [builds] Install the catalyst libraries from the mono archive 2020-12-03 10:42:25 +01:00
Rolf Bjarne Kvinge 03e010c747 Bump mono to a version that ships catalyst binaries and download those binaries.
New commits in mono/mono:

* mono/mono@dfbfe5eed1 [2020-02] Build makefile to support Mac Catalyst (#20566)

Diff: ac596375c7..dfbfe5eed1
2020-12-03 10:42:25 +01:00
Rolf Bjarne Kvinge c640775699 [dotnet] Bump to .NET 6.0.100-alpha.1.20556.2. and net6.0
New commits in spouliot/Touch.Unit:

* spouliot/Touch.Unit@f8768d9 Advance into the world of net6.0

Diff: 9abe69e6f5..f8768d99ef
2020-11-10 11:41:06 +01:00
Rolf Bjarne Kvinge f8b66658c5
[build] Implement support for optionally cache downloads in ~/Library/Caches/xamarin-macios. (#9894)
Set the MACIOS_CACHE_DOWNLOADS environment variable in ~/.zshrc, and enjoy
faster builds! Until your hard disk fills up...
2020-10-19 10:50:27 +02:00
Rolf Bjarne Kvinge d825679d20
[system-dependencies] Only use the locally installed .NET version. (#9885)
* [system-dependencies] Only use the locally installed .NET version.

We'll soon need to install files into the dotnet directory, and we don't want
to do that to the system dotnet. So just always use a locally installed .NET.

* Rework to not treat .NET 5 as an optional/installable dependency, instead download it always (like the mono archive).

This way no manual action is necessary to get it when needed, it will be
downloaded automatically.
2020-10-16 08:23:22 +02:00
Rolf Bjarne Kvinge 39e3184f02
[src] Build the .NET version of our product assemblies using a .NET 5 BCL. (#9637)
* [src] Build the .NET version of our product assemblies using a .NET 5 BCL.

We're not shipping the .NET product assemblies in any stable release, so we
can use a preview version of the .NET 5 BCL.

Also:

* Add all the nuget feeds we need to the top-level NuGet.config, even for .NET
  5/6, there shouldn't be any conflicts with stable feeds since we use exact
  version numbers.

* Generate a top-level global5.json which is copied to every directory that
  needs a .NET 5 global.json (overriding the .NET 3.1 global.json in the root
  directory).

* Use the expected dotnet binary during our local build.

* [tests] Fix the bgen tests to use .NET 5.

* [xharness] Set the current directory to the project directory when running .NET tests.

This way we end up using the dotnet version that's configured in global.json for the tests.
2020-09-21 13:22:44 +02:00
Rolf Bjarne Kvinge 4add0c9f47
A few minor improvements to speed up rebuilds. (#8597)
* There's no need to check the system when running 'make install', we already
  checked it during 'make all'.
* Remove the 'download-mono' dependency for the .stamp-download-mono target,
  since that makes the .stamp-download-mono target always out of date (since
  there will never be a 'download-mono' file). Instead execute the
  'download-mono' target manually. This fixes an issue where running 'make
  all' repeatedly would continue doing the same stuff over and over again.
2020-05-14 16:45:23 +02:00
Rolf Bjarne Kvinge 5834572741
Create and publish .NET NuGet packages. (#8576)
Create the various NuGet packages to support .NET 5+. The packages are
currently empty (and not very useful), but the actual content will come later.

The current set of NuGet packages are (this list is duplicated for each
platform: iOS, tvOS, watchOS and macOS):

* Microsoft.iOS.Sdk: currently contains the basic MSBuild targets files for an
  MSBuild Project SDK. Will eventually contain all the build logic. Might also
  eventually contain other tools (mlaunch, bgen, etc.), but these might also
  end up in a different package.
* Microsoft.iOS.Ref: will contain the Xamarin.iOS.dll reference assembly.
* Microsoft.iOS.Runtime.[RID]: will contain architecture-specific files
  (libxamarin*.dylib, the Xamarin.iOS.dll implementation assembly, etc.):

The NuGets built on CI are automatically published to a NuGet feed.

The versioning for the NuGet packages required a few changes: OS bumps are now
changed in Make.versions instead of Make.config (this is explained in the
files themselves as well).
2020-05-13 15:23:29 +02:00
Rolf Bjarne Kvinge 5f786dead4
[builds] Fix generation of the smcs script. (#8581)
This regressed in c517281f1c.
2020-05-13 08:49:26 +02:00
Rolf Bjarne Kvinge e4f8460277
[mmp/mtouch] Share more code. (#8394)
* Rearrange files in Xamarin.Mac a bit to ease code sharing between mmp and
  mtouch, by putting mono's static and dynamic libraries in
  /Library/Frameworks/Xamarin.Mac.framework/Versions/Current/Sdks/Xamarin.macOS.sdk
  to match how Xamarin.iOS does it.

* Don't use 'usr' as an intermediate directory. This removes another special
  case.

* Share many of the functions and properties that return specific directories,
  and document (as comments) what each function/property is supposed to
  return.
2020-04-16 14:19:45 +02:00
Alex Soto 3ff3e07ebe Merge remote-tracking branch 'xamarin/d16-5-xcode11.4' 2020-03-26 19:59:14 -04:00
Rolf Bjarne Kvinge eef4ea79c9 [builds] Download the netcore 3.1 assemblies to use as reference assemblies for .NET 5.
I couldn't figure out how to make nuget install these into the system, so I
decided to just download the package locally instead.

This is just temporary until we get real .NET 5 reference assemblies.
2020-03-09 18:43:41 +01:00
Alex Soto 709a90599e Merge remote-tracking branch 'xamarin/xcode11.4' into d16-5-xcode11.4-merge 2020-03-03 10:57:24 -05:00
Rolf Bjarne Kvinge feb5e96c2a
Rename bmac-mobile-mono to mono-sgen. (#7966)
bmac-mobile-mono is an old name (when we needed a specific executable to
execute bmac) that has nothing to do with its current usage (AOT code for
Xamarin.Mac apps).

So rename the executable to reflect current usage.

This makes looking at the installed files a bit less confusing.
2020-02-25 06:51:12 +01:00
Rolf Bjarne Kvinge c53b17d79b
Make the x86-64 slice we inject into binaries optional. (#7891)
We inject an x86-64 slice into binaries that don't contain one, because
Apple's notarization process fails without such a slice.

But make the slice optional and opt-in, because it seems Apple has started
to fail on binaries with such a slice now...
2020-02-14 14:25:43 +01:00
Rolf Bjarne Kvinge c517281f1c
Make the smcs script obsolete, and don't use it in tests anymore. (#7878)
Don't remove the entire script, because I believe there's code out there that
checks for the existence of the smcs script to determine whether Xamarin.iOS
is installed or not.
2020-02-13 08:37:52 +01:00
Rolf Bjarne Kvinge 999ba8e278
[builds] Make sure downloaded files have a newer timestamp than any other file from previous builds. (#7833)
This makes sure we actually use the new files we downloaded.
2020-02-10 22:30:52 +01:00
monojenkins b85e70fa66 [d16-5] [Mtouch] Make sure that the given SDK version and the iOS version do match. (#7736)
* [Mtouch] Make sure that the given SDK version and the iOS version do match.

We need to make sure that the iOS SDK and the iOS version do match the
ones present in Xcode.

* Add new variables to track the target version.
* Add method to get the target version.
* Modify mtouch to check agains the target framework rather than the
SDK.

This will allow to keep track of three independent things:

1. The SDK max version.
2. The Simulator max version.
3. The target version of the device.

This had to be added becuase 13.2 has targets to 13.2 but simulators for
13.3

Fixes: https://github.com/xamarin/xamarin-macios/issues/7705
2020-01-23 12:56:23 -05:00
Manuel de la Pena 8d83ec2bca
[Mtouch] Make sure that the given SDK version and the iOS version do match. (#7717)
We need to make sure that the iOS SDK and the iOS version do match the
ones present in Xcode.

* Add new variables to track the target version.
* Add method to get the target version.
* Modify mtouch to check agains the target framework rather than the
SDK.

This will allow to keep track of three independent things:

1. The SDK max version.
2. The Simulator max version.
3. The target version of the device.

This had to be added becuase 13.2 has targets to 13.2 but simulators for
13.3

Fixes: https://github.com/xamarin/xamarin-macios/issues/7705
2020-01-22 10:57:27 -05:00
Vincent Dondain fd3f86d912 Bump to mono:2019-10 (#7192) (#7547)
* Fixed
`/Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/builds/mono-ios-sdk-destdir/ios-sources/external/linker/src/linker/Linker.Steps/OutputStep.cs(110,15): error CS0246: The type or namespace name ‘OutputException’ could not be found (are you missing a using directive or an assembly reference?) [/Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/tools/mmp/mmp.csproj]`
* Changed the name of the method that is used from linker. Because of this commit 6be26771b9
* Added `OutputException.cs` file on `mtouch.csproj`.
* Removing enter_gc_safe and exit_gc_safe because now it's already gc_safe in this part of code, after a mono change.
* Added known exceptions to LLVM exception list.
* Needs `ifdef` because of this https://github.com/mono/mono/pull/17260.
* Bump MIN_MONO_VERSION to 6.8.0.41 and point MIN_MONO_URL to the PR.
* Add ENABLE_IOS=1 and ENABLE_MAC=1.
* Added switch to disable packaged mono build
* [Tests] Ignore tests that fail on 32b.
    Ignore the test on 32b, and filled issue: https://github.com/mono/mono/issues/17752
* [Tests] Ignore a couple of tests causing OOM.
    Hopefully fixes https://github.com/xamarin/maccore/issues/1659 for good.
* Ignore `MM0135` test on Catalina+ because it needs Xcode 9.4.
* [monotouch-test] Add null checks for teardown when test didn't run because of a too early OS version.
* [CFNetwork]: Http 2.0 requires OS X 10.11 or later.
    Check whether `_HTTPVersion2_0` is available and fallback to HTTP 1.1 otherwise.

* #7346
* This bumps Mono to use https://github.com/mono/mono/pull/17645 (which is the 2019-10 backport
of https://github.com/mono/mono/pull/17628).
* The big user-visible change is in regards to certificate validation, everything below are just
some minor adjustments to tests.

CoreFX uses a completely new `HttpClientHandler` implementation called `SocketsHttpHandler`,
which you can find at https://github.com/dotnet/corefx/tree/release/3.0/src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler.

Since this is not based on the web stack anymore, it does not use any of the related APIs such
as `ServicePointManager` or `WebException`.

There is a new API called `HttpClientHandler.ServerCertificateCustomValidationCallback`.
- https://docs.microsoft.com/en-us/dotnet/api/system.net.http.httpclienthandler.servercertificatecustomvalidationcallback?view=netframework-4.8
- c1778515a3/src/System.Net.Http/src/System/Net/Http/HttpClientHandler.Unix.cs (L154)
- c1778515a3/src/System.Net.Http/src/System/Net/Http/HttpClientHandler.Windows.cs (L383)

The `ServicePointManager.ServerCertificateValidationCallback` is no longer invoked and on
certificate validation failure, `AuthenticationException` (from `System.Security.Authentication`)
is thrown instead of `WebException`.

At the moment, the `NSUrlSessionHandler` still uses it's own validation callback and also still
throws `WebException` on failure; we should probably look into making this consistent with the
other handlers.

* `HttpContent.SerializeToStreamAsync()` is now `protected` (changed from `protected internal`).
  - src/Foundation/NSUrlSessionHandler.cs: changed overload accordingly.
  - src/System.Net.Http/CFContentStream.cs: likewise.

* `HttpHeaders.GetKnownHeaderKind()` is an internal Mono API.
   There is a new internal API called `System.Net.Http.PlatformHelper.IsContentHeader(key)`
   which exists in both the old as well as the new implementation.
   The correct way of doing it with the CoreFX handler is
   `HeaderDescriptor.TryGet (key, out var descriptor) && descriptor.HeaderType == HttpHeaderType.Content`

* `HttpClientHandler.MaxRequestContentBufferSize` is now longer supported, you can set it to
  any non-negative value, the getter will always return 0.
  See c1778515a3/src/System.Net.Http/src/System/Net/Http/HttpClientHandler.Core.cs (L18).
  - tests/linker/ios/link sdk/HttpClientHandlerTest.cs: removed assertion from test.

* `HttpMessageInvoker.handler` is a `protected private` field - in the CoreFX handler, it is
  called `_handler` and `private`.  This is accessed via reflection by some of the tests, which are
  now using the new name.
  - tests/mmptest/src/MMPTest.cs: here
  - tests/mtouch/MTouch.cs: here

* tests/monotouch-test/System.Net.Http/MessageHandlers.cs:
  Adjust `RejectSslCertificatesServicePointManager` to reflect the certificate validation
  changes described above.
  - FIXME: There was an `Assert.Ignore()` related to `NSUrlSessionHandler` and macOS 10.10;
    I removed that to reenable the test because the description linked to an old issue in
    the private repo that was referenced by several "Merged" PR's, so it looked to me that
    this might have already been fixed - and I also didn't see why it would fail there.
2019-12-18 11:40:47 -05:00
Alexander Köplinger 7bc1903f80 Bump mono to latest 2019-10 (#7574)
New commits in mono/mono:

* mono/mono@9bcfa60312 [2019-10] Bump msbuild to track mono-2019-10 (#18132)
* mono/mono@e6cd9a15cd [2019-10] [mini] Fix delegate trampoline virtual call via delgate Invoke (#18115)
* mono/mono@7c95e4bc48 [debugger] skip suspend for unattached threads (#18111)
* mono/mono@77147e7526 [2019-10] Bump msbuild+roslyn to track mono-2019-10 (#18093)
* mono/mono@d7337e5beb Bump to mono/corefx@f3815a9 (#18104)
* mono/mono@6ac11972db [2019-10] [threads] Add back mono_threads_attach_tools_thread as a public API (#18075)
* mono/mono@b687667619 Bump corefx to pick up https://github.com/mono/corefx/pull/370 (#18068)
* mono/mono@da605d8081 Remove DNS lookups of the local hostname in tests (#18059)
* mono/mono@a6e867fe96 Bump msbuild to track mono-2019-10 (#18045)
* mono/mono@3387bd4a26 Bump bockbuild to get https://github.com/mono/bockbuild/pull/136
* mono/mono@5dd74a60e8 Fix side effect.
* mono/mono@a36f07c803 Fix DIM in a generic interface. Fixes #17869
* mono/mono@08e5a9751a Bump msbuild to track mono-2019-10 (#18014)
* mono/mono@56a583ea5c [2019-10] [profiler] disable inlining when coverage profiler is used and fix allocation sizes (#17991)
* mono/mono@914ffea421 [sgen] Don't trigger collections during allocation of thread objects (#17997)

Diff: 18920a83f4..9bcfa60312
2019-12-13 11:59:16 -05:00
Jo Shields 5d4ada34c7 Bump to mono:2019-10 (#7192)
## Miscellaneous fixes

* Fixed
`/Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/builds/mono-ios-sdk-destdir/ios-sources/external/linker/src/linker/Linker.Steps/OutputStep.cs(110,15): error CS0246: The type or namespace name ‘OutputException’ could not be found (are you missing a using directive or an assembly reference?) [/Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/tools/mmp/mmp.csproj]`
* Changed the name of the method that is used from linker. Because of this commit 6be26771b9
* Added `OutputException.cs` file on `mtouch.csproj`.
* Removing enter_gc_safe and exit_gc_safe because now it's already gc_safe in this part of code, after a mono change.
* Added known exceptions to LLVM exception list.
* Needs `ifdef` because of this https://github.com/mono/mono/pull/17260.
* Bump MIN_MONO_VERSION to 6.8.0.41 and point MIN_MONO_URL to the PR.
* Add ENABLE_IOS=1 and ENABLE_MAC=1.
* Added switch to disable packaged mono build
* [Tests] Ignore tests that fail on 32b.
    Ignore the test on 32b, and filled issue: https://github.com/mono/mono/issues/17752
* [Tests] Ignore a couple of tests causing OOM.
    Hopefully fixes https://github.com/xamarin/maccore/issues/1659 for good.
* Ignore `MM0135` test on Catalina+ because it needs Xcode 9.4.
* [monotouch-test] Add null checks for teardown when test didn't run because of a too early OS version.
* [CFNetwork]: Http 2.0 requires OS X 10.11 or later.
    Check whether `_HTTPVersion2_0` is available and fallback to HTTP 1.1 otherwise.

## Bring HttpClient from CoreFX

* #7346 
* This bumps Mono to use https://github.com/mono/mono/pull/17645 (which is the 2019-10 backport
of https://github.com/mono/mono/pull/17628).
* The big user-visible change is in regards to certificate validation, everything below are just
some minor adjustments to tests.

### SocketsHttpHandler

CoreFX uses a completely new `HttpClientHandler` implementation called `SocketsHttpHandler`,
which you can find at https://github.com/dotnet/corefx/tree/release/3.0/src/System.Net.Http/src/System/Net/Http/SocketsHttpHandler.

Since this is not based on the web stack anymore, it does not use any of the related APIs such
as `ServicePointManager` or `WebException`.

### Certificate Validation Changes

There is a new API called `HttpClientHandler.ServerCertificateCustomValidationCallback`.
- https://docs.microsoft.com/en-us/dotnet/api/system.net.http.httpclienthandler.servercertificatecustomvalidationcallback?view=netframework-4.8
- c1778515a3/src/System.Net.Http/src/System/Net/Http/HttpClientHandler.Unix.cs (L154)
- c1778515a3/src/System.Net.Http/src/System/Net/Http/HttpClientHandler.Windows.cs (L383)

The `ServicePointManager.ServerCertificateValidationCallback` is no longer invoked and on
certificate validation failure, `AuthenticationException` (from `System.Security.Authentication`)
is thrown instead of `WebException`.

At the moment, the `NSUrlSessionHandler` still uses it's own validation callback and also still
throws `WebException` on failure; we should probably look into making this consistent with the
other handlers.

### Minor adjustments related to internal Mono APIs

* `HttpContent.SerializeToStreamAsync()` is now `protected` (changed from `protected internal`).
  - src/Foundation/NSUrlSessionHandler.cs: changed overload accordingly.
  - src/System.Net.Http/CFContentStream.cs: likewise.

* `HttpHeaders.GetKnownHeaderKind()` is an internal Mono API.
   There is a new internal API called `System.Net.Http.PlatformHelper.IsContentHeader(key)`
   which exists in both the old as well as the new implementation.
   The correct way of doing it with the CoreFX handler is
   `HeaderDescriptor.TryGet (key, out var descriptor) && descriptor.HeaderType == HttpHeaderType.Content`

### Minor adjustments to tests.

* `HttpClientHandler.MaxRequestContentBufferSize` is now longer supported, you can set it to
  any non-negative value, the getter will always return 0.
  See c1778515a3/src/System.Net.Http/src/System/Net/Http/HttpClientHandler.Core.cs (L18).
  - tests/linker/ios/link sdk/HttpClientHandlerTest.cs: removed assertion from test.

* `HttpMessageInvoker.handler` is a `protected private` field - in the CoreFX handler, it is
  called `_handler` and `private`.  This is accessed via reflection by some of the tests, which are
  now using the new name.
  - tests/mmptest/src/MMPTest.cs: here
  - tests/mtouch/MTouch.cs: here

* tests/monotouch-test/System.Net.Http/MessageHandlers.cs:
  Adjust `RejectSslCertificatesServicePointManager` to reflect the certificate validation
  changes described above.
  - FIXME: There was an `Assert.Ignore()` related to `NSUrlSessionHandler` and macOS 10.10;
    I removed that to reenable the test because the description linked to an old issue in
    the private repo that was referenced by several "Merged" PR's, so it looked to me that
    this might have already been fixed - and I also didn't see why it would fail there.
2019-12-04 15:10:32 -05:00
Bernhard Urban-Forster d5ff125555 [build] fix Makefile around x86-64-slice (#7219)
* [build] fix Makefile around x86-64-slice

a7fd4552dc was slightly wrong, it should have broken all tests around notarization (which are presumably not done for PRs).

Also adding a missing dependency.

* typo

* $(suffix $@) does not work when specified as dependency

* update .gitignore

* Update builds/Makefile

Co-Authored-By: Rolf Bjarne Kvinge <rolf@xamarin.com>
2019-10-15 08:16:24 +02:00
Bernhard Urban-Forster a7fd4552dc [build] lipo x86-64-slice into libs according to their kind (#7217)
The result of `lipo`ing `.a`s and `.dylib`s together is not well defined.
In this specific case, using `lipo` on `libmonosgen-2.0.a` to inject `x86-64-slice.dylib` resulted into `dsymutil` (run by `mtouch` when building the app) not finding the proper debug information anymore.

Also putting the dummy slice into a file and adding `-ggdb3` to avoid those warnings:

```console
$ dsymutil ./_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/MonoTouch.iphoneos.sdk/usr/lib/libmonosgen-2.0.dylib
warning: (x86_64) /var/folders/p3/5279mmgn1p575bz28j0ngfqw0000gn/T/--19c1b5.o unable to open object file: No such file or directory
warning: no debug symbols in executable (-arch x86_64)
```
2019-10-11 07:08:42 +02:00
monojenkins d45ad36c66 Bump mono to 2019-08@528103728fc2aedb7b6062e11255d39a0ed3f31c to add missing NS2.1 APIs (#7150)
See https://github.com/mono/mono/issues/17064.

The 2019-08 version of the fix adds a new assembly with NS2.1 APIs that we stubbed out in 2019-06: System.Data.DataSetExtensions.dll
2019-10-02 08:08:41 -04:00
Alexander Köplinger fb1f73ef57 Bump mono to 2019-08@528103728fc2aedb7b6062e11255d39a0ed3f31c to add missing NS2.1 APIs (#7147)
See https://github.com/mono/mono/issues/17064.

The 2019-08 version of the fix adds a new assembly with NS2.1 APIs that we stubbed out in 2019-06: System.Data.DataSetExtensions.dll
2019-10-02 07:59:39 -04:00
Bernhard Urban 26ec2826aa ARM64_32 Debug Mode (#7012)
* [builds] add arm64_32 cross compiler

* [mtouch] force --interpreter on arm64_32 debug mode build

* [mtouch] include debug check for arm64_32 and reflect error codes in documentation
2019-09-24 17:24:49 +02:00
Rolf Bjarne Kvinge 2adecee3d9
Drop the Xcode 9.4 dependency. (#7044)
* Drop the Xcode 9.4 dependency.

Also bump mono to get the removal of the mac32 binaries.

New commits in mono/mono:

* mono/mono@70d6903053 [2019-08] [merp] Use a separate program as the hang supervisor. (#16900)
* mono/mono@4bff2b6370 [offsets-tool] Install clang into the user-specific python directory.
* mono/mono@81894ec8ca Implement WriteCore and ReadCore in DeflateStream
* mono/mono@bfbf823ca1 [ci] Remove more XCODE32_DIR usages (#16964)
* mono/mono@ce01b20a4d Add net_4.8.xml to EXTRA_DIST and bump binary-reference-assemblies again
* mono/mono@7a587d7fa6 Add .NET 4.8 reference assemblies (#16912)
* mono/mono@35e454a8f6 [sdks] Remove the mac32 build. (#16936)
* mono/mono@75eb342f53 [2019-08] [System] Make FileSystemWatcher backend non-static (#16926)
* mono/mono@5881981f79 [2019-08] [mini] Add missing membars when initializing rgctx entries (#16909)
* mono/mono@6290b6cd6e Temporarily disable embedded ppdb data decompression (#16911)
* mono/mono@a0e7f9eaf2 [2019-08] [arm64_32] make "Debug Mode" work on Watch series 4 with --interpreter (#16886)
* mono/mono@6275840a7f Rename bundle identifier for the various Mono.frameworks we create for Xamarin.iOS. Fixes xamarin/xamarin-macios#7005. (#16901)
* mono/mono@25f6093283 [corlib] Fix building nunit-lite twice (#16895)
* mono/mono@7ec17ba1be [2019-08] [android sdk] Add aprofutil tool (#16884)
* mono/mono@f755f3b539 [metadata] Fix leaks when handling a few attributes (#16850)
* mono/mono@5f9a2db39b [2019-08] Fix infrequent hangs in test-runner. (#16854)
* mono/mono@f31f5ea1f1 [2019-08] [threads] do not convert NULL thread name (#16828)
* mono/mono@20308e6f87 [aot] Do not wrap tool_prefix path when calling strip (#16820)
* mono/mono@cecda47c48 [aprofutil] Add -p and -f options
* mono/mono@824cc12ac3 Bump to mono/corefx@e79cf5b
* mono/mono@b77dc06a7e [aprofutil] Install the tool correctly (#16112)
* mono/mono@1848d78d60 [aotprof-tool] Initial import of AOT profiler tool (#15384)
* mono/mono@da0086e304 [2019-08] Add RenamedEvent* to FSW sources from CoreFX (#16756)
* mono/mono@0297b21b03 [msbuild][roslyn] Bump msbuild and roslyn to pull in new versions (#16768)
* mono/mono@40631e3b9e [2019-08] [aot] move method_addresses to data.rel.so section to avoid text relocations (#16751)
* mono/mono@68b77674e2 Vtable [i] can be null so this should be check before use it. Fixes #16712
* mono/mono@4a0b4f41ed [mini] publish global patches after JitInfo has been added
* mono/mono@7a1f63fde6 [debugger][android] It was not initialising seq_points on MonoCompile on Android, so when was compiling dynamic methods, seq_points wasn't created and we got the assert when try to single step.

Diff: 29b1ac19c9..70d6903053

* [tests] Add a fat macOS dylib for testing purposes.

Add a binary version of a fat macOS dylib (because we can't create one when we
need it since we can't create 32-bit slice anymore).

It was created like this (in tests/test-libraries):

	$ cat test.m
	int theUltimateAnswer ()
	{
		return 42;
	}

	$ /Applications/Xcode94.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang test.m -olibtest.i386.dylib -shared -isysroot /Applications/Xcode94.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk -framework Foundation -framework CoreLocation -lz  -arch i386
	$ lipo -create libtest.i386.dylib .libs/macos/libtest.dylib -output libtest-fat.dylib

* [tests] Adjust XM tests to XM not having fat dylibs anymore.

* [tests] Adjust product tests to some libraries not being fat anymore.

* One more test fix.
2019-09-24 13:40:18 +02:00
Rolf Bjarne Kvinge f40261a502
[builds] Stop shipping the 32-bit AOT compiler for Xamarin.Mac. (#7039) 2019-09-20 15:39:39 +02:00
Rolf Bjarne Kvinge d1d620291a Don't build the XM and the XI toolchains at the same time, they're not parallel safe. Works around mono/mono#16821.
Ref: https://github.com/mono/mono/issues/16821
2019-09-16 15:26:47 +02:00
Rolf Bjarne Kvinge 664bb077e2 Fix downloading mono archive when running device tests. 2019-09-16 15:11:49 +02:00
Rolf Bjarne Kvinge a4ab788428 Mono's build said to bump ulimit, so let's do that. 2019-09-16 14:30:59 +02:00
Rolf Bjarne Kvinge 303aa0a649 Merge remote-tracking branch 'origin/xcode11' into master-xcode11 2019-09-13 18:35:18 +02:00
Vincent Dondain aac92a1c20
Update Versions info for iOS/tvOS 12.3 & 12.4 + watchOS 5.3 (#6945)
- Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/959179
- Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/956758

* Actually 12.3 & 12.4 are still on the 12.2 SDK

* Turns out our version plist check is assuming max version supported = max sdk version
2019-09-10 10:12:26 -04:00
Rolf Bjarne Kvinge 0008c20abf
Implement notarization. (#6928)
* Add a dummy x86_64 slice to all our native libraries that don't have one. (#6848)

Apple's notarization tool has a bug where they incorrectly flag Mach-O
binaries without an x86_64 slice, so make sure all our libraries have one.

* Jenkinsfile notarization (#6869)

* Add in notarization script for xamarin.mac/xamarin.iOS

* Flatten the list to get rid of the braces

* Add in keychain password

* Add login.keychain back in to access codesigning certificates

* Always sign pkgs, upload notarized copies

* Enable ios notarization and make notarized pkgs public

* Make notarization non-fatal

* Publish GH statuses for notarized PKGs

* Don't forget to declare URI variables for notarized pkgs

* report proper package links

* [jenkins] Improve package reporting.

* Use dummy function name which our tests won't complain about.
2019-09-09 00:34:11 -07:00
Rolf Bjarne Kvinge a9abc07cb3
Rename bundle identifier for the frameworks we ship. Fixes #6920. (#6926)
Rename the bundle identifier for the frameworks we ship, because apparently
Apple has added an App Store check to reject apps with multiple frameworks
with the same bundle identifier.

For some reason that includes rejecting frameworks that are both in iOS and
watchOS apps. This feels like a bug on Apple's end, but we can still easily
work around it, so let's do just that.

Strictly speaking it's not necessary to change the bundle identifier for tvOS
frameworks, but it's more consistent that way.

Fixes https://github.com/xamarin/xamarin-macios/issues/6920.
2019-09-06 09:30:49 -07:00
Rolf Bjarne Kvinge 17b81b8a61
[builds] Set a different min watchOS version for arm64_32 architectures. (#6868)
This fixes a confusion with how mono builds libmono-native for watchOS, so we
can simplify our makefiles a little bit.

Ref: https://github.com/xamarin/xamarin-macios/pull/5465/files#r266486349
Ref: ce5ba1e41d (commitcomment-33834491)
2019-08-29 03:52:01 -07:00
Rolf Bjarne Kvinge f3fbbd7047
Add a dummy x86_64 slice to all our native libraries that don't have one. (#6848)
Apple's notarization tool has a bug where they incorrectly flag Mach-O
binaries without an x86_64 slice, so make sure all our libraries have one.
2019-08-26 09:51:50 -07:00
Jo Shields a29ae8e6df Bump to mono:2019-06 (#6196)
* Use the commonly used casing for `MSBuildSDKsPath` property

Handle "incorrectly" cased msbuild property names

msbuild property names are case insensitive. While generating the custom
app.config, in `SetToolsetProperty(..)` we try to update the property if
it already exists. But the name lookup was case sensitive, thus causing
the lookup to fail, resulting in two entries for the same property name
differing only in case. Eg. `MSBuildSDKsPath` vs `MSBuildSdksPath`.

* [mtouch] Whitelist new Brotli native symbols in Xamarin.Tests.Misc.PublicSymbols test

* [mtouch] Better assert in NoLLVMFailuresInWatchOS() test

We'd list the "LLVM failed" messages before even though the AOT might've crashed and the list is meaningless. Assert the exit code before that.

* [mtouch] Use new LLVM even for 32bit targets

See https://github.com/mono/mono/issues/14841 and https://github.com/mono/mono/issues/9621

* [mtouch] Work around slow LLVM in "don't link" test

See https://github.com/mono/mono/issues/14843

* Remove useless conditional

* Remove LLVM36 from Makefile

* [watch4] set right min version for arm64_32 based watch devices (#6307)

Fixes the confusion around `libmono-native*` (see for example ce5ba1e41d (commitcomment-33834491) ) when building with `MONO_BUILD_FROM_SOURCE=1`.

* reflect watchos64_32_version_min change from mono sdk

* Move mono hash info to mk/mono.mk so that existing scripts work.

* Add Makefile dependency on mono.mk where necessary

With 3e7bc29ade the Mono hash was moved from Make.config to mono.mk.

We need to add a Makefile dependency on this file wherever Make.config was used to track a Mono dependency.

* [tests] Copy mk/mono.mk to the XM test package.

* [tests] Update minOS version test after consolidating min watchOS versions everywhere.

Fixes this mtouch and mmptest failure:

    1) Failed : Xamarin.Tests.ProductTests.MinOSVersion(watchOS,MinwatchOS,WatchOSSimulator,False)
      Failures
      Expected: <empty>
      But was:  < "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (mono-runtime-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (bindings-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (bindings-generated-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (shared-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (runtime-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (trampolines-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (trampolines-invoke-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (xamarin-support-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (nsstring-localization-debug.arm64_32.o).", "Unexpected minOS version (expected 2.0.0, alternatively 2.0.0, found 5.1.0) in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchSimulator.sdk/usr/lib/libxamarin-debug.a (trampolines-varargs-debug.arm64_32.o)."... >

* [mmp] Fix make clean target

It needs an -r to remove directories:

```
rm: bin: is a directory
rm: obj: is a directory
```

* Add new xamarin_timezone_get_local_name() to a few more places
2019-07-16 17:24:00 +02:00
Rolf Bjarne Kvinge 04d4f1a2b3
[xcode11][builds] Build the BCL test assemblies. Fixes #6261. (#6380)
* [builds] Build the BCL test assemblies. Fixes #6261.

Build the BCL test assemblies and copy them where xharness expects them to be.

Fixes https://github.com/xamarin/xamarin-macios/issues/6261.

* [builds] Copy nunitlite.dll to where it's expected too.
2019-06-20 18:13:43 +02:00
Rolf Bjarne Kvinge 7bd9f76272
[builds] Fix non-parallel make issues. (#6360)
Building in non-parallel mode revelead and issue where a required directory
would not exist when needed. Fixed by creating the required directory when
needed.
2019-06-19 16:10:04 +02:00
Alexander Köplinger b05c9cb5ab Fix from-source Mono build not generate proper dependencies (#6225)
The .deps.mk target didn't get generated because its dependency was wrong.

Also do not exclude tests from the dependencies, they should be rebuild when changed too.

Fixes #6224
2019-06-11 19:05:11 +02:00
Vincent Dondain e0dda4d109 Fixed source build issue
We were hitting this:

```
fatal error: /Applications/Xcode11-beta1.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't open input file: /Users/vidondai/Documents/xi-xcode11/xamarin-macios/builds/install/targetwatch64_32/tmp-lib/libmono-native-unified.dylib (No such file or directory)
make[2]: *** [/Users/vidondai/Documents/xi-xcode11/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/SDKs/Xamarin.WatchOS.sdk/usr/lib/libmono-native-unified.dylib] Error 1
```
2019-06-04 16:22:11 -04:00
Rolf Bjarne Kvinge 75359b53ca More source build adjustments 2019-06-04 11:33:49 -07:00