From 4da7c1a52486964f368f17875910a6468d804552 Mon Sep 17 00:00:00 2001 From: walon Date: Sat, 7 Oct 2023 21:59:48 +0800 Subject: [PATCH] =?UTF-8?q?[change]=20=E6=89=93=E5=8C=85=E6=97=B6=E6=B8=85?= =?UTF-8?q?=E7=A9=BA=E8=A3=81=E5=87=8Faot=20dll=E7=9B=AE=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Editor/BuildProcessors/CopyStrippedAOTAssemblies.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Editor/BuildProcessors/CopyStrippedAOTAssemblies.cs b/Editor/BuildProcessors/CopyStrippedAOTAssemblies.cs index 3e290b5..1d3259e 100644 --- a/Editor/BuildProcessors/CopyStrippedAOTAssemblies.cs +++ b/Editor/BuildProcessors/CopyStrippedAOTAssemblies.cs @@ -1,3 +1,4 @@ +using HybridCLR.Editor.Installer; using System; using System.Collections.Generic; using System.IO; @@ -13,7 +14,7 @@ using UnityEngine; namespace HybridCLR.Editor.BuildProcessors { - internal class CopyStrippedAOTAssemblies : IPostprocessBuildWithReport + internal class CopyStrippedAOTAssemblies : IPostprocessBuildWithReport, IPreprocessBuildWithReport #if !UNITY_2021_1_OR_NEWER , IIl2CppProcessor #endif @@ -95,5 +96,12 @@ namespace HybridCLR.Editor.BuildProcessors } #endif } + + public void OnPreprocessBuild(BuildReport report) + { + BuildTarget target = EditorUserBuildSettings.activeBuildTarget; + var dstPath = SettingsUtil.GetAssembliesPostIl2CppStripDir(target); + BashUtil.RecreateDir(dstPath); + } } }