Skip to content

WIP: Build CoreCLR for Mac Catalyst OS #51000

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 35 commits into from
Closed
Show file tree
Hide file tree
Changes from 13 commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
4981587
Initial support for compiling clr runtime subset against maccatalyst
Mar 31, 2021
b697a83
Fix build on x64
Mar 31, 2021
bd073e5
Merge remote-tracking branch 'origin/main' into maccatalyst-coreclr
Apr 21, 2021
dd65b4e
Allow 'clr' subset to work for Mac Catalyst
Apr 21, 2021
9a0b667
Re-order, so single file host builds after -DTARGET_MACCATALYST is im…
Apr 21, 2021
c813a32
Don't build/depend on Mono corelib
Apr 21, 2021
914c0e6
Better handling of runtimeflavor
Apr 21, 2021
5de69c2
Fix
Apr 21, 2021
397849d
Don't do XplatEventSource on Catalyst
Apr 21, 2021
3694620
Add System.Globalization.Native to build. Removes need for invariant …
Apr 22, 2021
eeba7e6
Allow AppleTestRunner.dll to run on non-mono w/ CoreRun
Apr 22, 2021
28c754b
Add more native libs to the build
Apr 22, 2021
593b42b
Allow AppleAppBuilder to build a CoreCLR Catalyst app
Apr 23, 2021
58e470a
Fix up coreclr runtime template
Apr 26, 2021
a3970e1
Add CoreCLR Catalyst x64 to runtime-staging
Apr 26, 2021
9cc3afc
Merge remote-tracking branch 'origin/main' into maccatalyst-coreclr
Apr 26, 2021
51d2c76
Don't only run Catalyst on FullMatrix
Apr 26, 2021
189422a
Don't hardcode Mono RuntimeFlavor on Catalyst
Apr 26, 2021
5432b12
Treat Catalyst like OSX in AzDO
Apr 26, 2021
52c17ac
Add Catalyst to eng/install-native-dependencies.sh
Apr 26, 2021
a996d91
CoreCLR bypasses build.sh, ensure we pass an OS to build-runtime.sh
Apr 26, 2021
d47bc74
Try passing osArg into native test component build
Apr 26, 2021
80730bf
Don't try to build stuff we aren't targeting on MacCatalyst
Apr 26, 2021
8f25396
Force Flavor to be specified, as we use it for coreclr vs mono Catalyst
Apr 26, 2021
c3433be
Ensure coreclrhost.h is bundled into artifacts folder
Apr 27, 2021
cf6529d
Try to get include folder into mobile runtime pack on mobile
Apr 27, 2021
a03399d
Only build system.buffers.tests for now, to avoid disk full noise in CI
Apr 27, 2021
1d3f34e
Don't exclude libcoreclr.dylib from Resources/
Apr 27, 2021
9958dcf
Fix up coreclr vs mono headers path
Apr 27, 2021
fd9844f
Required Catalyst Helix changes from #51139
Apr 27, 2021
9a0ec57
Typo
Apr 27, 2021
153de52
Fix on ios, clean up unused ObjC code
Apr 27, 2021
0f3ed14
Revert "Only build system.buffers.tests for now, to avoid disk full n…
Apr 27, 2021
e66fefd
Merge remote-tracking branch 'origin/main' into maccatalyst-coreclr
Apr 27, 2021
4c7d848
Skip .dwarf files on Mobile targets, TOO CHONKY
Apr 27, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions eng/Subsets.props
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,12 @@
<PropertyGroup>
<RuntimeFlavor Condition="'$(TargetsMobile)' == 'true'">Mono</RuntimeFlavor>
<RuntimeFlavor Condition="'$(RuntimeFlavor)' == '' and ($(_subset.Contains('+mono+')) or $(_subset.Contains('+mono.runtime+'))) and (!$(_subset.Contains('+clr+')) and !$(_subset.Contains('+clr.runtime+')))">Mono</RuntimeFlavor>
<RuntimeFlavor Condition="'$(RuntimeFlavor)' == ''">CoreCLR</RuntimeFlavor>
<RuntimeFlavor Condition="'$(RuntimeFlavor)' == '' or ((!$(_subset.Contains('+mono+')) and !$(_subset.Contains('+mono.runtime+'))) and ($(_subset.Contains('+clr+')) or $(_subset.Contains('+clr.runtime+'))))">CoreCLR</RuntimeFlavor>
</PropertyGroup>

