Skip to content

Commit

Permalink
Merge branch 'main' into darc-main-7d6cfed6-6e3b-49ea-b941-87e0d82e36e0
Browse files Browse the repository at this point in the history
  • Loading branch information
rolfbjarne authored Nov 17, 2022
2 parents 99395ac + d6f9aa7 commit 870dccc
Show file tree
Hide file tree
Showing 208 changed files with 3,518 additions and 3,062 deletions.
6 changes: 3 additions & 3 deletions dotnet/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ DIRECTORIES += \
$(TMP_PKG_DIR) \
$(foreach platform,$(DOTNET_WINDOWS_PLATFORMS),$(DOTNET_DESTDIR)/Microsoft.$(platform).Windows.Sdk/Sdk) \
$(foreach platform,$(DOTNET_WINDOWS_PLATFORMS),$(DOTNET_DESTDIR)/Microsoft.$(platform).Windows.Sdk/targets) \
$(foreach platform,$(DOTNET_PLATFORMS),Workloads/Microsoft.NET.Sdk.$(platform)) \

$(DIRECTORIES):
$(Q) mkdir -p $@
Expand Down Expand Up @@ -167,13 +168,12 @@ endef
$(foreach platform,$(DOTNET_PLATFORMS),$(eval $(call SharedAfterTargetsTemplate,$(platform),$(NET6_$(platform)_NUGET_VERSION_NO_METADATA))))

define WorkloadTargets
Workloads/Microsoft.NET.Sdk.$(1)/WorkloadManifest.json: Makefile $(TOP)/Make.config.inc $(TOP)/.git/HEAD $(TOP)/.git/index Makefile generate-workloadmanifest-json.csharp
$$(Q) mkdir -p Workloads/Microsoft.NET.Sdk.$(1)/
Workloads/Microsoft.NET.Sdk.$(1)/WorkloadManifest.json: Makefile $(TOP)/Make.config.inc $(TOP)/.git/HEAD $(TOP)/.git/index Makefile generate-workloadmanifest-json.csharp | Workloads/Microsoft.NET.Sdk.$(1)
$$(Q) rm -f $$@.tmp
$$(Q_GEN) ./generate-workloadmanifest-json.csharp "$(1)" "$(3)" "$(4)" "$$(DOTNET_$(5)_RUNTIME_IDENTIFIERS)" "$$@.tmp" "$$(DOTNET_WINDOWS_PLATFORMS)"
$$(Q) mv $$@.tmp $$@

