refactor: 移除 Costura.Fody,改用标准多文件部署
- 移除 Costura.Fody 包引用,避免杀毒软件误报 - 删除 FodyWeavers.xml 配置文件 - 更新 setup.iss 使用通配符复制所有 DLL - 更新 release.bat 复制所有依赖文件 安装包现在包含独立的 DLL 文件,符合 Windows 软件标准部署方式 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
|
||||
<Costura>
|
||||
<!-- 设置为true以包含调试符号 -->
|
||||
<IncludeDebugSymbols>false</IncludeDebugSymbols>
|
||||
<!-- 禁用压缩可提高启动速度 -->
|
||||
<DisableCompression>false</DisableCompression>
|
||||
<!-- 创建临时目录存放原生DLL -->
|
||||
<CreateTemporaryAssemblies>true</CreateTemporaryAssemblies>
|
||||
</Costura>
|
||||
</Weavers>
|
||||
@@ -26,8 +26,6 @@
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
|
||||
<PackageReference Include="ClosedXML" Version="0.102.2" />
|
||||
<PackageReference Include="System.Configuration.ConfigurationManager" Version="6.0.0" />
|
||||
<!-- 将所有DLL打包到EXE中 -->
|
||||
<PackageReference Include="Costura.Fody" Version="5.7.0" PrivateAssets="all" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -111,6 +111,7 @@ if not exist "publish\x86" mkdir publish\x86
|
||||
|
||||
copy /Y "PackagingMallShipper\bin\Release\net462\PackagingMallShipper.exe" "publish\" >nul
|
||||
copy /Y "PackagingMallShipper\bin\Release\net462\PackagingMallShipper.exe.config" "publish\" >nul
|
||||
copy /Y "PackagingMallShipper\bin\Release\net462\*.dll" "publish\" >nul
|
||||
copy /Y "PackagingMallShipper\bin\Release\net462\x64\SQLite.Interop.dll" "publish\x64\" >nul
|
||||
copy /Y "PackagingMallShipper\bin\Release\net462\x86\SQLite.Interop.dll" "publish\x86\" >nul
|
||||
|
||||
@@ -120,7 +121,7 @@ if not exist "publish\PackagingMallShipper.exe" (
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
echo [Info] Files copied to publish folder
|
||||
echo [Info] Files copied to publish folder (EXE + DLLs)
|
||||
echo.
|
||||
|
||||
echo [Step 4] Compiling installer...
|
||||
|
||||
@@ -33,8 +33,12 @@ Name: "chinesesimplified"; MessagesFile: "compiler:Languages\ChineseSimplified.i
|
||||
Name: "desktopicon"; Description: "创建桌面快捷方式"; GroupDescription: "附加选项:"; Flags: checkedonce
|
||||
|
||||
[Files]
|
||||
; 主程序和配置
|
||||
Source: "publish\PackagingMallShipper.exe"; DestDir: "{app}"; Flags: ignoreversion
|
||||
Source: "publish\PackagingMallShipper.exe.config"; DestDir: "{app}"; Flags: ignoreversion
|
||||
; 所有依赖 DLL
|
||||
Source: "publish\*.dll"; DestDir: "{app}"; Flags: ignoreversion
|
||||
; SQLite 原生 DLL
|
||||
Source: "publish\x64\SQLite.Interop.dll"; DestDir: "{app}\x64"; Flags: ignoreversion
|
||||
Source: "publish\x86\SQLite.Interop.dll"; DestDir: "{app}\x86"; Flags: ignoreversion
|
||||
|
||||
|
||||
Reference in New Issue
Block a user