diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index b352d4e4a200ba..a5a55f1647d432 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -54,6 +54,10 @@
https://github.com/dotnet/arcade
4b7c80f398fd3dcea03fdc4e454789b61181d300
+
+ https://github.com/dotnet/arcade
+ 4b7c80f398fd3dcea03fdc4e454789b61181d300
+
https://github.com/dotnet/arcade
4b7c80f398fd3dcea03fdc4e454789b61181d300
diff --git a/eng/Versions.props b/eng/Versions.props
index 84082898866e8c..097869c3698286 100644
--- a/eng/Versions.props
+++ b/eng/Versions.props
@@ -63,6 +63,7 @@
7.0.0-beta.21463.4
7.0.0-beta.21463.4
7.0.0-beta.21463.4
+ 7.0.0-beta.21463.4
7.0.0-beta.21463.4
7.0.0-beta.21463.4
7.0.0-beta.21463.4
diff --git a/src/installer/pkg/sfx/installers/dotnet-host.proj b/src/installer/pkg/sfx/installers/dotnet-host.proj
index 953b0f4f8522f9..aba056f06d17cb 100644
--- a/src/installer/pkg/sfx/installers/dotnet-host.proj
+++ b/src/installer/pkg/sfx/installers/dotnet-host.proj
@@ -15,7 +15,7 @@
true
sharedhost
false
- osx_scripts/host
+ osx_scripts/host
The .NET Shared Host.
$(MSBuildThisFileDirectory)rpm_scripts/host
$(RpmScriptsDirectory)/after_install.sh
@@ -78,4 +78,36 @@
+
+
+ <_MacOSIntermediatesPath>$(IntermediateOutputPath)macos/
+
+ $(_MacOSIntermediatesPath)scripts
+
+
+ <_MacOSScript Include="$(MacOSScriptsTemplateDirectory)/*" Destination="$(MacOSScriptsDirectory)/%(FileName)%(Extension)"/>
+
+
+
+
+ <_UnameMachineRegex>$(InstallerTargetArchitecture)
+ <_UnameMachineRegex Condition="'$(InstallerTargetArchitecture)' == 'arm64'">arm64|aarch64
+ <_UnameMachineRegex Condition="'$(InstallerTargetArchitecture)' == 'x64'">amd64|x86_64
+ <_MacOSScriptsTemplateProperties>InstallerTargetArchitecture=$(InstallerTargetArchitecture);UnameMachineRegex=$(_UnameMachineRegex)
+
+
+
+
+
+
+
+
+
+
diff --git a/src/installer/pkg/sfx/installers/dotnet-hostfxr.proj b/src/installer/pkg/sfx/installers/dotnet-hostfxr.proj
index 2c5fa5d8188867..b9eb792a38fade 100644
--- a/src/installer/pkg/sfx/installers/dotnet-hostfxr.proj
+++ b/src/installer/pkg/sfx/installers/dotnet-hostfxr.proj
@@ -14,7 +14,6 @@
HostFxrSrc
true
hostfxr
- osx_scripts/hostfxr
The .NET HostFxr
diff --git a/src/installer/pkg/sfx/installers/osx_scripts/host/postinstall b/src/installer/pkg/sfx/installers/osx_scripts/host/postinstall
index 531cb93fd382fc..eaee94e2798738 100755
--- a/src/installer/pkg/sfx/installers/osx_scripts/host/postinstall
+++ b/src/installer/pkg/sfx/installers/osx_scripts/host/postinstall
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
#
# Licensed to the .NET Foundation under one or more agreements.
# The .NET Foundation licenses this file to you under the MIT license.
@@ -10,9 +10,21 @@ INSTALL_DESTINATION=$2
# A temporary fix for the permissions issue(s)
chmod 755 $INSTALL_DESTINATION/dotnet
-# Add the installation directory to the system-wide paths
-# But first create the directory if it doesn't exist
-mkdir -p /etc/paths.d
-echo $INSTALL_DESTINATION | tee /etc/paths.d/dotnet
+if [ -e /etc/dotnet/install_location ]; then
+ # clear out any entries for this architecture if they exist
+ sed -i old '/^${InstallerTargetArchitecture}=/d' /etc/dotnet/install_location
+else
+ mkdir -p /etc/dotnet
+fi
+
+echo ${InstallerTargetArchitecture}=$INSTALL_DESTINATION | tee -a /etc/dotnet/install_location
+
+# if we're running on the native architecture
+if [[ "$(uname -m)" =~ "${UnameMachineRegex}" ]]; then
+ # Add the installation directory to the system-wide paths
+ # But first create the directory if it doesn't exist
+ mkdir -p /etc/paths.d
+ echo $INSTALL_DESTINATION | tee /etc/paths.d/dotnet
+fi
exit 0
diff --git a/src/installer/pkg/sfx/installers/osx_scripts/hostfxr/postinstall b/src/installer/pkg/sfx/installers/osx_scripts/hostfxr/postinstall
deleted file mode 100755
index 2d0ceb82786936..00000000000000
--- a/src/installer/pkg/sfx/installers/osx_scripts/hostfxr/postinstall
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-#
-# Licensed to the .NET Foundation under one or more agreements.
-# The .NET Foundation licenses this file to you under the MIT license.
-#
-
-PACKAGE=$1
-INSTALL_DESTINATION=$2
-
-# A temporary fix for the permissions issue(s)
-chmod 755 $INSTALL_DESTINATION/dotnet
-
-# Add the installation directory to the system-wide paths
-echo $INSTALL_DESTINATION | tee /etc/paths.d/dotnet
-
-exit 0