<PropertyGroup>
<DefaultCoreClrSubsets>clr.native+linuxdac+clr.corelib+clr.tools+clr.nativecorelib+clr.packages</DefaultCoreClrSubsets>
<DefaultCoreClrSubsets>clr.native+clr.corelib</DefaultCoreClrSubsets>
<DefaultCoreClrSubsets Condition="'$(TargetOS)' != 'MacCatalyst'">$(DefaultCoreClrSubsets)+linuxdac+clr.tools+clr.nativecorelib+clr.packages</DefaultCoreClrSubsets>

<DefaultMonoSubsets Condition="'$(MonoEnableLLVM)' == 'true' and '$(MonoLLVMDir)' == ''">mono.llvm+</DefaultMonoSubsets>
<DefaultMonoSubsets Condition="'$(MonoAOTEnableLLVM)' == 'true' and '$(MonoAOTLLVMDir)' == ''">mono.llvm+</DefaultMonoSubsets>
Expand Down
4 changes: 3 additions & 1 deletion eng/liveBuilds.targets
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@
<TargetPath>runtime/$(CoreCLRCrossTargetComponentDirName)_$(TargetArchitecture)/native</TargetPath>
<IsNative>true</IsNative>
</CoreCLRCrossTargetFiles>
<RuntimeIncludeFiles Condition="'$(TargetsMobile)' == 'true'"
Include="$(CoreCLRArtifactsPath)\..\..\..\..\src\coreclr\hosts\inc\**\*.*" />
</ItemGroup>
<ItemGroup Condition="'$(RuntimeFlavor)' == 'Mono'">
<RuntimeFiles Include="$(MonoArtifactsPath)\*.*" />
Expand All @@ -111,7 +113,7 @@

<MonoCrossFiles Condition="'$(TargetsMobile)' == 'true'"
Include="$(MonoArtifactsPath)\cross\**\*.*" />
<MonoIncludeFiles Condition="'$(TargetsMobile)' == 'true'"
<RuntimeIncludeFiles Condition="'$(TargetsMobile)' == 'true'"
Include="$(MonoArtifactsPath)\include\**\*.*" />
</ItemGroup>

Expand Down
6 changes: 4 additions & 2 deletions eng/testing/tests.mobile.targets
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<UseDefaultAndroidFeatureSwitches Condition="'$(UseDefaultAndroidFeatureSwitches)' == ''">true</UseDefaultAndroidFeatureSwitches>
<UseDefaultiOSFeatureSwitches Condition="'$(UseDefaultiOSFeatureSwitches)' == ''">true</UseDefaultiOSFeatureSwitches>
<BundleTestAppTargets>BundleTestAppleApp;BundleTestAndroidApp</BundleTestAppTargets>
<RuntimeFlavor Condition="'$(RuntimeFlavor)' == ''">mono</RuntimeFlavor>
</PropertyGroup>

<PropertyGroup Condition="'$(TargetOS)' == 'Android' and '$(UseDefaultAndroidFeatureSwitches)' == 'true'">
Expand Down Expand Up @@ -190,7 +191,7 @@
TargetOS="$(TargetOS)"
Arch="$(TargetArchitecture)"
ProjectName="$(AssemblyName)"
MonoRuntimeHeaders="$(MicrosoftNetCoreAppRuntimePackNativeDir)include\mono-2.0"
RuntimeHeaders="$(MicrosoftNetCoreAppRuntimePackNativeDir)include"
Assemblies="@(BundleAssemblies)"
MainLibraryFileName="$(MainLibraryFileName)"
ForceAOT="$(RunAOTCompilation)"
Expand All @@ -202,7 +203,8 @@
Optimized="$(Optimized)"
DevTeamProvisioning="$(DevTeamProvisioning)"
OutputDirectory="$(BundleDir)"
AppDir="$(PublishDir)">
AppDir="$(PublishDir)"
RuntimeFlavor="$(RuntimeFlavor)">
<Output TaskParameter="AppBundlePath" PropertyName="AppBundlePath" />
<Output TaskParameter="XcodeProjectPath" PropertyName="XcodeProjectPath" />
</AppleAppBuilderTask>
Expand Down
17 changes: 9 additions & 8 deletions src/coreclr/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,6 @@ include(pgosupport.cmake)
#---------------------------------------------------
include(components.cmake)

