diff --git a/Editor/Installer/UpdateController.cs b/Editor/Installer/UpdateController.cs
index 8fe5549..c1e133c 100644
--- a/Editor/Installer/UpdateController.cs
+++ b/Editor/Installer/UpdateController.cs
@@ -11,7 +11,7 @@
var ret1 = BashUtil.RunCommand2(hybridclrRepoDir, "git",
new string[] { "log", "HEAD", "-n", "1", "--pretty=format:\"%H\"", });
BashUtil.RunCommand2(hybridclrRepoDir, "git",
- new string[] { "fetch", "depth=1" });
+ new string[] { "fetch", "--depth=1" });
var ret2 = BashUtil.RunCommand2(hybridclrRepoDir, "git",
new string[] { "log", "remotes/origin/HEAD", "-n", "1", "--pretty=format:\"%H\"", });
if (ret1.StdOut != ret2.StdOut)
@@ -25,7 +25,7 @@
var ret1 = BashUtil.RunCommand2(il2cppPlusRepoDir, "git",
new string[] { "log", $"{il2cppBranch}", "-n", "1", "--pretty=format:\"%H\"", });
BashUtil.RunCommand2(il2cppPlusRepoDir, "git",
- new string[] { "fetch", "depth=1" });
+ new string[] { "fetch", "--depth=1" });
var ret2 = BashUtil.RunCommand2(il2cppPlusRepoDir, "git",
new string[] { "log", $"remotes/origin/{il2cppBranch}", "-n", "1", "--pretty=format:\"%H\"", });
if (ret1.StdOut != ret2.StdOut)
diff --git a/Runtime/RuntimeApi.cs b/Runtime/RuntimeApi.cs
index 3019212..c87af14 100644
--- a/Runtime/RuntimeApi.cs
+++ b/Runtime/RuntimeApi.cs
@@ -56,10 +56,28 @@ namespace HybridCLR
// }
//}
+ ///
+ /// 指示混合执行assembly使用原始的AOT代码。当assembly没有发生变化时必须调用此接口。
+ ///
+ ///
+ ///
+#if UNITY_EDITOR
+ public static LoadImageErrorCode UseDifferentialHybridAOTAssembly(string assemblyName)
+ {
+ return LoadImageErrorCode.OK;
+ }
+#else
[DllImport(dllName, EntryPoint = "RuntimeApi_UseDifferentialHybridAOTAssembly")]
public static extern LoadImageErrorCode UseDifferentialHybridAOTAssembly(string assemblyName);
+#endif
+ ///
+ /// 加载差分混合执行 assembly
+ ///
+ ///
+ ///
+ ///
public static unsafe LoadImageErrorCode LoadDifferentialHybridAssembly(byte[] dllBytes, byte[] optionBytes)
{
#if UNITY_EDITOR
@@ -67,16 +85,16 @@ namespace HybridCLR
#else
fixed(byte* dllBytesPtr = dllBytes)
{
- fixed(byte* tokenPtr = optionBytes)
+ fixed(byte* optionBytesPtr = optionBytes)
{
- return (LoadImageErrorCode)LoadDifferentialHybridAssembly(dllBytesPtr, dllBytes.Length, tokenPtr, optionBytes.Length);
+ return (LoadImageErrorCode)LoadDifferentialHybridAssembly(dllBytesPtr, dllBytes.Length, optionBytesPtr, optionBytes.Length);
}
}
#endif
}
[DllImport(dllName, EntryPoint = "RuntimeApi_LoadDifferentialHybridAssembly")]
- public static extern unsafe int LoadDifferentialHybridAssembly(byte* dllBytes, int dllSize, byte* notChangeMethodTokens, int tokenCount);
+ public static extern unsafe int LoadDifferentialHybridAssembly(byte* dllBytes, int dllSize, byte* optionBytesPtr, int optionBytesLength);
///
/// 获取解释器线程栈的最大StackObject个数(size*8 为最终占用的内存大小)
diff --git a/package.json b/package.json
index 3bfd478..d00df7c 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "com.focus-creative-games.hybridclr_unity",
- "version": "0.10.0",
+ "version": "0.10.1",
"displayName": "HybridCLR",
"description": "Unity package for HybridCLR. It includes editor and runtime scripts and assets for HybridCLR",
"category": "Runtime",