diff --git a/Directory.Build.props b/Directory.Build.props
index 1e4aec17d15c0..a365e35d38fdb 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -192,6 +192,17 @@
$([MSBuild]::NormalizeDirectory($(WasmProjectRoot), 'build'))
+
+ true
+ true
+
+
+
+ true
+ android+browser+wasi
+ $(MonoCrossAOTTargetOS)+tvos+ios+maccatalyst
+
+
false
true
diff --git a/eng/DotNetBuild.props b/eng/DotNetBuild.props
index a1a8affb5cd6e..49f7bdaf9cf34 100644
--- a/eng/DotNetBuild.props
+++ b/eng/DotNetBuild.props
@@ -65,10 +65,11 @@
$(InnerBuildArgs) /p:AdditionalRuntimeIdentifierParent=$(BaseOS) /p:BaseOS=$(BaseOS)
$(InnerBuildArgs) /p:WasmEnableThreads=true
- $(InnerBuildArgs) $(FlagParameterPrefix)s clr.nativeaotlibs+clr.nativeaotruntime+libs+packs /p:BuildNativeAOTRuntimePack=true /p:SkipLibrariesNativeRuntimePackages=true
+ $(InnerBuildArgs) /p:DotNetBuildRuntimeNativeAOTRuntimePack=$(DotNetBuildRuntimeNativeAOTRuntimePack)
$(InnerBuildArgs) /p:MonoEnableLLVM=$(DotNetBuildMonoEnableLLVM)
$(InnerBuildArgs) /p:MonoAOTEnableLLVM=$(DotNetBuildMonoAOTEnableLLVM)
$(InnerBuildArgs) /p:MonoBundleLLVMOptimizer=$(DotNetBuildMonoBundleLLVMOptimizer)
+ $(InnerBuildArgs) /p:DotNetBuildMonoCrossAOT=$(DotNetBuildMonoCrossAOT)
$(InnerBuildArgs) $(FlagParameterPrefix)pgoinstrument
diff --git a/eng/Subsets.props b/eng/Subsets.props
index 969b8bd4c851e..313cbe3d54c8b 100644
--- a/eng/Subsets.props
+++ b/eng/Subsets.props
@@ -41,6 +41,8 @@
mono+libs+host+packs
clr+libs+tools+host+packs
+ clr.nativeaotlibs+clr.nativeaotruntime+libs+packs
+ mono+packs
diff --git a/eng/pipelines/runtime-official.yml b/eng/pipelines/runtime-official.yml
index 0309f659133e3..e3e10911f52e9 100644
--- a/eng/pipelines/runtime-official.yml
+++ b/eng/pipelines/runtime-official.yml
@@ -281,7 +281,7 @@ extends:
- windows_arm64
jobParameters:
templatePath: 'templates-official'
- buildArgs: -s clr.nativeaotlibs+clr.nativeaotruntime+libs+packs -c $(_BuildConfig) /p:BuildNativeAOTRuntimePack=true /p:SkipLibrariesNativeRuntimePackages=true
+ buildArgs: -c $(_BuildConfig) /p:DotNetBuildRuntimeNativeAOTRuntimePack=true
nameSuffix: NativeAOT
isOfficialBuild: ${{ variables.isOfficialBuild }}
postBuildSteps:
@@ -406,50 +406,13 @@ extends:
- linux_musl_x64
- linux_arm64
- linux_musl_arm64
- jobParameters:
- templatePath: 'templates-official'
- buildArgs: -s mono+packs -c $(_BuildConfig)
- /p:MonoCrossAOTTargetOS=android+browser+wasi /p:BuildMonoAOTCrossCompilerOnly=true
- nameSuffix: CrossAOT_Mono
- runtimeVariant: crossaot
- isOfficialBuild: ${{ variables.isOfficialBuild }}
- postBuildSteps:
- - template: /eng/pipelines/common/upload-intermediate-artifacts-step.yml
- parameters:
- name: MonoRuntimePacks
-
- - template: /eng/pipelines/common/platform-matrix.yml
- parameters:
- jobTemplate: /eng/pipelines/common/global-build-job.yml
- runtimeFlavor: mono
- buildConfig: release
- platforms:
- windows_arm64
- windows_x64
- jobParameters:
- templatePath: 'templates-official'
- buildArgs: -s mono+packs -c $(_BuildConfig)
- /p:MonoCrossAOTTargetOS=android+browser+wasi /p:BuildMonoAOTCrossCompilerOnly=true
- nameSuffix: CrossAOT_Mono
- runtimeVariant: crossaot
- isOfficialBuild: ${{ variables.isOfficialBuild }}
- postBuildSteps:
- - template: /eng/pipelines/common/upload-intermediate-artifacts-step.yml
- parameters:
- name: MonoRuntimePacks
-
- - template: /eng/pipelines/common/platform-matrix.yml
- parameters:
- jobTemplate: /eng/pipelines/common/global-build-job.yml
- runtimeFlavor: mono
- buildConfig: release
- platforms:
- osx_x64
- osx_arm64
jobParameters:
templatePath: 'templates-official'
- buildArgs: -s mono+packs -c $(_BuildConfig)
- /p:MonoCrossAOTTargetOS=android+browser+wasi+tvos+ios+maccatalyst /p:BuildMonoAOTCrossCompilerOnly=true
+ buildArgs: -c $(_BuildConfig) /p:DotNetBuildMonoCrossAOT=true
nameSuffix: CrossAOT_Mono
runtimeVariant: crossaot
isOfficialBuild: ${{ variables.isOfficialBuild }}
diff --git a/eng/pipelines/runtime.yml b/eng/pipelines/runtime.yml
index 56faff436d07e..01788474bd3b5 100644
--- a/eng/pipelines/runtime.yml
+++ b/eng/pipelines/runtime.yml
@@ -1179,6 +1179,7 @@ extends:
#
# Build Mono release AOT cross-compilers
+ # Only when mono changed
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
@@ -1190,51 +1191,12 @@ extends:
- linux_musl_x64
- linux_arm64
- linux_musl_arm64
- jobParameters:
- buildArgs: -s mono+packs -c $(_BuildConfig)
- /p:MonoCrossAOTTargetOS=android+browser+wasi /p:BuildMonoAOTCrossCompilerOnly=true
- nameSuffix: CrossAOT_Mono
- runtimeVariant: crossaot
- condition: >-
- or(
- eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_mono_excluding_wasm.containsChange'], true),
- eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_installer.containsChange'], true),
- eq(variables['isRollingBuild'], true))
-
- - template: /eng/pipelines/common/platform-matrix.yml
- parameters:
- jobTemplate: /eng/pipelines/common/global-build-job.yml
- runtimeFlavor: mono
- buildConfig: release
- platforms:
- windows_arm64
- windows_x64
- jobParameters:
- buildArgs: -s mono+packs -c $(_BuildConfig)
- /p:MonoCrossAOTTargetOS=android+browser+wasi /p:BuildMonoAOTCrossCompilerOnly=true
- nameSuffix: CrossAOT_Mono
- runtimeVariant: crossaot
- condition: >-
- or(
- eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_mono_excluding_wasm.containsChange'], true),
- eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_installer.containsChange'], true),
- eq(variables['isRollingBuild'], true))
- #
- # Build Mono release AOT cross-compilers
- # Only when mono changed
- #
-
- - template: /eng/pipelines/common/platform-matrix.yml
- parameters:
- jobTemplate: /eng/pipelines/common/global-build-job.yml
- runtimeFlavor: mono
- buildConfig: release
- platforms:
- osx_x64
- osx_arm64
jobParameters:
- buildArgs: -s mono+packs -c $(_BuildConfig)
- /p:MonoCrossAOTTargetOS=android+browser+wasi+tvos+ios+maccatalyst /p:BuildMonoAOTCrossCompilerOnly=true
+ buildArgs: -c $(_BuildConfig) /p:DotNetBuildMonoCrossAOT=true
nameSuffix: CrossAOT_Mono
runtimeVariant: crossaot
condition: >-