#---------------------------
# Build the single file host
#---------------------------
if(NOT CLR_CROSS_COMPONENTS_BUILD)
set(CLR_SINGLE_FILE_HOST_ONLY 1)
add_subdirectory(${CLR_SRC_NATIVE_DIR}/corehost/apphost/static Corehost.Static)
add_dependencies(runtime singlefilehost)
endif()
#-------------------------
# Enable C++ EH with SEH
#-------------------------
Expand Down Expand Up @@ -143,6 +135,15 @@ endif(CLR_CMAKE_HOST_WIN32)
#----------------------------------
include(clrdefinitions.cmake)

#---------------------------
# Build the single file host
#---------------------------
if(NOT CLR_CROSS_COMPONENTS_BUILD)
set(CLR_SINGLE_FILE_HOST_ONLY 1)
add_subdirectory(${CLR_SRC_NATIVE_DIR}/corehost/apphost/static Corehost.Static)
add_dependencies(runtime singlefilehost)
endif()

if(FEATURE_STANDALONE_GC)
add_definitions(-DFEATURE_STANDALONE_GC)
add_subdirectory(gc)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
<ILLinkDirectory>$(MSBuildThisFileDirectory)src\ILLink\</ILLinkDirectory>

<FeaturePortableThreadPool>true</FeaturePortableThreadPool>

<IsiOSLike Condition="'$(TargetsMacCatalyst)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true'">true</IsiOSLike>
</PropertyGroup>

<ItemGroup>
Expand Down Expand Up @@ -287,6 +289,12 @@
<Compile Include="$(BclSourcesRoot)\System\Runtime\InteropServices\CustomMarshalers\TypeToTypeInfoMarshaler.cs" />
<Compile Include="$(BclSourcesRoot)\System\Variant.cs" />
</ItemGroup>
<ItemGroup Condition="'$(IsiOSLike)' == 'true'">
<Compile Include="$(BclSourcesRoot)\System\Environment.iOS.cs"/>
<Compile Include="$(CommonPath)Interop\OSX\System.Native\Interop.SearchPath.cs">
<Link>Common\Interop\OSX\Interop.SearchPath.cs</Link>
</Compile>
</ItemGroup>
<ItemGroup Condition="'$(TargetsUnix)' == 'true'">
<Compile Include="$(BclSourcesRoot)\Interop\Unix\Interop.Libraries.cs" />
<Compile Include="$(BclSourcesRoot)\System\Threading\ClrThreadPoolBoundHandle.Unix.cs" />
Expand Down
105 changes: 105 additions & 0 deletions src/coreclr/System.Private.CoreLib/src/System/Environment.iOS.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System.IO;
using System.Threading;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using NSSearchPathDirectory = Interop.Sys.NSSearchPathDirectory;