Workloads/Microsoft.NET.Sdk.$(1)/WorkloadManifest.targets: Workloads/WorkloadManifest.$(1).template.targets Makefile $(TOP)/Make.config.inc $(TOP)/.git/HEAD $(TOP)/.git/index
Workloads/Microsoft.NET.Sdk.$(1)/WorkloadManifest.targets: Workloads/WorkloadManifest.$(1).template.targets Makefile $(TOP)/Make.config.inc $(TOP)/.git/HEAD $(TOP)/.git/index | Workloads/Microsoft.NET.Sdk.$(1)
$$(Q_GEN) sed \
-e "s/@NUGET_VERSION_NO_METADATA@/$3/g" \
$$< > $$@.tmp
Expand Down
27 changes: 17 additions & 10 deletions msbuild/Xamarin.iOS.Tasks/Tasks/ValidateAppBundleTaskBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ void ValidateWatchApp (string path, string mainBundleIdentifier, string mainShor
{
var name = Path.GetFileNameWithoutExtension (path);
var info = Path.Combine (path, "Info.plist");
var isSingleProject = false;
if (!File.Exists (info)) {
Log.LogError (7014, path, MSBStrings.E7014, name);
return;
Expand Down Expand Up @@ -162,26 +163,32 @@ void ValidateWatchApp (string path, string mainBundleIdentifier, string mainShor
Log.LogError (7019, info, MSBStrings.E7019, name, wkCompanionAppBundleIdentifier, mainBundleIdentifier);

PBoolean watchKitApp;
if (!plist.TryGetValue ("WKWatchKitApp", out watchKitApp) || !watchKitApp.Value)
Log.LogError (7020, info, MSBStrings.E7020, name);
if (plist.TryGetValue ("WKWatchKitApp", out watchKitApp)) {
if (!watchKitApp.Value)
Log.LogError (7020, info, MSBStrings.E7020, name);
} else {
isSingleProject = true;
}

if (plist.ContainsKey ("LSRequiresIPhoneOS"))
Log.LogError (7021, info, MSBStrings.E7021, name);

var pluginsDir = Path.Combine (path, "PlugIns");
if (!Directory.Exists (pluginsDir)) {
if (!Directory.Exists (pluginsDir) && !isSingleProject) {
Log.LogError (7022, path, MSBStrings.E7022, name);
return;
}

int count = 0;
foreach (var plugin in Directory.EnumerateDirectories (pluginsDir, "*.appex")) {
ValidateWatchExtension (plugin, bundleIdentifier, shortVersionString, version);
count++;
}
if (!isSingleProject) {
int count = 0;
foreach (var plugin in Directory.EnumerateDirectories (pluginsDir, "*.appex")) {
ValidateWatchExtension (plugin, bundleIdentifier, shortVersionString, version);
count++;
}

if (count == 0)
Log.LogError (7022, pluginsDir, MSBStrings.E7022_A, name);
if (count == 0)
Log.LogError (7022, pluginsDir, MSBStrings.E7022_A, name);
}
}

void ValidateWatchExtension (string path, string watchAppBundleIdentifier, string mainShortVersionString, string mainVersion)
Expand Down
1 change: 1 addition & 0 deletions runtime/exports.t4
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@
"MonoProfileThreadFunc", "end"
) {
XamarinRuntime = RuntimeMode.MonoVM,
Mode = DotNetMode.OnlyLegacy,
},

new Export ("void", "mono_profiler_install_gc",
Expand Down
5 changes: 5 additions & 0 deletions runtime/monovm-bridge.m
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@
* and create a pool that spans the thread's entire lifetime.
*/

#if !DOTNET
static CFMutableDictionaryRef xamarin_thread_hash = NULL;
static pthread_mutex_t thread_hash_lock = PTHREAD_MUTEX_INITIALIZER;

Expand Down Expand Up @@ -296,14 +297,18 @@
// COOP: no managed memory access: any mode.
xamarin_thread_finish (NULL);
}
#endif // !DOTNET

void
xamarin_install_nsautoreleasepool_hooks ()
{
// No need to do anything here for CoreCLR.
#if !DOTNET
// COOP: executed at startup (and no managed memory access): any mode.
xamarin_thread_hash = CFDictionaryCreateMutable (kCFAllocatorDefault, 0, NULL, NULL);

mono_profiler_install_thread (thread_start, thread_end);
#endif // !DOTNET
}

void
Expand Down
9 changes: 7 additions & 2 deletions src/CoreFoundation/CFDataBuffer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,14 @@ public unsafe CFDataBuffer (byte [] buffer)
data = CFData.FromData ((IntPtr) ptr, buffer.Length);
}

public CFDataBuffer (IntPtr ptr)
public CFDataBuffer (IntPtr ptr) : this (ptr, false)
{
data = new CFData (ptr, false);
}


public CFDataBuffer (IntPtr ptr, bool owns)
{
data = new CFData (ptr, owns);
buffer = data.GetBuffer ();
}

Expand Down
Loading

4 comments on commit 870dccc

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ API diff for current PR / commit

Legacy Xamarin (No breaking changes)
.NET (No breaking changes)

❗ API diff vs stable (Breaking changes)

Legacy Xamarin (:heavy_exclamation_mark: Breaking changes :heavy_exclamation_mark:)
.NET (:heavy_exclamation_mark: Breaking changes :heavy_exclamation_mark:)
Legacy Xamarin (stable) vs .NET

ℹ️ Generator diff

Generator Diff: vsdrops (html) vsdrops (raw diff) gist (raw diff) - Please review changes)

Pipeline on Agent
Hash: 870dccc7a585d53f9a7217f863ff647d1671ef06 [CI build]

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💻 [CI Build] Tests on macOS M1 - Mac Big Sur (11.5) passed 💻

All tests on macOS M1 - Mac Big Sur (11.5) passed.

Pipeline on Agent
Hash: 870dccc7a585d53f9a7217f863ff647d1671ef06 [CI build]

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📚 [CI Build] Artifacts 📚

Packages generated

View packages

Pipeline on Agent XAMMINI-053.Monterey'
Hash: 870dccc7a585d53f9a7217f863ff647d1671ef06 [CI build]

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀 [CI Build] Test results 🚀

Test results

✅ All tests passed on VSTS: simulator tests.

🎉 All 223 tests passed 🎉

Tests counts

✅ bcl: All 69 tests passed. Html Report (VSDrops) Download
✅ cecil: All 1 tests passed. Html Report (VSDrops) Download
✅ dotnettests: All 1 tests passed. Html Report (VSDrops) Download
✅ fsharp: All 7 tests passed. Html Report (VSDrops) Download
✅ framework: All 8 tests passed. Html Report (VSDrops) Download
✅ generator: All 2 tests passed. Html Report (VSDrops) Download
✅ interdependent_binding_projects: All 7 tests passed. Html Report (VSDrops) Download
✅ install_source: All 1 tests passed. Html Report (VSDrops) Download
✅ introspection: All 8 tests passed. Html Report (VSDrops) Download
✅ linker: All 65 tests passed. Html Report (VSDrops) Download
✅ mac_binding_project: All 1 tests passed. Html Report (VSDrops) Download
✅ mmp: All 2 tests passed. Html Report (VSDrops) Download
✅ mononative: All 12 tests passed. Html Report (VSDrops) Download
✅ monotouch: All 23 tests passed. Html Report (VSDrops) Download
✅ msbuild: All 2 tests passed. Html Report (VSDrops) Download
✅ mtouch: All 1 tests passed. Html Report (VSDrops) Download
✅ xammac: All 3 tests passed. Html Report (VSDrops) Download
✅ xcframework: All 8 tests passed. Html Report (VSDrops) Download
✅ xtro: All 2 tests passed. Html Report (VSDrops) Download

Pipeline on Agent
Hash: 870dccc7a585d53f9a7217f863ff647d1671ef06 [CI build]

Please sign in to comment.