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

1381 Коммитов

Автор SHA1 Сообщение Дата
Mauro Agnoletti 6bc66bf2ee
Ensure we restore the temp csproj to compute AOT compiler path (#16280)
The build command doesn't support a parameter to specify a NuGet.config, so we need to restore the temp project first, so we pass the NuGet.config file to use the sources from, in case it exists (e.g: the NuGet.config from the XMA dotnet path).

This is useful to support auhtorized NuGet feeds

Fixes Bug #1611102 - [XVS][MAUI] Failed to build .NET MAUI (net6.0) with iOS Simulator: https://dev.azure.com/devdiv/DevDiv/_workitems/edit/1611102

Co-authored-by: GitHub Actions Autoformatter <github-actions-autoformatter@xamarin.com>
2022-10-07 08:16:01 +02:00
Rolf Bjarne Kvinge fb97063227 Merge main into net7.0. 2022-10-06 14:01:27 +02:00
Rolf Bjarne Kvinge 45b97d838e Merge main into xcode14.1. 2022-10-06 13:59:29 +02:00
Rolf Bjarne Kvinge 96d7b958b6
[msbuild] Fix processing static libraries in binding sidecars. (#16227)
Fixes an issue where we'd end up trying to link with the managed assembly instead:

> ld: warning: ignoring file .../bin/Debug/net6.0-ios/MyBinding.dll, building for iOS Simulator-x86_64 but attempting to link with file built for unknown-unsupported file format ( 0x4D 0x5A 0x90 0x00 0x03 0x00 0x00 0x00 0x04 0x00 0x00 0x00 0xFF 0xFF 0x00 0x00 )

Also add a warning if we run into other types of libraries in the future to
make it easier to diagnose.
2022-10-05 08:40:20 +02:00
Rolf Bjarne Kvinge c7badeacf1 Merge main into xcode14.1. 2022-10-04 16:21:54 +02:00
Rolf Bjarne Kvinge 8b247307ab Merge main into net7.0. 2022-09-30 14:02:34 +02:00
Rolf Bjarne Kvinge 513355602d
[msbuild] Make DetectSigningIdentity.CodesignEntitlements an ITaskItem property. (#16174)
This way XVS will copy the corresponding file to the mac during a build.

Fixes this error:

Target Name=_DetectSigningIdentity
Project=C:\Users\admin\source\repos\iOSApp4\iOSApp4\iOSApp4.csproj
        DetectSigningIdentity
Assembly = C:\Program
Files\dotnet\packs\Microsoft.iOS.Sdk\16.0.515\tools\msbuild\iOS\..\iOS\Xamarin.iOS.Tasks.dll
            Parameters
                AppBundleName = iOSApp4
                BundleIdentifier = com.companyname.iOSApp4
                CodesignEntitlements = Entitlements.plist
                RequireCodeSigning = False
                SdkIsSimulator = True
                SdkPlatform = iPhoneSimulator
                SessionId = ...
TargetFrameworkMoniker = .NETCoreApp,Version=v6.0,Profile=ios
DetectSigningIdentity: 2022-09-28T04:17:13.3947732-07:00 - Started
DetectSigningIdentity: 2022-09-28T04:17:13.3947732-07:00 - Initializing
[xma][info]: Trying to get a Build Connection for Session '...':
Xamarin.Messaging.Build.Client.BuildConnection...., Lifetime: AppDomain
DetectSigningIdentity: 2022-09-28T04:17:13.3947732-07:00 - Initialized
DetectSigningIdentity: 2022-09-28T04:17:13.3957722-07:00 - There's no
available inputs to copy to the Mac
DetectSigningIdentity: 2022-09-28T04:17:13.3957722-07:00 - Serializing
intputs
DetectSigningIdentity: 2022-09-28T04:17:13.4077719-07:00 - Executing
[xma][info]: Starting remote task execution for 'iOSApp4':
Xamarin.MacDev.Tasks.DetectSigningIdentity
[xma][info]: Sending Request
Xamarin.Messaging.Build.Contracts.ExecuteTaskMessage to topic
xvs/build/execute-task/iOSApp4/01e0050002fDetectSigningIdentity
[xma][err]: An error occurred on the receiver while executing a post for
topic xvs/build/execute-task/iOSApp4/01e0050002fDetectSigningIdentity
and client
build01e0050ee064bdc5af5fe8d051898268699b25ed1eeec849023e711753e8d82d6484admin
[xma][info]: An error occurred while executing the operation. The Build
Server connection is active and running so no retries will be attempted.
            Errors
C:\Program
Files\dotnet\packs\Microsoft.iOS.Sdk\16.0.515\tools\msbuild\iOS\Xamarin.Shared.targets(1699,3):
MessagingRemoteException: An error occurred on client Build while
executing a reply for topic
xvs/build/execute-task/iOSApp4/01e0050002fDetectSigningIdentity
FileNotFoundException: Could not find file
"/Users/vstester/Library/Caches/Xamarin/mtbs/builds/iOSApp4/.../Entitlements.plist"
     [C:\Users\admin\source\repos\iOSApp4\iOSApp4\iOSApp4.csproj]
DetectSigningIdentity: 2022-09-28T04:17:13.4631033-07:00 - Finished

Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1635214.
2022-09-30 09:33:33 +02:00
Rolf Bjarne Kvinge ed612dcd6e Merge main into net7.0. 2022-09-28 17:17:10 +02:00
Rolf Bjarne Kvinge 7cc91e0c53 Merge main into xcode14.1. 2022-09-28 17:14:31 +02:00
Rolf Bjarne Kvinge 9e0fecc4ff
Autoformat msbuild projects. (#16132)
All other changes should be blank space only: https://github.com/xamarin/xamarin-macios/pull/16132/files?w=1

Co-authored-by: GitHub Actions Autoformatter <github-actions-autoformatter@xamarin.com>
2022-09-28 16:25:35 +02:00
Rolf Bjarne Kvinge b6d484e3c4
Remove Xamarin.Analysis. (#16149)
It's not used by anyone anymore, and there are better alternatives for .NET.

This removes a dependency on a private component, which makes a potential move
into the dotnet org easier.
2022-09-28 16:25:07 +02:00
VS MobileTools Engineering Service 2 823c5ba8ec
[main] [6.0.4xx] [msbuild] Use _TrimmerDefaultAction if TrimmerDefaultAction isn't set. (#16130)
The .NET 7 linker targets will set _TrimmerDefaultAction instead of
TrimmerDefaultAction, so if TrimmerDefaultAction isn't set (which it
will be
for .NET 6), then use _TrimmerDefaultAction (which should be set for
.NET 7).

Unfortunately for .NET 8 it seems I've misplaced my crystal ball, so
we'll
have to wait a bit to see what happens then.

Ref: https://github.com/xamarin/xamarin-macios/issues/16125.

Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1621047.


Backport of #16126

Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2022-09-26 19:49:48 -04:00
Rolf Bjarne Kvinge 9c3458dc33 Merge main into xcode14.1. 2022-09-26 22:46:59 +02:00
Rolf Bjarne Kvinge 56165a77ec Merge main into net7.0. 2022-09-26 22:44:48 +02:00
Rolf Bjarne Kvinge 8a915601ef
[msbuild] Add a public 'CompileImageAssetsDependsOn' property. Fixes #16065. (#16089)
Add a public 'CompileImageAssetsDependsOn' property, so that MAUI can inject tasks that
must be completed before we compile image assets:

```xml
<PropertyGroup>
	<CompileImageAssetsDependsOn>
		$(CompileImageAssetsDependsOn);
		ResizetizeCollectItems;
	</CompileImageAssetsDependsOn>
</PropertyGroup>
```

Fixes https://github.com/xamarin/xamarin-macios/issues/16065.
2022-09-23 16:29:40 +02:00
Rolf Bjarne Kvinge b82b1685a7
Use Environment.SpecialFolder.UserProfile, not SpecialFolder.Personal. (#16017)
Context: dotnet/runtime#68610
Context: https://github.com/xamarin/xamarin-android-tools/commit/0be567a9

In Mono and .NET prior to .NET 8, the
[`System.Environment.SpecialFolder`][0]`.Personal` enum value would refer to
`$HOME` on Unix platforms.

This will be changing in .NET 8, such that
`Environment.SpecialFolder.Personal` will instead refer to
`$XDG_DOCUMENTS_DIR` (if set) or `$HOME/Documents`.  This is for "semantic
compatibility" with .NET on Windows.

Replace usage of `Environment.SpecialFolder.Personal` with
`Environment.SpecialFolder.UserProfile`, so that our code continues to work as
expected under .NET 8.

[0]: https://docs.microsoft.com/en-us/dotnet/api/system.environment.specialfolder?view=net-6.0
2022-09-23 16:29:19 +02:00
VS MobileTools Engineering Service 2 85d73a0328
[main] Fixed Build Agent (#16086)
The Build Agent is a console app so it can't target netstandard.
Changing it back to net472 for now

Backport of #16083

Co-authored-by: Mauro Agnoletti <maagno@microsoft.com>
2022-09-23 07:08:07 +02:00
Rolf Bjarne Kvinge 15e9683a53 Bump main in net7.0. 2022-09-22 07:55:18 +02:00
Rolf Bjarne Kvinge f4d5e6eeab Merge main into xcode14.1. 2022-09-22 07:50:58 +02:00
Rolf Bjarne Kvinge 52a332cb9b
[dotnet/msbuild] Add support for skipping/adding items (and bundles) to be signed. Fixes #15594. (#15894)
Add support for two new MSBuild item groups:

* CodesignBundle: lists additional app bundles inside the main bundle which should
  be signed (typically manually copied into the app bundle by the developer).
* SkipCodesignItems: lists files we'd sign by default, but which shouldn't be signed.

Fixes https://github.com/xamarin/xamarin-macios/issues/15594.
2022-09-21 11:38:03 +02:00
Rolf Bjarne Kvinge 4215eae4a3 Merge main into xcode14.1. 2022-09-16 18:35:48 +02:00
Rolf Bjarne Kvinge 40b3831bc7 Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-09-16 2022-09-16 18:32:01 +02:00
Emanuel Fernandez Dell'Oca 4b49ddda8f
[msbuild] Hot Restart fixes (#15979)
Adds missing css files needed on Maui Blazor apps and avoids copying unnecessary files into the bundle (overdue task since the .NET migration).

Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2022-09-16 17:31:04 +02:00
Rolf Bjarne Kvinge 5a613f7c86 Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-09-15 2022-09-15 09:30:29 +02:00
Rolf Bjarne Kvinge 5fda07d3f3 Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14.1-2022-09-15 2022-09-15 09:29:28 +02:00
Rolf Bjarne Kvinge 40199966b6
[msbuild] Automatically add the 'com.apple.security.cs.allow-jit' entitlement for desktop release builds. Fixes #15745. (#15927)
* Add support for specifying custom entitlements with an MSBuild item group.
* Use this new support to automatically add the 'com.apple.security.cs.allow-jit'
  entitlement to .NET desktop apps when building for release, since all apps that
  go through notarization will need it in order to be able to use the JIT.

It's possible to override the default behavior by adding something like this to the project file:

    <ItemGroup>
        <CustomEntitlements Include="com.apple.security.cs.allow-jit" Type="Remove" />
    </ItemGroup>

Fixes https://github.com/xamarin/xamarin-macios/issues/15745.
2022-09-13 17:41:22 +02:00
Rolf Bjarne Kvinge 7df80a40da
[msbuild] Remove MS7068 so allow creating binding projects without native libraries. Fixes #15489. (#15926)
Fixes https://github.com/xamarin/xamarin-macios/issues/15489.
2022-09-13 17:40:43 +02:00
Rolf Bjarne Kvinge f93e5fba12 Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14-2022-09-13 2022-09-13 11:00:35 +02:00
Rolf Bjarne Kvinge dea88f7fed Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-09-13 2022-09-13 10:59:01 +02:00
Rolf Bjarne Kvinge d769fa99cc
[msbuild] Only require a provisioning profile if we have non-empty entitlements. (#15918)
This is the behavior in legacy Xamarin (for mobile projects): if a project
contains a CodesignEntitlements=Entitlements.plist property, we require a
provisioning profile (and failing the build if none is found).

In .NET, the expected behavior is that if a file is in the project directory,
it should be detected automatically and handled accordingly. We didn't do this
for the initial release of .NET, but we implemented it later
(https://github.com/xamarin/xamarin-macios/pull/15729).

However, this turned out to be complicated, because many templates provide an
Entitlements.plist file, and now suddenly just the presence of such a file
would require a provisioning profile, which also means setting up the whole
rigmarole of Apple's certificates and provisioning profiles (and even
potentially getting a paid Apple Developer account).

This usually worked well in legacy Xamarin, because in templates only the
Release configuration would set the CodesignEntitlements=Entitlements.plist
property, and thus we'd only require a provisioning profile for release builds
(and the Entitlements.plist file would be ignored for Debug builds).

Here we change the default behavior when building for .NET so that we only
require a provisioning profile if the Entitlements.plist file is empty (i.e.
doesn't request any entitlements).

I've also implemented an override, where setting the
CodesignRequireProvisioningProfile=true property will override our default
logic.

Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1613459.
2022-09-13 10:51:41 +02:00
Mauro Agnoletti 1731c5c0dc
Updated Xamarin.Messaging to 1.7.14 (#15913) 2022-09-13 10:40:44 +02:00
Rolf Bjarne Kvinge 17821f0585 Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-09-12 2022-09-12 11:28:02 +02:00
Rolf Bjarne Kvinge 68eb7d401f Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14-2022-09-12 2022-09-12 11:27:02 +02:00
Rolf Bjarne Kvinge b353c21108
[msbuild] Enable nullability in the CompileEntitlements task. (#15912)
Also remove the 'MergeProfileEntitlements' property, since its value is always
'true' and thus the property is redundant.
2022-09-12 11:21:44 +02:00
Rolf Bjarne Kvinge b6cdde4280
[msbuild] Add support for keeping temporary output when looking for AOT compilers. (#15884) 2022-09-09 17:10:50 +02:00
Rolf Bjarne Kvinge 7e20a09b28
[msbuild] Ignore MSB3246 in Xamarin.iOS.Tasks.Windows to avoid a warning about a dll which isn't an assembly. (#15887) 2022-09-09 17:10:41 +02:00
Rolf Bjarne Kvinge 9f0b794d28 Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-09-09 2022-09-09 16:55:20 +02:00
Rolf Bjarne Kvinge 9bca30dce6 Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14-2022-09-09 2022-09-09 16:54:19 +02:00
Rolf Bjarne Kvinge 316d371d83
[msbuild] Use 'netstandard2.0' as the target framework in every project. (#15796)
Fixes this compiler warning:

    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(1733,5): warning : ProjectReference 'xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj' was resolved using '.NETFramework,Version=v4.7.2' instead of the project target framework '.NETStandard,Version=v2.0'. This project may not be fully compatible with your project. [xamarin-macios/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj]
2022-09-09 13:22:16 +02:00
Rolf Bjarne Kvinge 2558c98c7c
[msbuild] Take the .NET version into account when computing the illink.dll location. (#15876)
We use illink.dll from the executing .NET version: if we're building with .NET
7, then we're using illink from .NET 7. This means we can't hard-code 'net6.0'
when computing the path to illink.dll for remote builds.

Fixes https://devdiv.visualstudio.com/DefaultCollection/DevDiv/_workitems/edit/1611403.
2022-09-07 21:10:25 +02:00
Rolf Bjarne Kvinge 62bc02760a
[msbuild] Compute _AppContainerDir from AppBundleDir if AppBundleDir is set by the developer. Fixes #15014. (#15869)
Fixes https://github.com/xamarin/xamarin-macios/issues/15014.
2022-09-07 11:33:39 +02:00
Rolf Bjarne Kvinge ea4b193303 Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-09-07 2022-09-07 10:57:58 +02:00
Rolf Bjarne Kvinge 433c48a35e Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14-2022-09-07 2022-09-07 10:56:00 +02:00
Rolf Bjarne Kvinge f31f53f849
[msbuild] Make sure '_AppBundlePath' is always relative. Fixes #15130. (#15868)
_AppBundlePath is relative by default, but if AppBundleDir is set to an
absolute path (or the root path used to compute AppBundleDir is an absolute
path), then we must ensure _AppBundlePath is still a relative path, because
our code depends on this.

Note that there are no tests for this, because:

* The problem is that our code concatenates a path + _AppBundlePath.
* This works fine on macOS, because it still looks like a valid path.
* It does not work fine on Windows, because the resulting path ends up with a
  drive letter in the middle.
* We currently don't have any tests on Windows.

Fixes https://github.com/xamarin/xamarin-macios/issues/15130.
2022-09-07 10:42:30 +02:00
Rolf Bjarne Kvinge 40298d2cf5
[msbuild] Ignore NU1701 in Xamarin.iOS.Tasks.Windows to avoid a BouncyCastle warning. (#15864) 2022-09-07 10:39:24 +02:00
Rolf Bjarne Kvinge 95d728304b
[msbuild] Add additional app extensions to the list of items we need to sign. Fixes #15598. (#15829)
* Add additional app extensions to the list of items we need to sign.
* Improve msbuild test for additional app extensions:
    * Build for both device and simulator.
    * Hopefully fix the signing problems that occurred on the bots last time we tried.
    * Assert that both the container and extension are signed during the build when we build for device.

A 10-line fix with 3300 lines of tests...

Fixes https://github.com/xamarin/xamarin-macios/issues/15598.
2022-09-07 10:39:05 +02:00
Rolf Bjarne Kvinge 6b5ce1401f
[msbuild] Ignore MSB3246 in a few places. (#15851)
Fixes:

    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277: Found conflicts between different versions of "System.Reflection.Metadata" that could not be resolved. [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277: There was a conflict between "System.Reflection.Metadata, Version=1.4.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" and "System.Reflection.Metadata, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a". [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     "System.Reflection.Metadata, Version=1.4.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" was chosen because it was primary and "System.Reflection.Metadata, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" was not. [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     References which depend on "System.Reflection.Metadata, Version=1.4.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" [xamarin-macios/packages/system.reflection.metadata/1.6.0/lib/netstandard2.0/System.Reflection.Metadata.dll]. [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         xamarin-macios/packages/system.reflection.metadata/1.6.0/lib/netstandard2.0/System.Reflection.Metadata.dll [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "xamarin-macios/packages/system.reflection.metadata/1.6.0/lib/netstandard2.0/System.Reflection.Metadata.dll". [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             xamarin-macios/packages/system.reflection.metadata/1.6.0/lib/netstandard2.0/System.Reflection.Metadata.dll [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     References which depend on "System.Reflection.Metadata, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" []. [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         xamarin-macios/packages/microsoft.net.illink.tasks/6.0.200-1.22219.3/tools/net472/ILLink.Tasks.dll [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "xamarin-macios/packages/microsoft.net.illink.tasks/6.0.200-1.22219.3/tools/net472/ILLink.Tasks.dll". [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             ILLink.Tasks [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277: Found conflicts between different versions of "System.IO.Compression" that could not be resolved. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277: There was a conflict between "System.IO.Compression, Version=4.1.3.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" and "System.IO.Compression, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     "System.IO.Compression, Version=4.1.3.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" was chosen because it was primary and "System.IO.Compression, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" was not. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     References which depend on "System.IO.Compression, Version=4.1.3.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" [xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.IO.Compression.dll]. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.IO.Compression.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.IO.Compression.dll". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.IO.Compression.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     References which depend on "System.IO.Compression, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" []. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Build.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Build.dll". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             Microsoft.Build [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             Xamarin.iOS.Tasks [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Build.Tasks.Core.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Build.Tasks.Core.dll". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             Microsoft.Build.Tasks.Core [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             Xamarin.iOS.Tasks [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277: Found conflicts between different versions of "System.Net.Http" that could not be resolved. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277: There was a conflict between "System.Net.Http, Version=4.1.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" and "System.Net.Http, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     "System.Net.Http, Version=4.1.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" was chosen because it was primary and "System.Net.Http, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" was not. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     References which depend on "System.Net.Http, Version=4.1.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" [xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.Net.Http.dll]. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.Net.Http.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.Net.Http.dll". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             xamarin-macios/packages/netstandard.library/2.0.3/build/netstandard2.0/ref/System.Net.Http.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:     References which depend on "System.Net.Http, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" []. [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:         /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Build.Tasks.Core.dll [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:           Project file item includes which caused reference "/Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Build.Tasks.Core.dll". [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             Microsoft.Build.Tasks.Core [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
    /Library/Frameworks/Mono.framework/Versions/6.12.0/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3277:             Xamarin.iOS.Tasks [xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj]
2022-09-05 10:55:57 +02:00
Rolf Bjarne Kvinge d1ef85446d
Misc fixes to make the build more silent. (#15852) 2022-09-05 10:55:41 +02:00
Rolf Bjarne Kvinge 94db59d841
[msbuild] Ignore NU1603 for XVS package references. (#15805)
Fixes these NuGet warnings:

    xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj : warning NU1603: Xamarin.Messaging.Build.Common 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj : warning NU1603: Xamarin.Messaging.Core 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj : warning NU1603: Xamarin.iOS.HotRestart.Client 1.0.93 depends on Merq (>= 1.1.1) but Merq 1.1.1 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj : warning NU1603: Xamarin.Messaging.Build.Common 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj : warning NU1603: Xamarin.Messaging.Core 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.Mac.Tasks/Xamarin.Mac.Tasks.csproj : warning NU1603: Xamarin.Messaging.Build.Common 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.Mac.Tasks/Xamarin.Mac.Tasks.csproj : warning NU1603: Xamarin.Messaging.Core 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj : warning NU1603: Xamarin.Messaging.Core 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj : warning NU1603: Xamarin.Messaging.Build.Common 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
    xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj : warning NU1603: Xamarin.Messaging.Core 1.6.24 depends on Merq (>= 1.1.0) but Merq 1.1.0 was not found. An approximate best match of Merq 1.1.4 was resolved.
2022-08-31 18:26:46 +02:00
Rolf Bjarne Kvinge 76eb0bb573
[msbuild] Fix a few duplicate compile items warnings. (#15792)
Fixes:

	CSC : warning CS2002: Source file 'xamarin-macios/msbuild/Xamarin.Localization.MSBuild/MSBStrings.Designer.cs' specified multiple times [xamarin-macios/msbuild/Xamarin.Localization.MSBuild/Xamarin.Localization.MSBuild.csproj]
    CSC : warning CS2002: Source file 'xamarin-macios/tools/mtouch/Errors.Designer.cs' specified multiple times [xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj]
2022-08-31 18:26:10 +02:00
Rolf Bjarne Kvinge 4922bf4570 Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-08-31 2022-08-31 13:45:17 +02:00
Rolf Bjarne Kvinge ff3aeb5073 Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14-2022-08-30 2022-08-30 11:14:47 +02:00
Rolf Bjarne Kvinge a09b971788 [src] Quiet the build a bit. (#15737) 2022-08-29 14:15:02 +02:00
Rolf Bjarne Kvinge b9a60c4d7e
[msbuild] Remove the Xamarin.*.Task.Core assemblies. (#15768)
We used to do the following:

1. Have abstract task classes in the Xamarin.*.Task.Core assembly (with all
   the actual code for the task in question to work properly on macOS).
2. Subclassed task in the Xamarin.*.Task assembly, which did nothing.
3. On Windows we'd inject a different Xamarin.*.Task assembly, with
   Windows-specific overrides for the implementation in the abstract base
   class.

However, we no longer do point 3, which means that we no longer need to split
our tasks across two assemblies.

This means that we can remove the Xamarin.\*.Task.Core assemblies, and move all
the code into the corresponding Xamarin.\*.Task assembly instead.

This simplifies our code and speeds up the build.

There are more simplifications that can be done; those will come in later PRs.
2022-08-29 11:59:28 +02:00
Rolf Bjarne Kvinge 4289148b28 Merge remote-tracking branch 'origin/main' into bump-main-in-xcode14-2022-08-26 2022-08-26 13:24:27 +02:00
Rolf Bjarne Kvinge a932ca2d7c Merge remote-tracking branch 'origin/main' into bump-main-in-net7.0-2022-08-26 2022-08-26 13:22:24 +02:00
Emanuel Fernandez Dell'Oca b1a732d526
[dotnet] macOS/MacCatalyst Archive and publishing support (#15720)
These changes are required to support Archive and Publishing for .NET macOS/MacCatalyst projects from VS for Mac.

Co-authored-by: Alex Soto <alex@alexsoto.me>
2022-08-26 08:18:43 +02:00
Rolf Bjarne Kvinge b2c10aab23
[msbuild] Fix the FindAotCompiler task for .NET 7. (#15759)
Compute the .NET version to use when generating the project file to compute
the AOT compiler.

Also include a way to always force the computation, even on macOS (this eases
testing).

Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1597624.
2022-08-26 08:07:20 +02:00
Rolf Bjarne Kvinge 408cd7ac52
[msbuild] Automatically detect any Entitlements.plist files in the root project in .NET. (#15729)
Also provide a way out by setting EnableDefaultCodesignEntitlements=false.

Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1595888.
2022-08-26 08:06:48 +02:00
Rolf Bjarne Kvinge a09c1e976c
[dotnet] Honor existing values for BuildIpa and CreatePackage. Fixes #15696. (#15697)
Don't blindly set the BuildIpa and CreatePackage values, but instead only set
them (when publishing) if they're not already set.

This makes it possible to publish and not create a package.

Fixes https://github.com/xamarin/xamarin-macios/issues/15696.
2022-08-25 11:05:09 +02:00
Rolf Bjarne Kvinge ceb3f97e90
[msbuild] Build for iOS if any platform except macOS is enabled. (#15755)
This is because we use the iOS assemblies for all other platforms except for
macOS.
2022-08-25 09:26:21 +02:00
Rolf Bjarne Kvinge 2b619955db
[msbuild] Unify the DetectSigningIdentity task between iOS and Mac. (#15698)
I've chosen the iOS implementation, since it's a bit more advanced to support
remote builds (the Mac implementation didn't do anything at all).

This should have no effect, since we don't support remote builds for macOS
anyways.
2022-08-24 18:55:07 +02:00
Mauro Agnoletti 6617121585
Fixed remote archiving with iOS app extensions (#15726)
- Fix AppExtensionReferences ItemSpec in Archive:
 when the build is a remote build, we need to fix the ItemSpec of the AppExtensionReferences items so it uses the build server path correctly

- Shorten temp directory for remote zip extractions to avoid long path potential conflicts

Fixes Feedbak Ticket issue: https://developercommunity.visualstudio.com/t/Xamarin-iOS-project-wont-archive-anymor/1587820
2022-08-23 12:21:17 +02:00
Rolf Bjarne Kvinge 105a12d637 Merge remote-tracking branch 'origin/main' into net7.0-merge-main-2022-08-23 2022-08-23 11:08:56 +02:00
Rolf Bjarne Kvinge d66c4da1af Merge remote-tracking branch 'origin/main' into xcode14-merge-main-2022-08-22 2022-08-22 18:38:32 +02:00
Mauro Agnoletti 457737306c
Updated Xamarin.Messaging to 1.7.9 (#15713) 2022-08-19 18:48:17 -04:00
Mauro Agnoletti 028afc2eab
Updated Xamarin.Messaging to 1.7.9 (#15714) 2022-08-19 16:30:35 -04:00
Rolf Bjarne Kvinge e54019a336
[dotnet] Make it possible to specify the registrar using a 'Registrar' property in MSBuild. (#15483)
Co-authored-by: Marius Ungureanu <therzok@gmail.com>
2022-08-18 17:21:48 +02:00
Rolf Bjarne Kvinge aaee2bf794
[msbuild] Unify the CreateEmbeddedResources task between iOS and Mac. (#15500)
I've chosen the iOS implementation, since it's a bit more advanced to support
remote builds (the Mac implementation didn't do anything at all).

This should have no effect, since we don't support remote builds for macOS
anyways.
2022-08-18 16:56:23 +02:00
Alex Soto 0e53b999d2
[net7.0] Updates the path to illink when building from Windows (#15667)
The directory that contains illink.dll is now net7.0
2022-08-10 16:39:45 -04:00
Alex Soto 028b85da07 Merge remote-tracking branch 'agocke/set-trimmode-partial' into net7.0-a-new-hope 2022-08-05 17:59:04 -04:00
Alex Soto 1434ede326 Merge remote-tracking branch 'xamarin/main' into net7.0-a-new-hope 2022-08-05 17:58:58 -04:00
Manuel de la Pena 57adecc437 Merge branch 'main' into xcode14-merge-main 2022-08-03 10:34:56 -04:00
Rolf Bjarne Kvinge 78020cbaba
[msbuild] Remove dead code from the Codesign task. (#15519)
Fixes this warning:

    xamarin-macios/msbuild/Xamarin.iOS.Tasks.Windows/Tasks/Codesign.cs(12,27): warning CS0649: Field 'Codesign.cancellationSource' is never assigned to, and will always have its default value null [xamarin-macios/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj]
2022-07-27 10:21:45 -04:00
Rolf Bjarne Kvinge 8cc194ac86
[msbuild] Ignore CS0169 in a few places. (#15520)
Fixes these warnings:

    msbuild/Xamarin.iOS.Tasks/Model/DataItem.cs(25,31): warning CS0169: The field 'DataItem.UnsupportedData' is never used [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]
    msbuild/Xamarin.iOS.Tasks/Model/DataSet.cs(12,31): warning CS0169: The field 'DataSet.JsonData' is never used [xamarin-macios/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj]

Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2022-07-26 11:42:06 -04:00
Manuel de la Pena 4c4b906bc4 [Xcode14] Merge main into xcode14. 2022-07-26 11:15:34 -04:00
Mauro Agnoletti 17ebe77a94
Set custom home env var from XMA Build Agent (#15571)
Overriding HOME is dangerous because it could cause unwanted side effects, like breaking the keychain API logic.

For this reason, we need to use a custom environment variable to store the custom home used by the XMA dotnet SDK.

This custom home should be passed everywhere as environment settings when we invoke the dotnet tool
2022-07-25 20:53:25 -04:00
Emanuel Fernandez Dell'Oca c957b0402a
Ensure the Hot Restart bundle does not have any entitlements set (#15558)
Hot Restart expects the archived-expanded-entitlements.xcent to be empty. If any entitlements are added to that file, the new app signature will be invalid.

These changes ensure that file will be an empty plist when extracting the PreBuilt app.

Partial fix for https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1550700
2022-07-21 16:17:20 -04:00
Emanuel Fernandez Dell'Oca 9bc3e3b238
Bump Xamarin.Messaging to 1.6.60 (#15370)
* Bump Xamarin.Messaging to 1.6.60

* Bump GitInfo to match Xamarin.Messaging

Co-authored-by: Alex Soto <alex@alexsoto.me>
2022-07-20 11:25:51 -04:00
Rolf Bjarne Kvinge 9facd8187d
[msbuild] Unify the PrepareNativeReferences task between iOS and Mac. (#15473) 2022-07-14 16:21:10 +02:00
Rolf Bjarne Kvinge 72c065cd80
[msbuild] Unify the CompileAppManifest task logic between iOS and Mac. (#15474) 2022-07-14 16:20:56 +02:00
Rolf Bjarne Kvinge f8ff530796 Merge remote-tracking branch 'origin/main' into xcode14-merge-main-2022-07-12 2022-07-12 14:52:32 +02:00
Rolf Bjarne Kvinge 4c6a35be13 Merge remote-tracking branch 'origin/net7.0' into set-trimmode-partial 2022-07-12 11:48:30 +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 1f1c03b435
[msbuild] Copy partial app manifests to build server if they exists on Windows. Fixes #15267. (#15328)
The exclusion of partial app manifests happened here, but the commit doesn't explain why:

f4a4b232f8 (diff-178de6110858688b9f7c2e8e57a873f5ac9498b355a456bfc18547ab2df876bc)

It's certainly wrong if the partial app manifest is a part of the project, but
this exclusion might be because partial app manifests might be added as a part
of the build as well.

So change the logic to copy partial app manifests from Windows if they exist
there and they're not empty.

Fixes https://github.com/xamarin/xamarin-macios/issues/15267.
2022-07-11 20:39:07 +02:00
Rolf Bjarne Kvinge 840d2e9115
[msbuild] Remove code for watchOS 1 extensions, which we no longer support. (#15327) 2022-07-11 10:54:19 +02:00
Rolf Bjarne Kvinge 4b9d8aef5b Merge remote-tracking branch 'origin/main' into net7.0 2022-07-11 10:51:01 +02:00
Rolf Bjarne Kvinge abbd6ef466
[msbuild/tools] Fix path issues in the FilterStaticFrameworks task and ExtractBindingLibraries step. Fixes #15289. (#15321)
In the FilterStaticFrameworks task:

* Convert Windows-style paths to Mac-style paths.
* Give a better error if a framework can't be found.
* Don't try to copy frameworks that don't exist on Windows to the Mac.

In the ExtractBindingLibrariesStep:

* Return a relative path to frameworks we've extracted to make things easier for
  remote builds.

* In the _ComputeFrameworkFilesToPublish target, don't compute the source
  directory for frameworks using RootDir + Directory, because some frameworks
  may only exist on the mac, and RootDir + Directory will be a Windows path
  when building remotely. Instead use 'Identity', which is a relative path and
  will work on both Windows and Mac.

Fixes https://github.com/xamarin/xamarin-macios/issues/15289.
2022-07-11 10:39:54 +02:00
Andy Gocke c558df7524
Merge branch 'main' into set-trimmode-partial 2022-07-10 19:45:16 -07:00
Andy Gocke 6854d31701 Update DefaultAction call 2022-06-30 22:44:10 -07: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 baf9f82c9e Merge remote-tracking branch 'origin/xcode14' into xcode14-initial-pr 2022-06-22 23:51:52 +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 a358b493fd Merge remote-tracking branch 'origin/xcode14' into HEAD 2022-06-21 16:12:26 +02:00
Rolf Bjarne Kvinge 9e6e2449a1 Merge remote-tracking branch 'origin/main' into net7.0 2022-06-20 12:13:31 +02:00
Rolf Bjarne Kvinge ab52bb2f45
[msbuild] Unify the DetectSdkLocations task logic between iOS and Mac. (#15256)
This was mostly a clean merge, with a few minor differences:

* We no longer compute whether we're running in the simulator or not when building for Mac Catalyst.
* The task now supports building remotely for macOS (due to code sharing).
  Will be useful if we ever support building macOS apps remotely.
* We now call AppleSdkSettings.Init () on macOS. No idea why we weren't
  before, but it seems logical for macOS to behave like our other platforms.

There shouldn't be any other functional differences.
2022-06-16 23:52:43 +02:00
Rolf Bjarne Kvinge 438e312503
[msbuild] Only pass -z to dsymutil when using Xcode 13.2 or earlier. (#15254)
Apple removed the -z / --minimize option in Xocde 13.3, so now if you use it
you get a warning: "ignoring unknown option: -z".

So just don't pass -z when using Xcode >= 13.3

Ref: https://github.com/dotnet/runtime/issues/66770
Ref: 5d07dc8977
2022-06-15 14:55:51 +02:00
Rolf Bjarne Kvinge 2b84ce2ccb Merge remote-tracking branch 'origin/main' into net7.0 2022-06-15 13:34:23 +02:00
Rolf Bjarne Kvinge ee2af3c896
[msbuild] Only sign the prebuilt hotrestart app in CI (#15236)
Only sign the prebuilt hotrestart app in CI, to avoid making it required for
developers to configure code signing.

Also fix DetectSigningIdentity to not require a code signing certificate for
device builds when RequireCodeSigning is false.

Co-authored-by: Alexander Köplinger <alex.koeplinger@outlook.com>
2022-06-13 17:30:22 +02:00
Rolf Bjarne Kvinge c05e774612 [dotnet/tools] Disable compact unwind on Xcode 14 to fix linker warnings.
Ref: https://codereview.chromium.org/2784253003
Ref: https://github.com/grain-lang/binaryen.ml/pull/136
Ref: https://github.com/ocaml/ocaml/issues/9026
Ref: https://gitlab.haskell.org/ghc/ghc/-/issues/11829
2022-06-13 10:56:02 +02:00