namespace System
{
public static partial class Environment
{
private static Dictionary<SpecialFolder, string>? s_specialFolders;

private static string GetFolderPathCore(SpecialFolder folder, SpecialFolderOption option)
{
if (s_specialFolders == null)
{
Interlocked.CompareExchange(ref s_specialFolders, new Dictionary<SpecialFolder, string>(), null);
}

string? path;
lock (s_specialFolders)
{
if (!s_specialFolders.TryGetValue(folder, out path))
{
path = GetSpecialFolder(folder) ?? string.Empty;
s_specialFolders[folder] = path;
}
}
return path;
}

private static string? GetSpecialFolder(SpecialFolder folder)
{
switch (folder)
{
// TODO: fix for tvOS (https://github.com/dotnet/runtime/issues/34007)
// The "normal" NSDocumentDirectory is a read-only directory on tvOS
// and that breaks a lot of assumptions in the runtime and the BCL

case SpecialFolder.Personal:
case SpecialFolder.LocalApplicationData:
return Interop.Sys.SearchPath(NSSearchPathDirectory.NSDocumentDirectory);

case SpecialFolder.ApplicationData:
// note: at first glance that looked like a good place to return NSLibraryDirectory
// but it would break isolated storage for existing applications
return CombineSearchPath(NSSearchPathDirectory.NSDocumentDirectory, ".config");

case SpecialFolder.Resources:
return Interop.Sys.SearchPath(NSSearchPathDirectory.NSLibraryDirectory); // older (8.2 and previous) would return String.Empty

case SpecialFolder.Desktop:
case SpecialFolder.DesktopDirectory:
return Path.Combine(GetFolderPathCore(SpecialFolder.Personal, SpecialFolderOption.None), "Desktop");

case SpecialFolder.MyMusic:
return Path.Combine(GetFolderPathCore(SpecialFolder.Personal, SpecialFolderOption.None), "Music");

case SpecialFolder.MyPictures:
return Path.Combine(GetFolderPathCore(SpecialFolder.Personal, SpecialFolderOption.None), "Pictures");

case SpecialFolder.Templates:
return CombineSearchPath(NSSearchPathDirectory.NSDocumentDirectory, "Templates");

case SpecialFolder.MyVideos:
return Path.Combine(GetFolderPathCore(SpecialFolder.Personal, SpecialFolderOption.None), "Videos");

case SpecialFolder.CommonTemplates:
return "/usr/share/templates";

case SpecialFolder.Fonts:
return CombineSearchPath(NSSearchPathDirectory.NSDocumentDirectory, ".fonts");

case SpecialFolder.Favorites:
return CombineSearchPath(NSSearchPathDirectory.NSLibraryDirectory, "Favorites");

case SpecialFolder.ProgramFiles:
return Interop.Sys.SearchPath(NSSearchPathDirectory.NSApplicationDirectory);

case SpecialFolder.InternetCache:
return Interop.Sys.SearchPath(NSSearchPathDirectory.NSCachesDirectory);

case SpecialFolder.UserProfile:
return GetEnvironmentVariable("HOME");

case SpecialFolder.CommonApplicationData:
return "/usr/share";

default:
return string.Empty;
}

static string CombineSearchPath(NSSearchPathDirectory searchPath, string subdirectory)
{
string? path = Interop.Sys.SearchPath(searchPath);
return path != null ?
Path.Combine(path, subdirectory) :
string.Empty;
}
}
}
}
2 changes: 1 addition & 1 deletion src/coreclr/clr.featuredefines.props
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
</PropertyGroup>

<PropertyGroup Condition="'$(TargetsUnix)' == 'true'">
<FeatureXplatEventSource Condition="'$(TargetOS)'!='OSX'">true</FeatureXplatEventSource>
<FeatureXplatEventSource Condition="'$(TargetOS)'!='OSX' and '$(TargetOS)' != 'MacCatalyst'">true</FeatureXplatEventSource>

<FeatureArrayStubAsIL>true</FeatureArrayStubAsIL>
<FeatureMulticastStubAsIL>true</FeatureMulticastStubAsIL>
Expand Down
4 changes: 4 additions & 0 deletions src/coreclr/clrdefinitions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,10 @@ if(CLR_CMAKE_TARGET_OSX)
add_definitions(-DFEATURE_WRITEBARRIER_COPY)
endif(CLR_CMAKE_TARGET_OSX)

if(CLR_CMAKE_TARGET_MACCATALYST)
add_definitions(-DTARGET_MACCATALYST)
endif(CLR_CMAKE_TARGET_MACCATALYST)

if (NOT CLR_CMAKE_TARGET_ARCH_I386 OR NOT CLR_CMAKE_TARGET_WIN32)
add_compile_definitions($<$<NOT:$<BOOL:$<TARGET_PROPERTY:IGNORE_DEFAULT_TARGET_ARCH>>>:FEATURE_EH_FUNCLETS>)
endif (NOT CLR_CMAKE_TARGET_ARCH_I386 OR NOT CLR_CMAKE_TARGET_WIN32)
Expand Down
4 changes: 4 additions & 0 deletions src/coreclr/dlls/mscoree/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ list(APPEND CLR_SOURCES
Native.rc
)

if(CLR_CMAKE_TARGET_MACCATALYST)
add_definitions(-DTARGET_MACCATALYST)
endif(CLR_CMAKE_TARGET_MACCATALYST)

