Skip to content

Commit

Permalink
Bug #131, 与/guard:ehcont 项目一起链接时可能导致异常无法正常派发
Browse files Browse the repository at this point in the history
  • Loading branch information
mingkuang-Chuyu committed Dec 13, 2024
1 parent c56d70a commit 69016c2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Build.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
setlocal

::需要设置LibMaker.exe路径到环境变量Path。
::如果你需要LibMaker.exe,请自行到 初雨开源项目交流QQ群(633710173)群文件中下载
::如果你需要LibMaker.exe,请自行下载:https://github.com/Chuyu-Team/LibMaker/releases

pushd "%~dp0.."

Expand All @@ -26,7 +26,7 @@ goto:eof
:BuildObj
echo BuildObj %1 %2 %3

cl /O1 /Os /Oi /GS- /std:c++17 /execution-charset:utf-8 /Zc:sizedDealloc- /Zc:tlsGuards- /Zc:alignedNew- /arch:IA32 /Z7 /MT /Fo"objs\\%Platform%\\%1" /Zl /c /D "NDEBUG" /D "YY_Thunks_Target=%2" "%~dp0Thunks\YY_Thunks.cpp"
cl /O1 /Os /Oi /GS- /std:c++17 /execution-charset:utf-8 /guard:ehcont /Zc:sizedDealloc- /Zc:tlsGuards- /Zc:alignedNew- /arch:IA32 /Z7 /MT /Fo"objs\\%Platform%\\%1" /Zl /c /D "NDEBUG" /D "YY_Thunks_Target=%2" "%~dp0Thunks\YY_Thunks.cpp"
if %ErrorLevel% NEQ 0 exit /b %ErrorLevel%

::生成weak符号,一些非必须符号安排为weak可以避免链接失败
Expand All @@ -40,7 +40,7 @@ echo BuildLib %1 %2 %3

md "Lib\\%1\\%Platform%"

cl /O1 /Os /Oi /GS- /std:c++17 /execution-charset:utf-8 /Zc:sizedDealloc- /Zc:tlsGuards- /Zc:alignedNew- /arch:IA32 /Z7 /MT /Fo"Lib\\%1\\%Platform%\\YY_Thunks_for_%1.obj" /Zl /c /D "__APPLY_CHROMIUM_WORKAROUNDS" /D "__USING_NTDLL_LIB" /D "NDEBUG" /D "YY_Thunks_Target=%2" /D "__FALLBACK_PREFIX=YY_Thunks_" "%~dp0Thunks\YY_Thunks.cpp"
cl /O1 /Os /Oi /GS- /std:c++17 /execution-charset:utf-8 /guard:ehcont /Zc:sizedDealloc- /Zc:tlsGuards- /Zc:alignedNew- /arch:IA32 /Z7 /MT /Fo"Lib\\%1\\%Platform%\\YY_Thunks_for_%1.obj" /Zl /c /D "__APPLY_CHROMIUM_WORKAROUNDS" /D "__USING_NTDLL_LIB" /D "NDEBUG" /D "YY_Thunks_Target=%2" /D "__FALLBACK_PREFIX=YY_Thunks_" "%~dp0Thunks\YY_Thunks.cpp"

if %ErrorLevel% NEQ 0 exit /b %ErrorLevel%

Expand Down

0 comments on commit 69016c2

Please sign in to comment.