From 39acd7f7ebcd9b2301a04ea941464f12cad6c34b Mon Sep 17 00:00:00 2001
From: Li
Date: Mon, 18 Jul 2022 00:09:57 +1200
Subject: [PATCH] Revert NativeAOT becuase MS broke it
---
.github/workflows/build.yml | 75 +++++++++++--------
HorseIsleServer/HISPd/HISPd.csproj | 1 -
.../HISPd/Resources/DEBIAN/control | 2 +-
.../LibHISP/Properties/AssemblyInfo.cs | 4 +-
HorseIsleServer/LibHISP/Server/Entry.cs | 2 +-
.../N00BS/Properties/AssemblyInfo.cs | 4 +-
6 files changed, 49 insertions(+), 39 deletions(-)
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index ba14f3f..41591d0 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -36,16 +36,21 @@ jobs:
- name: Build linux-x64
continue-on-error: false
run: |
- dotnet add HISPd package Microsoft.DotNet.ILCompiler --prerelease
cd HISPd
- dotnet publish -r linux-x64 -c Linux /p:Platform=x64 --self-contained
+ dotnet publish -p:PublishProfile=LinuxARM.pubxml
cd ..
- mkdir -p HISPd/bin/x64/Linux/net7.0/linux-x64/native/gamedata
- cp -r HISPd/bin/x64/Linux/net7.0/linux-x64/gamedata/* HISPd/bin/x64/Linux/net7.0/linux-x64/native/gamedata
- cp HISPd/bin/x64/Linux/net7.0/linux-x64/HI1.MAP HISPd/bin/x64/Linux/net7.0/linux-x64/native/HI1.MAP
- cp HISPd/bin/x64/Linux/net7.0/linux-x64/publish/libe_sqlite3.so HISPd/bin/x64/Linux/net7.0/linux-x64/native/libe_sqlite3.so
- rm -f HISPd/bin/x64/Linux/net7.0/linux-x64/native/HISPd.dbg
- dotnet remove HISPd package Microsoft.DotNet.ILCompiler
+# Currently broken ...
+
+# dotnet add HISPd package Microsoft.DotNet.ILCompiler --prerelease
+# cd HISPd
+# dotnet publish -r linux-x64 -c Linux /p:Platform=x64 --self-contained
+# cd ..
+# mkdir -p HISPd/bin/x64/Linux/net7.0/linux-x64/native/gamedata
+# cp -r HISPd/bin/x64/Linux/net7.0/linux-x64/gamedata/* HISPd/bin/x64/Linux/net7.0/linux-x64/native/gamedata
+# cp HISPd/bin/x64/Linux/net7.0/linux-x64/HI1.MAP HISPd/bin/x64/Linux/net7.0/linux-x64/native/HI1.MAP
+# cp HISPd/bin/x64/Linux/net7.0/linux-x64/publish/libe_sqlite3.so HISPd/bin/x64/Linux/net7.0/linux-x64/native/libe_sqlite3.so
+# rm -f HISPd/bin/x64/Linux/net7.0/linux-x64/native/HISPd.dbg
+# dotnet remove HISPd package Microsoft.DotNet.ILCompiler
- name: Build linux-arm
@@ -185,21 +190,24 @@ jobs:
- name: Build win-x64
continue-on-error: false
run: |
- dotnet add HISPd package Microsoft.DotNet.ILCompiler --prerelease
cd HISPd
- dotnet publish -r win-x64 -c Windows /p:Platform=x64 --self-contained
- cd ..
- mkdir "HISPd\bin\x64\Windows\net7.0\win-x64\native\gamedata"
- copy "..\HorseIsleData\gamedata\*" "HISPd\bin\x64\Windows\net7.0\win-x64\native\gamedata"
- copy "..\HorseIsleData\HI1.MAP" "HISPd\bin\x64\Windows\net7.0\win-x64\native\HI1.MAP"
- copy "HISPd\bin\x64\Windows\net7.0\win-x64\publish\e_sqlite3.dll" "HISPd\bin\x64\Windows\net7.0\win-x64\native\e_sqlite3.dll"
- del "HISPd\bin\x64\Windows\net7.0\win-x64\native\HISPd.pdb"
- del "HISPd\bin\x64\Windows\net7.0\win-x64\native\HISPd.lib"
- del "HISPd\bin\x64\Windows\net7.0\win-x64\native\HISPd.exp"
- dotnet remove HISPd package Microsoft.DotNet.ILCompiler
- cd N00BS
dotnet publish -p:PublishProfile=Win64.pubxml
cd ..
+# dotnet add HISPd package Microsoft.DotNet.ILCompiler --prerelease
+# cd HISPd
+# dotnet publish -r win-x64 -c Windows /p:Platform=x64 --self-contained
+# cd ..
+# mkdir "HISPd\bin\x64\Windows\net7.0\win-x64\native\gamedata"
+# copy "..\HorseIsleData\gamedata\*" "HISPd\bin\x64\Windows\net7.0\win-x64\native\gamedata"
+# copy "..\HorseIsleData\HI1.MAP" "HISPd\bin\x64\Windows\net7.0\win-x64\native\HI1.MAP"
+# copy "HISPd\bin\x64\Windows\net7.0\win-x64\publish\e_sqlite3.dll" "HISPd\bin\x64\Windows\net7.0\win-x64\native\e_sqlite3.dll"
+# del "HISPd\bin\x64\Windows\net7.0\win-x64\native\HISPd.pdb"
+# del "HISPd\bin\x64\Windows\net7.0\win-x64\native\HISPd.lib"
+# del "HISPd\bin\x64\Windows\net7.0\win-x64\native\HISPd.exp"
+# dotnet remove HISPd package Microsoft.DotNet.ILCompiler
+# cd N00BS
+# dotnet publish -p:PublishProfile=Win64.pubxml
+# cd ..
- name: Build win-x86
continue-on-error: false
run: |
@@ -219,20 +227,23 @@ jobs:
- name: Build win-arm64
continue-on-error: false
run: |
- dotnet add HISPd package Microsoft.DotNet.ILCompiler --prerelease
- dotnet add HISPd package runtime.win-x64.Microsoft.DotNet.ILCompiler --prerelease
cd HISPd
- dotnet publish -r win-arm64 -c Windows /p:Platform=ARM64 --self-contained
+ dotnet publish -p:PublishProfile=WinARM.pubxml
cd ..
- mkdir "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\gamedata"
- copy "..\HorseIsleData\gamedata\*" "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\gamedata"
- copy "..\HorseIsleData\HI1.MAP" "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HI1.MAP"
- copy "HISPd\bin\ARM64\Windows\net7.0\win-arm64\publish\e_sqlite3.dll" "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\e_sqlite3.dll"
- del "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HISPd.pdb"
- del "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HISPd.lib"
- del "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HISPd.exp"
- dotnet remove HISPd package Microsoft.DotNet.ILCompiler
- dotnet remove HISPd package runtime.win-x64.Microsoft.DotNet.ILCompiler
+# dotnet add HISPd package Microsoft.DotNet.ILCompiler --prerelease
+# dotnet add HISPd package runtime.win-x64.Microsoft.DotNet.ILCompiler --prerelease
+# cd HISPd
+# dotnet publish -r win-arm64 -c Windows /p:Platform=ARM64 --self-contained
+# cd ..
+# mkdir "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\gamedata"
+# copy "..\HorseIsleData\gamedata\*" "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\gamedata"
+# copy "..\HorseIsleData\HI1.MAP" "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HI1.MAP"
+# copy "HISPd\bin\ARM64\Windows\net7.0\win-arm64\publish\e_sqlite3.dll" "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\e_sqlite3.dll"
+# del "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HISPd.pdb"
+# del "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HISPd.lib"
+# del "HISPd\bin\ARM64\Windows\net7.0\win-arm64\native\HISPd.exp"
+# dotnet remove HISPd package Microsoft.DotNet.ILCompiler
+# dotnet remove HISPd package runtime.win-x64.Microsoft.DotNet.ILCompiler
# Upload WINDOWS
diff --git a/HorseIsleServer/HISPd/HISPd.csproj b/HorseIsleServer/HISPd/HISPd.csproj
index 21bbc33..aa7f725 100644
--- a/HorseIsleServer/HISPd/HISPd.csproj
+++ b/HorseIsleServer/HISPd/HISPd.csproj
@@ -5,7 +5,6 @@
10.0
x64;x86;ARM;ARM64;AnyCPU
Debug;Windows;Linux;MacOS;Android;iOS
- true
diff --git a/HorseIsleServer/HISPd/Resources/DEBIAN/control b/HorseIsleServer/HISPd/Resources/DEBIAN/control
index c2c6703..487ff8e 100644
--- a/HorseIsleServer/HISPd/Resources/DEBIAN/control
+++ b/HorseIsleServer/HISPd/Resources/DEBIAN/control
@@ -1,5 +1,5 @@
Package: hisp
-Version: 1.7.91
+Version: 1.7.92
Depends: coreutils,systemd,mariadb-server,libsqlite3-dev,zlib1g-dev,libicu-dev,libkrb5-dev
Maintainer: Li
Homepage: https://islehorse.com
diff --git a/HorseIsleServer/LibHISP/Properties/AssemblyInfo.cs b/HorseIsleServer/LibHISP/Properties/AssemblyInfo.cs
index 7f46dfd..bc6c252 100644
--- a/HorseIsleServer/LibHISP/Properties/AssemblyInfo.cs
+++ b/HorseIsleServer/LibHISP/Properties/AssemblyInfo.cs
@@ -30,5 +30,5 @@ using System.Runtime.InteropServices;
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
-[assembly: AssemblyVersion("1.7.91.0")]
-[assembly: AssemblyFileVersion("1.7.91.0")]
+[assembly: AssemblyVersion("1.7.92.0")]
+[assembly: AssemblyFileVersion("1.7.92.0")]
diff --git a/HorseIsleServer/LibHISP/Server/Entry.cs b/HorseIsleServer/LibHISP/Server/Entry.cs
index 11c38b4..f90119e 100644
--- a/HorseIsleServer/LibHISP/Server/Entry.cs
+++ b/HorseIsleServer/LibHISP/Server/Entry.cs
@@ -75,10 +75,10 @@ namespace HISP.Server
File.AppendAllText("crashlog.txt", "HISP HAS CRASHED :(\n");
File.AppendAllText("crashlog.txt", "Unhandled Exception: " + execpt.ToString() + "\n");
File.AppendAllText("crashlog.txt", execpt.StackTrace + "\n");
+ GameServer.ShutdownServer();
}
catch (Exception) { };
- GameServer.ShutdownServer();
Thread.Sleep(5000);
Environment.Exit(1);
}
diff --git a/HorseIsleServer/N00BS/Properties/AssemblyInfo.cs b/HorseIsleServer/N00BS/Properties/AssemblyInfo.cs
index d864f9f..062645a 100644
--- a/HorseIsleServer/N00BS/Properties/AssemblyInfo.cs
+++ b/HorseIsleServer/N00BS/Properties/AssemblyInfo.cs
@@ -31,5 +31,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("1.7.91.0")]
-[assembly: AssemblyFileVersion("1.7.91.0")]
+[assembly: AssemblyVersion("1.7.92.0")]
+[assembly: AssemblyFileVersion("1.7.92.0")]