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

11120 Коммитов

Автор SHA1 Сообщение Дата
Rolf Bjarne Kvinge fc8fb4818c
[runtime] Set the current directory to the root directory of the app bundle for all platforms in .NET. (#12104)
To have consistent behavior in .NET, set the current directory to the root of
the app bundle for all platforms.

This is a breaking change for legacy Xamarin.Mac, which used to set the
current directory to the Contents/Resources subdirectory, but there's a simple
workaround for customers that depend on the old behavior (change it in Main
themselves), and I believe the consistent experience across platforms warrants
this change.

Note that we already had a breaking change here for macOS/.NET: we were
(unintentionally) setting the current directory to the Contents/MonoBundle
directory, which neither matched mobile platforms, nor the legacy Xamarin.Mac
behavior.

This solves the problem of what to do for Mac Catalyst apps, because there's
no need to choose between the macOS or the mobile behavior, since they're the
same.

This required changing the launch of macOS apps using CoreCLR to pass the full
path to the entry assembly, since the entry assembly isn't in the current
directory anymore.
2021-07-14 17:42:49 +02:00
TJ Lambert a202354c71
[IOSurface] Updates for Xcode13 Beta 1 (#12096) 2021-07-13 12:57:57 -05:00
TJ Lambert ecd8dccccf
[GameKit] Updates for Xcode13 Beta 1-2 (#12091) 2021-07-13 12:44:35 -05:00
Rolf Bjarne Kvinge 78e2251671
[xharness] Don't fail when trying to set a RuntimeIdentifier if there isn't already a RuntimeIdentifier in the csproj. (#12105) 2021-07-13 18:51:03 +02:00
Jonathan Peppers 33f8143b97
[dotnet] no default $(RuntimeIdentifier) for class libraries (#12093)
Context: https://github.com/dotnet/maui/pull/1578

In the latest xamarin-macios bump, the dotnent/maui build started
failing because the `$(OutputPath)` of all the projects changed from:

    bin/Debug/net6.0-ios/
    bin/Debug/net6.0-maccatalyst/

To:

    bin/Debug/net6.0-ios/iossimulator-x64/
    bin/Debug/net6.0-maccatalyst/maccatalyst-x64/

Class library projects appear to have `$(RuntimeIdentifier)` set by
default. I don't think this is needed, because class libraries do not
need to be compiled as `--self-contained` apps.

On the Android side, we only set a default `$(RuntimeIdentifiers)` for
application projects:

7c5fab1332/src/Xamarin.Android.Build.Tasks/Microsoft.Android.Sdk/targets/Microsoft.Android.Sdk.DefaultProperties.targets (L49-L61)

I think the correct change here is to check:

    '$(OutputType)' == 'Exe' Or '$(IsAppExtension)' == 'true'

So Apple platforms only put a default `$(RuntimeIdentifier)` for
applications or extensions.

Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-07-13 13:14:08 +02:00
Rolf Bjarne Kvinge 9207b5940e
[tests] Fix the Native*ReferencesApp tests to have an Info.plist with a minimum OS version. (#12099)
* We need to specify a minimum OS version, because otherwise we'll pick the
  latest OS version we support, and at least for macOS, we might very well try
  to execute on earlier OS versions, leading to confusing failures like this:

    Xamarin.Tests.DotNetProjectTest.BuildAndExecuteNativeReferencesTestApp("NativeDynamicLibraryReferencesApp",MacOSX,"osx-x64"): Contains magic word
        Expected: String containing "dc8bd019-bea2-4c86-92dc-dda22e2e6b88"
        But was: "dyld: Library not loaded: /System/Library/Frameworks/CHIP.framework/Versions/A/CHIP
        Referenced from: /Users/builder/azdo/_work/1/s/xamarin-macios/tests/dotnet/NativeDynamicLibraryReferencesApp/macOS/bin/Debug/net6.0-macos/osx-x64/NativeDynamicLibraryReferencesApp.app/Contents/MacOS/NativeDynamicLibraryReferencesApp
        Reason: image not found

* We only need a minimum OS version (for now at least) in the Info.plist, so
  remove everything else.
2021-07-12 23:05:35 +02:00
TJ Lambert 26a8abe76e
using swift names (#12095)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-12 11:18:02 -05:00
Rolf Bjarne Kvinge 6074ed5c04
[dotnet] Copy fewer runtime libraries to the publish directory. (#12059)
* Don't copy runtime dylibs to the publish directory if we're linking statically.
* Don't copy static libraries to the publish directory, they're never needed at
  runtime.
2021-07-12 17:09:45 +02:00
Jonathan Peppers 5434cfd936
[dotnet] don't import RuntimeConfigParser.Task for MacCatalyst (#12083)
Context: ae5ee8f02d/src/mono/nuget/Microsoft.NET.Workload.Mono.Toolchain.Manifest/WorkloadManifest.targets (L30-L32)

Building dotnet/maui, I get warnings for any MacCatalyst projects:

    WorkloadManifest.targets(22,9): warning MSB4011: "C:\src\maui\bin\dotnet\packs\Microsoft.NET.Runtime.RuntimeConfigParser.Task\6.0.0-preview.6.21352.12\Sdk\Sdk.props" cannot be imported again.
    It was already imported at "C:\src\maui\bin\dotnet\sdk-manifests\6.0.100\microsoft.net.sdk.maccatalyst\WorkloadManifest.targets (8,2)". This is most likely a build authoring error. This subsequent import will be ignored.

I believe we can remove this `<Import/>` now, as the Mono workload is
doing the importing for MacCatalyst.

It appears that this is still needed for the macOS workload, however.
2021-07-12 17:08:54 +02:00
Rolf Bjarne Kvinge 9ae7d236e6
[dotnet] aotdata files go in the same directory as the assemblies. (#12058)
aotdata files go next to the assemblies, not next to the executable. This does
not make a difference for mobile platforms (because it's the same location),
but it matters for Mac Catalyst / macOS, where assemblies are not located next
to the executable.
2021-07-12 15:52:11 +02:00
Rolf Bjarne Kvinge 2f50096a09
[dotnet] Remove dead code. (#12057) 2021-07-12 15:51:45 +02:00
Rolf Bjarne Kvinge f9ace85218
[generator] Adjust generated code to not assume that only device-specific code can be ARM64. (#12056)
We can have ARM64 code everywhere now, so our conditions to select the correct
objc_msgSend overload must not think that we only need the ARM64 code paths on
a mobile device.

Old style:

	if (Runtime.Arch == Arch.DEVICE) {
		if (IntPtr.Size == 8) {
			// arm64 codepath
		} else {
			// 32-bit arm codepath
		}
	} else if (IntPtr.Size == 8) {
		// x86_64 codepath
	} else {
		// x86 codepath
	}

New style:

	if (global::ObjCRuntime.Runtime.IsARM64CallingConvention) {
		// arm64 codepath
	} else if (IntPtr.Size == 8) {
		// x86_64 codepath
	} else if (Runtime.Arch == Arch.DEVICE) {
		// 32-bit arm codepath
	} else {
		// x86 codepath
	}
2021-07-12 15:50:27 +02:00
Manuel de la Pena cd1145d169
[xtro] Do not allow to leave empty todo files in xtro. (#12090)
To avoid things like the ones fixed in https://github.com/xamarin/xamarin-macios/pull/12088 we add a new
test to ensure that todo files do have content.
2021-07-12 09:44:11 -04:00
TJ Lambert 7ad807a4c3
initial changes (#12094)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-09 17:55:49 -05:00
github-actions[bot] 797a2f57d3
[Localization] Pulling New Localization Translations 995001664 (#12078)
Co-authored-by: csigs <csigs@users.noreply.github.com>
Co-authored-by: CSIGS <csigs@outlook.com>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2021-07-09 16:22:28 -04:00
Rachel Kang be3b440c23
[Speech] Update bindings for XCode 13.0 beta 1 (#12086) 2021-07-09 16:02:12 -04:00
Rachel Kang 7b167e26ef
[xtro] Remove empty .todo files (#12088)
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2021-07-09 15:00:42 -04:00
Rachel Kang 924c006f3c
[iTunesLibrary] Update bindings for Xcode 13.0 beta 1 (#12038)
* [iTunesLibrary] Update bindings for Xcode 13.0 beta 1

* Move existing property back to original location

* Fix message and remove unnecessary Introduced tags

* Fix typo in deprecation message

* Delete empty .todo file
2021-07-09 10:42:15 -05:00
github-actions[bot] 9d31e45151
[Localization] Pulling New Localization Translations 991686731 (#12073)
Co-authored-by: csigs <csigs@users.noreply.github.com>
Co-authored-by: CSIGS <csigs@outlook.com>
2021-07-08 14:54:51 -04:00
TJ Lambert 956828f0c4
[AutomaticAssessmentConfiguration] Updates for Xcode13 beta1 (#12070)
* initial changes for AutomaticAssessmentConfiguration

* forgot a selector

Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-08 13:01:35 -05:00
Rachel Kang ac5c1577e1
[MapKit] Update bindings for Xcode 13.0 beta 1 and beta 2 (#12081) 2021-07-07 17:29:43 -04:00
Rachel Kang baeb041d96
[Accounts] Update bindings for Xcode 13.0 beta 1 (#12024)
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2021-07-07 17:26:39 -04:00
Rachel Kang 9ca0942116
[Accessibility] Update bindings for Xcode 13.0 beta 1 (#11998)
Co-authored-by: Rachel Kang <rachelkang@microsoft.com>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-07-07 17:25:31 -04:00
TJ Lambert 9746c617a7
adding enum elements (#12068)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-07 15:37:21 -05:00
TJ Lambert ab151a7430
initial updates for xcode 13 beta 1 (#12074)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-07 15:36:26 -05:00
Manuel de la Pena f9639388d5
[CarPlay] Add support for Xcode13 beta2. (#12052) 2021-07-07 11:54:41 -04:00
TJ Lambert 240a73d710
[Actions ] Add github actions to the ignore list (#12075)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-07 11:50:50 -04:00
Anaïs Betts 42fc785f18
[Foundation] NSUrlSessionHandler proper attribution (#12082)
Attribute code ownership to the right author.

Co-authored-by: Anaïs Betts <anais@anaisbetts.org>
2021-07-07 11:30:44 -04:00
TJ Lambert 3b6f059863
[CI] Reverting the Cron job (#12071)
* Changing Cron Job

* reverting the cron job

Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-07-02 21:59:32 -04:00
TJ Lambert 10b2f36fa5
[EventKit] Updates for Xcode13 Beta1 (#12022)
* initial changes for EventKit Xcode13 Beta1

* adding delegate

* fixing delegates

* removing NoMacCatalyst from MONOMAC

* removing rest of monomac maccatalysts

* Apply suggestions from code review

Co-authored-by: Alex Soto <alex@alexsoto.me>

* there was one more EKVirtualConferenceURLDescriptor

Co-authored-by: tj_devel709 <antlambe@microsoft.com>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
Co-authored-by: Alex Soto <alex@alexsoto.me>
2021-07-01 18:25:58 -05:00
dotnet-maestro[bot] 20dc67f084
[main] Update dependencies from dotnet/installer (#12036)
* Update dependencies from https://github.com/dotnet/installer build 20210628.9

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.7.21327.2 -> To Version 6.0.100-preview.7.21328.9

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.7.21327.2 -> To Version 6.0.100-preview.7.21330.1

Dependency coherency updates

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

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
2021-07-01 08:37:48 +02:00
Manuel de la Pena d99235db4e
[CHIP] Add support for Xcode13 beta2. (#12025)
Co-authored-by: TJ Lambert <50846373+tj-devel709@users.noreply.github.com>
Co-authored-by: Alex Soto <alex@alexsoto.me>
2021-06-30 20:18:41 -04: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
TJ Lambert 0bfb7450a0
[ReplayKit] Updates for Xcode13 Beta 1 (#12026)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2021-06-30 11:10:37 -04:00
Jonathan Peppers 801063d7bf
[dotnet] add missing workload dependencies (#12045)
Context: 36e0432547/src/mono/nuget/Microsoft.NET.Workload.Mono.Toolchain.Manifest/WorkloadManifest.json.in

When using the MacCatalyst workload, you hit the build error:

    error NETSDK1147: To build this project, the following workloads must be installed: microsoft-net-runtime-maccatalyst

I found an `extends` was missing in `WorkloadManifest.json`.

I also found the macOS workload needs to extend
`microsoft-net-runtime-mono-tooling`, because of its usage of
`<RuntimeConfigParserTask/>`
2021-06-30 09:50:46 +02:00
Jonathan Peppers a64b030fcc
[dotnet] shorten workload ids (#12035)
Context: https://github.com/xamarin/xamarin-android/pull/6045

We are aiming to simplify the .NET workload ids to short names like:

    dotnet workload install maui
    dotnet workload install android
    dotnet workload install ios
    dotnet workload install maccatalyst
    dotnet workload install macos
    dotnet workload install tvos

Updated the workload ids here, as well as the `.stamp-install-workloads`
make target.

Other changes:

* Updated descriptions to match Android. Still waiting on an *official*
description we should be using for each workload.

* Fixed trailing `,` that showed up as JSON errors in VS Code.
2021-06-29 16:49:39 +02:00
Mauro Agnoletti bfe6fafbee
Updated Xamarin.Messaging version (#12012) 2021-06-29 10:22:54 -04:00
Rolf Bjarne Kvinge ebf6c13bd1
[dotnet] Add support for universal apps. (#11983)
Add support for universal / fat apps for iOS, macOS and Mac Catalyst.

We detect if we need to build a universal app by checking if `RuntimeIdentifiers` (plural) is set, and in that case we do a complete inner build for every `RuntimeIdentifier`, and then once those inner builds are done, we merge the resulting .app bundles together (using a new MSBuild task called `MergeAppBundles`).

When merging app bundles together, we'll run into files that exist in both apps. Depending on the file type, we do different things:

* MachO flies: lipo'ed together.
* Managed assemblies: we do a binary comparison, if the assemblies are different, we put them in a RID-specific subdirectory. At runtime we know to look for assemblies in this directory.
* runtimeconfig.bin, icudt.dat: put in a RID-specific subdirectory.
* Info.plist: computed in the outer (fat) build, the one from the inner build is ignored.
* Other files: for identical files we just copy one, otherwise we show an error.

If we run into files that are different between apps, but we should handle somehow, then we'll have to decide on a case-to-case basis what to do.

Some code shuffling was required to increase code sharing between the tools/ code, the msbuild/ code, and tests.

I've also added support for a default `RuntimeIdentifier`.

Fixes https://github.com/xamarin/xamarin-macios/issues/10294.
Fixes https://github.com/xamarin/xamarin-macios/issues/10861.
2021-06-29 11:38:04 +02:00
dotnet-maestro[bot] 477853a2b4
Update dependencies from https://github.com/dotnet/installer build 20210627.2 (#12031)
Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.7.21326.4 -> To Version 6.0.100-preview.7.21327.2

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
2021-06-29 11:17:04 +02:00
Alex Soto e2a92c1b07
[xcode13] Bump PR to Xcode 13 Beta 2 (#12017)
Update tests regarding the deprecated fields and classes.

Co-authored-by: Rachel Kang <rachelkang@microsoft.com>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2021-06-28 17:54:52 -04:00
TJ Lambert 4fd6faf780
Changing Cron Job (#12032)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-06-28 17:51:42 -04:00
TJ Lambert 32402490b6
[GameController] Updates for Xcode13 beta1 (#12014)
* Initial changes for xcode13 GameController beta1

* syntax and name change

* name change and adding async

Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-06-28 10:37:42 -05:00
TJ Lambert a134a75f9e
[Localization] Change the Input value (#12029)
* changing the isCreatePrSelected input

* remove the variable representation

Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-06-28 10:36:36 -05:00
Rolf Bjarne Kvinge 870ffa0117
[dotnet] Use TargetDir instead of OutputPath for resolving assembly output directory. (#12021)
OutputPath is relative to the project directory, so it doesn't work when the
current directory isn't the same as the project directory.

TargetDir is an absolute directory.

Ref: #11994 / 096c75f425 (same for Mac Catalyst).
2021-06-28 14:05:09 +02:00
dotnet-maestro[bot] 761566f583
[main] Update dependencies from dotnet/installer (#11852)
* Update dependencies from https://github.com/dotnet/installer build 20210606.2

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.6.21306.2

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.6.21313.2

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.6.21315.23

Dependency coherency updates

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

* Fix custom step order

In response to https://github.com/mono/linker/pull/2082

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21320.4

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21321.2

Dependency coherency updates

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

* Remove unnecessary workaround.

* [dotnet] Update our code to get the path to the AOT compiler. Fixes #11905.

* [dotnet] Remove another workaround for runtime packs doing the wrong thing.

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21322.1

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21322.8

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21323.2

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21323.11

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21324.6

Dependency coherency updates

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

* [dotnet] Install the microsoft-net-runtime-maccatalyst workload as well.

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21325.1

Dependency coherency updates

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

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

Microsoft.Dotnet.Sdk.Internal
 From Version 6.0.100-preview.6.21280.2 -> To Version 6.0.100-preview.7.21326.4

Dependency coherency updates

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

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Sven Boemer <sbomer@gmail.com>
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-06-28 13:58:33 +02:00
TJ Lambert b1e8b29fd6
Adding enums (#12010)
Co-authored-by: tj_devel709 <antlambe@microsoft.com>
2021-06-25 10:33:39 -05:00
Rolf Bjarne Kvinge d8ee4d202e
[src] Remove the internal NSObject.SetAsProxy, and call the NSObject.IsDirectBinding setter directly. (#12020)
NSObject.SetAsProxy is only available for macOS, so this makes the generated
code behave (and actually work) on all platforms.
2021-06-25 16:55:41 +02:00
Rolf Bjarne Kvinge fe1b2386bd
[dotnet] Fix launching macOS and Mac Catalyst apps with arguments. (#12019)
When we're using 'open' to launch apps, we need to use '--args ...' to pass any additional argument to the app, because otherwise 'open' will try to open those arguments as if they were files:

```
$ open "/Applications/Sublime Text.app" helloworld
The file /Users/rolf/test/helloworld does not exist.
```

(and doesn't launch Sublime Text).

while this works:

```
$ open "/Applications/Sublime Text.app" --args helloworld
```

in that it opens Sublime Text.

It's also possible to not append any other arguments, so this:

```
$ open "/Applications/Sublime Text.app" --args
```

while it looks weird, it works just fine.

Ref: https://github.com/dotnet/sdk/issues/18437
2021-06-25 16:53:13 +02:00
Rolf Bjarne Kvinge 8aff15a4f0 [tests] Don't run parallel make in tests/common/TestProjects/ComplexAssembly, it may cause make to deadlock. 2021-06-25 08:26:01 +02:00
Jonathan Peppers 69698bea36
[dotnet] use copyOnly for .png files in templates (#12016)
Context: https://github.com/dotnet/templating/issues/3325
Context: https://github.com/dotnet/templating/wiki/Reference-for-template.json#content-manipulation

In current .NET 6 Preview 6 builds, there is an issue if a template
includes a binary file larger than ~8kb, it seems to get truncated when
`dotnet new` extracts the template.

A workaround is to use the `copyOnly` feature for binary files. Really,
we should be doing this anyway, because otherwise the templating system
considers replacing *text* in these binary files. It improves
performance to do this and would hopefully prevent a future bug of
random bytes getting replaced.
2021-06-25 08:18:56 +02:00