File tree Expand file tree Collapse file tree 4 files changed +60
-1
lines changed
Expand file tree Collapse file tree 4 files changed +60
-1
lines changed Original file line number Diff line number Diff line change @@ -9,4 +9,6 @@ vcpkg_installed/
99build /
1010
1111/* .log
12- CMakeCache.txt
12+ CMakeCache.txt
13+
14+ releases /
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ # shellcheck disable=SC2164
4+
5+ root_dir=$( pwd)
6+ releases_dir=" ${root_dir} /releases"
7+ version=$( cat version.txt)
8+
9+ mkdir -p " $releases_dir "
10+
11+ function build_and_archive() {
12+ local triplet=$1
13+ cmake --build .
14+ archive_name=" mtsum-v${version} -${triplet} "
15+ tar -cf - " mtsum" > " ${archive_name} .tar"
16+ 7z a -tgzip -mx=9 " ${releases_dir} /${archive_name} .tar.gz" " ${archive_name} .tar"
17+ rm " ${archive_name} .tar"
18+ }
19+
20+ cmake --preset release-make -DMTSUM_STATIC=OFF -DMTSUM_VCPKG=ON -B cmake-build-release-x64-linux
21+ cd cmake-build-release-x64-linux
22+ build_and_archive " x64-linux"
23+
24+ cd " $root_dir "
25+
26+ cmake --preset release-make -DMTSUM_STATIC=ON -DMTSUM_VCPKG=ON -B cmake-build-release-x64-linux-static
27+ cd cmake-build-release-x64-linux-static
28+ build_and_archive " x64-linux-static"
Original file line number Diff line number Diff line change 1+ Import-VisualStudioVars - Architecture amd64
2+
3+ $rootDir = Get-Location
4+ $releasesDir = Join-Path $rootDir " releases"
5+ $version = Get-Content " version.txt" - Raw
6+
7+ New-Item - ItemType Directory - Force - Path $releasesDir
8+
9+ function Build-And-Archive {
10+ param (
11+ [string ]$triplet
12+ )
13+ cmake -- build .
14+ $archiveName = " mtsum-v$version -$triplet "
15+ 7z a - tzip - mx= 9 " $releasesDir \$archiveName .zip" " mtsum.exe" * .dll
16+ }
17+
18+ # cmake --preset release-ninja -DMTSUM_STATIC=OFF -DMTSUM_VCPKG=ON -B cmake-build-release-x64-windows
19+ Set-Location " cmake-build-release-x64-windows"
20+ Build-And - Archive - triplet " x64-windows"
21+
22+ Set-Location $rootDir
23+
24+ # cmake --preset release-ninja -DMTSUM_STATIC=ON -DMTSUM_VCPKG=ON -B cmake-build-release-x64-windows-static
25+ Set-Location " cmake-build-release-x64-windows-static"
26+ Build-And - Archive - triplet " x64-windows-static"
27+
28+ Set-Location $rootDir
Original file line number Diff line number Diff line change 1+ 1.1.0
You can’t perform that action at this time.
0 commit comments