Skip to content

Commit

Permalink
fix CI on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
soramimi committed Jun 1, 2024
1 parent 61c3805 commit bb811c8
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 20 deletions.
8 changes: 4 additions & 4 deletions RELEASE-WINDOWS.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/ruby

$qt = "C:/Qt/6.5.2/msvc2019_64"
$windeployqt = "C:/Qt/6.5.2/msvc2019_64/bin/windeployqt.exe"
$qt = "C:/Qt/6.6.3/msvc2019_64"
$windeployqt = "C:/Qt/6.6.3/msvc2019_64/bin/windeployqt.exe"
#$qt = "" # スタティックリンクのとき

$openssl = "C:/Program Files/OpenSSL"
Expand All @@ -11,7 +11,7 @@
load 'version.rb'

$workdir = "_release"
$dstdir = $workdir + "/" + $product_name
$dstdir = $workdir + "/soramimi.jp/" + $product_name

FileUtils.rm_rf($workdir)
FileUtils.mkpath($dstdir)
Expand All @@ -31,6 +31,6 @@
pkgfilename = "#{$product_name}-#{$version_a}.#{$version_b}.#{$version_c}-win32.zip"

Dir.chdir($workdir) {
`7z a #{pkgfilename} #{$product_name}`
`7z a #{pkgfilename} soramimi.jp`
}

2 changes: 1 addition & 1 deletion ci/ci-windows.bat
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvars64.bat"
call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat"
ruby packaging\win\deploy.rb
21 changes: 6 additions & 15 deletions packaging/win/deploy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ def run(cmd)
run "git clone https://github.com/madler/zlib"
FileUtils.cp "../../zlib.pro", "zlib/"
Dir.chdir("zlib") {
run "C:/Qt/6.5.2/msvc2019_64/bin/qmake.exe CONFIG+=release zlib.pro"
run "C:/Qt/Tools/QtCreator/bin/jom.exe"
run "C:/Qt/6.6.3/msvc2019_64/bin/qmake.exe CONFIG+=release zlib.pro"
run "C:/Qt/Tools/QtCreator/bin/jom/jom.exe"
}
ENV["INCLUDE"] = $script_dir + "/zlib;" + ENV["INCLUDE"]

Expand All @@ -34,23 +34,14 @@ def run(cmd)
FileUtils.cp $script_dir + "/zlib/_bin/libz.lib", "_bin/"

mkcd $script_dir + "/build"
run "C:/Qt/6.5.2/msvc2019_64/bin/qmake.exe CONFIG+=release ../../../Guitar.pro"
run "C:/Qt/Tools/QtCreator/bin/jom.exe"
run "C:/Qt/6.6.3/msvc2019_64/bin/qmake.exe CONFIG+=release ../../../Guitar.pro"
run "C:/Qt/Tools/QtCreator/bin/jom/jom.exe"

Dir.chdir $script_dir + "/../../"
run "ruby RELEASE-WINDOWS.rb"

Dir.chdir $script_dir
load '../../version.rb'
load 'version.rb'

pkgname = "Guitar-#{$version_a}.#{$version_b}.#{$version_c}-win32.zip"

run "7z x ../../_release/#{pkgname} -opackages/jp.soramimi.guitar"

mkcd $script_dir + "/packages/jp.soramimi.guitar"
FileUtils.mv "Guitar", "data"

Dir.chdir $script_dir
run "C:/Qt/QtIFW-3.2.2/bin/binarycreator.exe -c config/config.xml -p packages GuitarSetup.exe"

run "curl -T GuitarSetup.exe ftp://192.168.0.5:/Public/pub/nightlybuild/"
run "curl -T _release/#{pkgname} ftp://192.168.0.5:/Public/pub/nightlybuild/"

0 comments on commit bb811c8

Please sign in to comment.