From f8289ffad582687bd8a7913e03de4d9732ff61c8 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 19 Oct 2019 23:53:12 +0200 Subject: [PATCH] Include wxwidgets.props into MSVS binaries distribution Add wxMSVC_VERSION_ABI_COMPAT definition to the version of the file included in the binary distribution to make it compatible with the actual DLL names. Closes #18510. --- build/tools/msvs/package.bat | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/build/tools/msvs/package.bat b/build/tools/msvs/package.bat index ad827b8db9..02be0b1ca3 100755 --- a/build/tools/msvs/package.bat +++ b/build/tools/msvs/package.bat @@ -74,8 +74,22 @@ copy utils\wxrc\%VCver%_mswudll_x64\wxrc.exe lib\%VCver%_x64_dll 7z a -t7z %packagePath%\%VCver%\wxMSW-%wxMAJOR_VERSION%.%wxMINOR_VERSION%.%wxRELEASE_NUMBER%_%VCver%_x64_ReleaseDLL.7z lib\%VCver%_x64_dll\wxMSW%wxDllVers%u_*.dll lib\%VCver%_x64_dll\wxbase%wxDllVers%u_*.dll 7z a -t7z %packagePath%\%VCver%\wxMSW-%wxMAJOR_VERSION%.%wxMINOR_VERSION%.%wxRELEASE_NUMBER%_%VCver%_x64_ReleasePDB.7z lib\%VCver%_x64_dll\wxMSW%wxDllVers%u_*.pdb lib\%VCver%_x64_dll\wxbase%wxDllVers%u_*.pdb -del %packagePath%\%VCver%\sha1.txt -fciv %packagePath%\%VCver% -type *.7z -sha1 -wp >> %packagePath%\%VCver%\sha1.txt +rem Create a modified copy of wxwidgets.props suitable for use with our +rem binaries: we need to enable automatic ABI-compatible MSVC version detection +rem for this, so we define it in the same place where WXUSINGDLL is defined (as +rem we only provide DLLs, this is sufficient). +powershell -noprofile -command "& { (Get-Content wxwidgets.props).Replace('WXUSINGDLL','WXUSINGDLL;wxMSVC_VERSION_ABI_COMPAT') | Set-Content %packagePath%\%VCver%\wxwidgets.props }" + +rem Change to the directory containing wxwidgets.props in order to include it +rem into the archive without any path. +cd %packagePath%\%VCver% +7z a -t7z wxMSW-%wxMAJOR_VERSION%.%wxMINOR_VERSION%.%wxRELEASE_NUMBER%_%VCver%_Dev.7z wxwidgets.props +7z a -t7z wxMSW-%wxMAJOR_VERSION%.%wxMINOR_VERSION%.%wxRELEASE_NUMBER%_%VCver%_x64_Dev.7z wxwidgets.props + +del wxwidgets.props + +del sha1.txt +fciv . -type *.7z -sha1 -wp >> sha1.txt goto End