set (DEF_SOURCES
mscorwks_ntdef.src
)
Expand Down
4 changes: 2 additions & 2 deletions src/coreclr/dlls/mscoree/coreclr/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,11 @@ else(CLR_CMAKE_HOST_WIN32)
set(END_WHOLE_ARCHIVE -Wl,--no-whole-archive)
endif(CLR_CMAKE_TARGET_LINUX OR CLR_CMAKE_TARGET_FREEBSD OR CLR_CMAKE_TARGET_NETBSD OR CLR_CMAKE_TARGET_SUNOS)

if(CLR_CMAKE_TARGET_OSX)
if(CLR_CMAKE_TARGET_OSX OR CLR_CMAKE_TARGET_MACCATALYST)
# These options are used to force every object to be included even if it's unused.
set(START_WHOLE_ARCHIVE -force_load)
set(END_WHOLE_ARCHIVE )
endif(CLR_CMAKE_TARGET_OSX)
endif(CLR_CMAKE_TARGET_OSX OR CLR_CMAKE_TARGET_MACCATALYST)

set_exports_linker_option(${EXPORTS_FILE})

Expand Down
8 changes: 7 additions & 1 deletion src/coreclr/hosts/inc/coreclrhost.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,19 @@
#define CORECLR_CALLING_CONVENTION
#endif

#ifndef __OBJC__
#define CORECLR_EXTERN_C extern "C"
#else
#define CORECLR_EXTERN_C
#endif

#include <stdint.h>

