diff --git a/Release/Release_CLI_Windows.ps1 b/Release/Release_CLI_Windows.ps1 new file mode 100644 index 000000000..fd59cabc9 --- /dev/null +++ b/Release/Release_CLI_Windows.ps1 @@ -0,0 +1,101 @@ +## Copyright (c) MediaArea.net SARL. All Rights Reserved. +## +## Use of this source code is governed by a BSD-style license that can +## be found in the License.html file in the root of the source tree. +## + +$ErrorActionPreference = "Stop" + +#----------------------------------------------------------------------- +# Setup +$release_directory = $PSScriptRoot +$version = (Get-Content "${release_directory}\..\Project\version.txt" -Raw).Trim() +$arch = "x64" + +#----------------------------------------------------------------------- +# Cleanup +$artifact = "${release_directory}\QCli_${version}_Windows_${arch}" +if (Test-Path "${artifact}") { + Remove-Item -Force -Recurse "${artifact}" +} + +$artifact = "${release_directory}\QCli_${version}_Windows_${arch}.zip" +if (Test-Path "${artifact}") { + Remove-Item -Force "${artifact}" +} + +$artifact = "${release_directory}\QCli_${version}_Windows_${arch}_DebugInfo.zip" +if (Test-Path "${artifact}") { + Remove-Item -Force "${artifact}" +} + +#----------------------------------------------------------------------- +# Package GUI +Push-Location "${release_directory}" + New-Item -ItemType Directory -Path "QCli_${version}_Windows_${arch}" + Push-Location -Path "QCli_${version}_Windows_${arch}" + Copy-Item -Force -Path "${release_directory}\..\History.txt" . + Copy-Item -Force -Path "${release_directory}\..\License.html" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\qcli.exe" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\Qt6Core.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\Qt6Gui.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\Qt6Multimedia.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\Qt6Network.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\Qt6Svg.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\d3dcompiler_47.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\opengl32sw.dll" . + New-Item -ItemType directory -Path "iconengines" + Push-Location -Path "iconengines" + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\iconengines\qsvgicon.dll" . + Pop-Location + New-Item -ItemType directory -Path "imageformats" + Push-Location -Path "imageformats" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\imageformats\qjpeg.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\imageformats\qsvg.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\imageformats\qico.dll" . + Pop-Location + New-Item -ItemType directory -Path "multimedia" + Push-Location -Path "multimedia" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\multimedia\windowsmediaplugin.dll" . + Pop-Location + New-Item -ItemType directory -Path "networkinformation" + Push-Location -Path "networkinformation" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\networkinformation\qnetworklistmanager.dll" . + Pop-Location + New-Item -ItemType directory -Path "platforms" + Push-Location -Path "platforms" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\platforms\qwindows.dll" . + Pop-Location + New-Item -ItemType directory -Name "tls" + Push-Location -Path "tls" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\tls\qcertonlybackend.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\tls\qopensslbackend.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\tls\qschannelbackend.dll" . + Pop-Location + Copy-Item -Path "${release_directory}\..\..\output\lib\qwt.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avdevice-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avcodec-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avfilter-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avformat-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avutil-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\postproc-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\swresample-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\swscale-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\freetype-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\harfbuzz.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\concrt140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_1.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_2.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_atomic_wait.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_codecvt_ids.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vccorlib140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vcruntime140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vcruntime140_1.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vcruntime140_threads.dll" . + + Compress-Archive -Path * -DestinationPath "..\QCli_${version}_Windows_${arch}.zip" + Pop-Location + + Compress-Archive -Path "${release_directory}\..\Project\QtCreator\build\qctools-cli\release\QCli.pdb" -DestinationPath "QCli_${version}_Windows_${arch}_DebugInfo.zip" +Pop-Location diff --git a/Release/Release_CLI_Windows_x64.ps1 b/Release/Release_CLI_Windows_x64.ps1 deleted file mode 100644 index 92da9910d..000000000 --- a/Release/Release_CLI_Windows_x64.ps1 +++ /dev/null @@ -1,91 +0,0 @@ -################################################################################################### -# Release_CLI_Windows_x64.ps1 - PowerShell script for creating Windows QCli packages (x64) # -# # -# Script requirements: # -# - Built qctools_AllInclusive sources # -# - Microsoft Visual Studio environment # -################################################################################################### - -# setup environment -$ErrorActionPreference="Stop" -$build_path=$Pwd -$version=Get-Content -Path $build_path\qctools\Project\version.txt - -# binary archive -Write-Output "Create CLI archive" -if (Test-Path -Path QCli_${version}_Windows_x64) { - Remove-Item -Force -Recurse -Path QCli_${version}_Windows_x64 -} -New-Item -ItemType directory -Name QCli_${version}_Windows_x64 -Push-Location -Path QCli_${version}_Windows_x64 - Copy-Item -Path $build_path\qctools\History.txt - Copy-Item -Path $build_path\qctools\License.html - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\qcli.exe - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\Qt6Core.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\Qt6Gui.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\Qt6Multimedia.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\Qt6Network.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\Qt6Svg.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\d3dcompiler_47.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\opengl32sw.dll - New-Item -ItemType directory -Name iconengines - Push-Location -Path iconengines - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\iconengines\qsvgicon.dll - Pop-Location - New-Item -ItemType directory -Name imageformats - Push-Location -Path imageformats - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\imageformats\qjpeg.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\imageformats\qsvg.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\imageformats\qico.dll - Pop-Location - New-Item -ItemType directory -Name multimedia - Push-Location -Path multimedia - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\multimedia\windowsmediaplugin.dll - Pop-Location - New-Item -ItemType directory -Name networkinformation - Push-Location -Path networkinformation - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\networkinformation\qnetworklistmanager.dll - Pop-Location - New-Item -ItemType directory -Name platforms - Push-Location -Path platforms - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\platforms\qwindows.dll - Pop-Location - New-Item -ItemType directory -Name tls - Push-Location -Path tls - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\tls\qcertonlybackend.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\tls\qopensslbackend.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\tls\qschannelbackend.dll - Pop-Location - Copy-Item -Path $build_path\output\lib\qwt.dll - Copy-Item -Path $build_path\output\bin\avdevice-*.dll - Copy-Item -Path $build_path\output\bin\avcodec-*.dll - Copy-Item -Path $build_path\output\bin\avfilter-*.dll - Copy-Item -Path $build_path\output\bin\avformat-*.dll - Copy-Item -Path $build_path\output\bin\avutil-*.dll - Copy-Item -Path $build_path\output\bin\postproc-*.dll - Copy-Item -Path $build_path\output\bin\swresample-*.dll - Copy-Item -Path $build_path\output\bin\swscale-*.dll - Copy-Item -Path $build_path\output\bin\freetype-*.dll - Copy-Item -Path $build_path\output\bin\harfbuzz.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\concrt140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_1.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_2.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_atomic_wait.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_codecvt_ids.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vccorlib140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vcruntime140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vcruntime140_1.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vcruntime140_threads.dll -Pop-Location -if (Test-Path -Path QCli_${version}_Windows_x64.zip) { - Remove-Item -Force -Path QCli_${version}_Windows_x64.zip -} -Compress-Archive -Path QCli_${version}_Windows_x64\* -DestinationPath QCli_${version}_Windows_x64.zip - -# debug symbols archive -Write-Output "Create CLI debug symbols archive" -if (Test-Path -Path QCli_${version}_Windows_x64_DebugInfo.zip) { - Remove-Item -Force -Path QCli_${version}_Windows_x64_DebugInfo.zip -} -Compress-Archive -Path $build_path\qctools\Project\QtCreator\build\qctools-cli\release\QCli.pdb -DestinationPath QCli_${version}_Windows_x64_DebugInfo.zip diff --git a/Release/Release_GUI_Windows.ps1 b/Release/Release_GUI_Windows.ps1 new file mode 100644 index 000000000..6e8a981f2 --- /dev/null +++ b/Release/Release_GUI_Windows.ps1 @@ -0,0 +1,121 @@ +## Copyright (c) MediaArea.net SARL. All Rights Reserved. +## +## Use of this source code is governed by a BSD-style license that can +## be found in the License.html file in the root of the source tree. +## + +$ErrorActionPreference = "Stop" + +#----------------------------------------------------------------------- +# Setup +$release_directory = $PSScriptRoot +$version = (Get-Content "${release_directory}\..\Project\version.txt" -Raw).Trim() +$arch = "x64" + +#----------------------------------------------------------------------- +# Cleanup +$artifact = "${release_directory}\QCTools_${version}_Windows_${arch}_WithoutInstaller" +if (Test-Path "${artifact}") { + Remove-Item -Force -Recurse "${artifact}" +} + +$artifact = "${release_directory}\QCTools_${version}_Windows_${arch}_WithoutInstaller.zip" +if (Test-Path "${artifact}") { + Remove-Item -Force "${artifact}" +} + +$artifact = "${release_directory}\QCTools_${version}_Windows_${arch}_DebugInfo.zip" +if (Test-Path "${artifact}") { + Remove-Item -Force "${artifact}" +} + +$artifact = "${release_directory}\QCTools_${version}_Windows.exe" +if (Test-Path "${artifact}") { + Remove-Item -Force "${artifact}" +} + +#----------------------------------------------------------------------- +# Package GUI +Push-Location "${release_directory}" + New-Item -ItemType Directory -Path "QCTools_${version}_Windows_${arch}_WithoutInstaller" + Push-Location -Path "QCTools_${version}_Windows_${arch}_WithoutInstaller" + Copy-Item -Force -Path "${release_directory}\..\History.txt" . + Copy-Item -Force -Path "${release_directory}\..\License.html" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\QCTools.exe" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Core.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Gui.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Multimedia.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6MultimediaWidgets.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Network.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6OpenGL.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Qml.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6QmlModels.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Svg.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\Qt6Widgets.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\d3dcompiler_47.dll" . + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\opengl32sw.dll" . + New-Item -ItemType directory -Path "iconengines" + Push-Location -Path "iconengines" + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\\iconengines\qsvgicon.dll" . + Pop-Location + New-Item -ItemType directory -Path "imageformats" + Push-Location -Path "imageformats" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\imageformats\qjpeg.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\imageformats\qsvg.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\imageformats\qico.dll" . + Pop-Location + New-Item -ItemType directory -Path "multimedia" + Push-Location -Path "multimedia" + Copy-Item -Force -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\multimedia\windowsmediaplugin.dll" . + Pop-Location + New-Item -ItemType directory -Path "networkinformation" + Push-Location -Path "networkinformation" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\networkinformation\qnetworklistmanager.dll" . + Pop-Location + New-Item -ItemType directory -Path "platforms" + Push-Location -Path "platforms" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\platforms\qwindows.dll" . + Pop-Location + New-Item -ItemType directory -Path "styles" + Push-Location -Path "styles" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\styles\qwindowsvistastyle.dll" . + Pop-Location + New-Item -ItemType directory -Path "tls" + Push-Location -Path "tls" + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\tls\qcertonlybackend.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\tls\qopensslbackend.dll" . + Copy-Item -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\tls\qschannelbackend.dll" . + Pop-Location + Copy-Item -Path "${release_directory}\..\..\output\lib\qwt.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avdevice-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avcodec-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avfilter-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avformat-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\avutil-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\postproc-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\swresample-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\swscale-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\freetype-*.dll" . + Copy-Item -Path "${release_directory}\..\..\output\bin\harfbuzz.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\concrt140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_1.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_2.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_atomic_wait.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\msvcp140_codecvt_ids.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vccorlib140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vcruntime140.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vcruntime140_1.dll" . + Copy-Item -Path "${Env:VCToolsRedistDir}\${arch}\Microsoft.VC143.CRT\vcruntime140_threads.dll" . + + Compress-Archive -Path * -DestinationPath "..\QCTools_${version}_Windows_${arch}_WithoutInstaller.zip" + Pop-Location + + Compress-Archive -Path "${release_directory}\..\Project\QtCreator\build\qctools-gui\release\QCTools.pdb" -DestinationPath "QCTools_${version}_Windows_${arch}_DebugInfo.zip" +Pop-Location + +#----------------------------------------------------------------------- +# Package installer +Push-Location "${release_directory}" + makensis.exe "..\Source\Install\QCTools.nsi" +Pop-Location diff --git a/Release/Release_GUI_Windows_x64.ps1 b/Release/Release_GUI_Windows_x64.ps1 deleted file mode 100644 index bd2cf75c7..000000000 --- a/Release/Release_GUI_Windows_x64.ps1 +++ /dev/null @@ -1,118 +0,0 @@ -################################################################################################### -# Release_GUI_Windows_x64.ps1 - PowerShell script for creating Windows QCTools packages (x64) # -# # -# Script requirements: # -# - Built qctools_AllInclusive sources # -# - Microsoft Visual Studio environment # -# - NSIS binary in the PATH # -################################################################################################### - -# helpers -function Cmd-Result { - if (-Not $?) { - Exit(1) - } -} - -# setup environment -$ErrorActionPreference="Stop" -$build_path=$Pwd -$version=Get-Content -Path $build_path\qctools\Project\version.txt - -# binary archive -Write-Output "Create GUI archive" -if (Test-Path -Path QCTools_${version}_Windows_x64) { - Remove-Item -Force -Recurse -Path QCTools_${version}_Windows_x64 -} -New-Item -ItemType directory -Name QCTools_${version}_Windows_x64 -Push-Location -Path QCTools_${version}_Windows_x64 - Copy-Item -Path $build_path\qctools\History.txt - Copy-Item -Path $build_path\qctools\License.html - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\QCTools.exe - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Core.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Gui.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Multimedia.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6MultimediaWidgets.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Network.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6OpenGL.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Qml.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6QmlModels.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Svg.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\Qt6Widgets.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\d3dcompiler_47.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\opengl32sw.dll - New-Item -ItemType directory -Name iconengines - Push-Location -Path iconengines - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\iconengines\qsvgicon.dll - Pop-Location - New-Item -ItemType directory -Name imageformats - Push-Location -Path imageformats - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\imageformats\qjpeg.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\imageformats\qsvg.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\imageformats\qico.dll - Pop-Location - New-Item -ItemType directory -Name multimedia - Push-Location -Path multimedia - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\multimedia\windowsmediaplugin.dll - Pop-Location - New-Item -ItemType directory -Name networkinformation - Push-Location -Path networkinformation - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\networkinformation\qnetworklistmanager.dll - Pop-Location - New-Item -ItemType directory -Name platforms - Push-Location -Path platforms - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\platforms\qwindows.dll - Pop-Location - New-Item -ItemType directory -Name styles - Push-Location -Path styles - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\styles\qwindowsvistastyle.dll - Pop-Location - New-Item -ItemType directory -Name tls - Push-Location -Path tls - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\tls\qcertonlybackend.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\tls\qopensslbackend.dll - Copy-Item -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\tls\qschannelbackend.dll - Pop-Location - Copy-Item -Path $build_path\output\lib\qwt.dll - Copy-Item -Path $build_path\output\bin\avdevice-*.dll - Copy-Item -Path $build_path\output\bin\avcodec-*.dll - Copy-Item -Path $build_path\output\bin\avfilter-*.dll - Copy-Item -Path $build_path\output\bin\avformat-*.dll - Copy-Item -Path $build_path\output\bin\avutil-*.dll - Copy-Item -Path $build_path\output\bin\postproc-*.dll - Copy-Item -Path $build_path\output\bin\swresample-*.dll - Copy-Item -Path $build_path\output\bin\swscale-*.dll - Copy-Item -Path $build_path\output\bin\freetype-*.dll - Copy-Item -Path $build_path\output\bin\harfbuzz.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\concrt140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_1.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_2.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_atomic_wait.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\msvcp140_codecvt_ids.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vccorlib140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vcruntime140.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vcruntime140_1.dll - Copy-Item -Path $Env:VCToolsRedistDir\x64\Microsoft.VC143.CRT\vcruntime140_threads.dll -Pop-Location -if (Test-Path -Path QCTools_${version}_Windows_x64_WithoutInstaller.zip) { - Remove-Item -Force -Path QCTools_${version}_Windows_x64_WithoutInstaller.zip -} -Compress-Archive -Path QCTools_${version}_Windows_x64\* -DestinationPath QCTools_${version}_Windows_x64_WithoutInstaller.zip - -# debug symbols archive -Write-Output "Create GUI debug symbols archive" -if (Test-Path -Path QCTools_${version}_Windows_x64_DebugInfo.zip) { - Remove-Item -Force -Path QCTools_${version}_Windows_x64_DebugInfo.zip -} -Compress-Archive -Path $build_path\qctools\Project\QtCreator\build\qctools-gui\release\QCTools.pdb -DestinationPath QCTools_${version}_Windows_x64_DebugInfo.zip - -# installer -Write-Output "Create GUI installer" -if (Test-Path -Path QCTools_${version}_Windows.exe) { - Remove-Item -Force -Path QCTools_${version}_Windows.exe -} -Push-Location -Path qctools\Source\Install - makensis.exe QCTools.nsi ; Cmd-Result -Pop-Location -Copy-Item -Path qctools\QCTools_${version}_Windows.exe diff --git a/Source/Install/QCTools.nsi b/Source/Install/QCTools.nsi index 1cdd62e74..09d619ce6 100644 --- a/Source/Install/QCTools.nsi +++ b/Source/Install/QCTools.nsi @@ -27,6 +27,11 @@ SetCompressor /FINAL /SOLID lzma !include FileFunc.nsh !include WinVer.nsh +; Uninstaller signing +!ifdef EXPORT_UNINST + !uninstfinalize 'copy /Y "%1" "../../Release/${PRODUCT_NAME}_${PRODUCT_VERSION}_Windows-uninst.exe"' +!endif + ; Modern UI !include "MUI2.nsh" !define MUI_ABORTWARNING @@ -65,7 +70,7 @@ BrandingText " " ; Modern UI end Name "${PRODUCT_NAME} ${PRODUCT_VERSION}" -OutFile "..\..\${PRODUCT_NAME}_${PRODUCT_VERSION}_Windows.exe" +OutFile "..\..\Release\${PRODUCT_NAME}_${PRODUCT_VERSION}_Windows.exe" InstallDir "$PROGRAMFILES64\${PRODUCT_NAME}" InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" "" ShowInstDetails nevershow @@ -156,7 +161,11 @@ Section "SectionPrincipale" SEC01 SectionEnd Section -Post - WriteUninstaller "$INSTDIR\uninst.exe" + !if /FileExists "..\..\Release\${PRODUCT_NAME}_${PRODUCT_VERSION}_Windows-uninst.exe" + File "/oname=$INSTDIR\uninst.exe" "..\..\Release\${PRODUCT_NAME}_${PRODUCT_VERSION}_Windows-uninst.exe" + !else + WriteUninstaller "$INSTDIR\uninst.exe" + !endif WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$INSTDIR\QCTools.exe" WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)" WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}"