// For each hosting API, we define a function prototype and a function pointer
// The prototype is useful for implicit linking against the dynamic coreclr
// library and the pointer for explicit dynamic loading (dlopen, LoadLibrary)
#define CORECLR_HOSTING_API(function, ...) \
extern "C" int CORECLR_CALLING_CONVENTION function(__VA_ARGS__); \
CORECLR_EXTERN_C int CORECLR_CALLING_CONVENTION function(__VA_ARGS__); \
typedef int (CORECLR_CALLING_CONVENTION *function##_ptr)(__VA_ARGS__)

//
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/jit/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,7 @@ endif (FEATURE_MERGE_JIT_AND_ENGINE)
# Creates a static library "clrjit_static" to link into the VM.
add_subdirectory(static)

if (CLR_CMAKE_TARGET_OSX AND CLR_CMAKE_TARGET_ARCH_ARM64)
if ((CLR_CMAKE_TARGET_OSX OR CLR_CMAKE_TARGET_MACCATALYST) AND CLR_CMAKE_TARGET_ARCH_ARM64)
set(TARGET_OS_NAME unix_osx) # Apple Arm64 has a special ABI, distinguish it.
elseif (CLR_CMAKE_TARGET_UNIX)
set(TARGET_OS_NAME unix)
Expand Down
4 changes: 4 additions & 0 deletions src/coreclr/pal/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ if(CLR_CMAKE_USE_SYSTEM_LIBUNWIND)
add_definitions(-DFEATURE_USE_SYSTEM_LIBUNWIND)
endif(CLR_CMAKE_USE_SYSTEM_LIBUNWIND)

if(CLR_CMAKE_TARGET_MACCATALYST)
add_definitions(-DTARGET_MACCATALYST)
endif(CLR_CMAKE_TARGET_MACCATALYST)

if(CLR_CMAKE_TARGET_OSX)
add_definitions(-DTARGET_OSX)
if(CLR_CMAKE_TARGET_ARCH_AMD64)
Expand Down
17 changes: 13 additions & 4 deletions src/coreclr/pal/src/configure.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ elseif(CLR_CMAKE_TARGET_SUNOS)
set(CMAKE_REQUIRED_INCLUDES /opt/local/include)
endif()

if(CLR_CMAKE_TARGET_OSX)
if(CLR_CMAKE_TARGET_OSX OR CLR_CMAKE_TARGET_MACCATALYST)
set(CMAKE_REQUIRED_DEFINITIONS -D_XOPEN_SOURCE)
elseif(NOT CLR_CMAKE_TARGET_FREEBSD AND NOT CLR_CMAKE_TARGET_NETBSD)
set(CMAKE_REQUIRED_DEFINITIONS "-D_BSD_SOURCE -D_SVID_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200809L")
Expand Down Expand Up @@ -1321,7 +1321,17 @@ if(NOT CLR_CMAKE_HOST_ARCH_ARM AND NOT CLR_CMAKE_HOST_ARCH_ARM64)
set(CMAKE_REQUIRED_LIBRARIES)
endif()

if(CLR_CMAKE_TARGET_OSX)
if(CLR_CMAKE_TARGET_MACCATALYST)
set(HAVE__NSGETENVIRON 1)
set(DEADLOCK_WHEN_THREAD_IS_SUSPENDED_WHILE_BLOCKED_ON_MUTEX 1)
set(PAL_PTRACE "ptrace((cmd), (pid), (caddr_t)(addr), (data))")
set(PAL_PT_ATTACH PT_ATTACH)
set(PAL_PT_DETACH PT_DETACH)
set(PAL_PT_READ_D PT_READ_D)
set(PAL_PT_WRITE_D PT_WRITE_D)
set(HAS_FTRUNCATE_LENGTH_ISSUE 1)
set(HAVE_SCHED_OTHER_ASSIGNABLE 1)
elseif(CLR_CMAKE_TARGET_OSX)
set(HAVE__NSGETENVIRON 1)
set(DEADLOCK_WHEN_THREAD_IS_SUSPENDED_WHILE_BLOCKED_ON_MUTEX 1)
set(PAL_PTRACE "ptrace((cmd), (pid), (caddr_t)(addr), (data))")
Expand All @@ -1331,7 +1341,6 @@ if(CLR_CMAKE_TARGET_OSX)
set(PAL_PT_WRITE_D PT_WRITE_D)
set(HAS_FTRUNCATE_LENGTH_ISSUE 1)
set(HAVE_SCHED_OTHER_ASSIGNABLE 1)

elseif(CLR_CMAKE_TARGET_FREEBSD)
set(DEADLOCK_WHEN_THREAD_IS_SUSPENDED_WHILE_BLOCKED_ON_MUTEX 0)
set(PAL_PTRACE "ptrace((cmd), (pid), (caddr_t)(addr), (data))")
Expand Down Expand Up @@ -1374,7 +1383,7 @@ else() # Anything else is Linux
set(PAL_PT_WRITE_D PTRACE_POKEDATA)
set(HAS_FTRUNCATE_LENGTH_ISSUE 0)
set(HAVE_SCHED_OTHER_ASSIGNABLE 1)
endif(CLR_CMAKE_TARGET_OSX)
endif(CLR_CMAKE_TARGET_MACCATALYST)

check_struct_has_member(
"struct statfs"
Expand Down
10 changes: 9 additions & 1 deletion src/coreclr/pal/src/map/virtual.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1760,7 +1760,7 @@ VirtualProtect(
return bRetVal;
}

#if defined(HOST_OSX) && defined(HOST_ARM64)
#if defined(HOST_OSX) && defined(HOST_ARM64) && !defined(TARGET_MACCATALYST)
bool
PAL_JITWriteEnableHolder::JITWriteEnable(bool writeEnable)
{
Expand All @@ -1777,6 +1777,14 @@ PAL_JITWriteEnableHolder::JITWriteEnable(bool writeEnable)
}
#endif

#if defined(HOST_ARM64) && defined(TARGET_MACCATALYST)
bool
PAL_JITWriteEnableHolder::JITWriteEnable(bool writeEnable)
{
return false;
}
#endif

#if HAVE_VM_ALLOCATE
//---------------------------------------------------------------------------------------
//
Expand Down
2 changes: 2 additions & 0 deletions src/coreclr/pal/src/misc/dbgmsg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -821,6 +821,7 @@ void PAL_DisplayDialog(const char *szTitle, const char *szText)
if (cfsText != NULL)
{
CFOptionFlags response;
#if !defined(TARGET_MACCATALYST)
CFUserNotificationDisplayAlert(0, // Never time-out, wait for user to hit 'OK'
0, // No flags
NULL, // Default icon
Expand All @@ -832,6 +833,7 @@ void PAL_DisplayDialog(const char *szTitle, const char *szText)
NULL, // No alternate button
NULL, // No third button
&response); // User's response (discarded)
#endif
CFRelease(cfsText);
}
CFRelease(cfsTitle);
Expand Down
Loading