1
0
mirror of https://github.com/simh/simh.git synced 2026-01-13 23:35:57 +00:00
simh.simh/appveyor.yml
2023-07-05 04:07:54 -10:00

73 lines
2.2 KiB
YAML

image:
- Visual Studio 2015
- Ubuntu2004
- macos-monterey
platform:
- x86
matrix:
fast_finish: true
cache:
- ../windows-build
skip_commits:
files:
- doc/*
- '**/*.md'
- '**/*.txt'
before_build:
- ps: |
$platform = uname -s
if ($platform -eq 'Linux') {
sudo apt-get update -yqqm
sudo apt-get install -ym gcc libpcap-dev libvdeplug-dev libpcre3-dev libedit-dev libsdl2-dev libpng-dev libsdl2-ttf-dev
} else {
if ($platform -eq 'Darwin') {
brew install vde pcre libedit sdl2 libpng zlib sdl2_ttf make
}
}
build_script:
- cmd: |
"C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\vcvarsall.bat"
cd "Visual Studio Projects" & vcbuild /M%NUMBER_OF_PROCESSORS% /useenv /rebuild Simh.sln "Release|Win32"
- ps: |
if ($isWindows) {
cd ..
mkdir PACKAGES
$platform = 'Windows'
$id_line = Select-String -Path 'Visual Studio Projects\.git-commit-id.h' -Pattern 'SIM_GIT_COMMIT_ID'
$id_name_pos = $id_line.line.IndexOf("SIM_GIT_COMMIT_ID")
$id = $id_line.Line.SubString($id_name_pos + 18, 8)
$datetime = Get-Date -Format "yyyy-mm-dd_hh-mm-ss"
Compress-Archive -Path BIN\NT\Win32-Release\*.exe -DestinationPath PACKAGES\simh-4.0-Current-$platform-$datetime-$id.zip
} else {
$platform = uname -s
if ($platform -eq 'Linux') {
$ncpus = nproc
$parallel = '-j' + $ncpus
} else {
$platform = 'macOS'
}
make QUIET=1 $parallel
mkdir PACKAGES
$id_line = Select-String -Path '.git-commit-id' -Pattern 'SIM_GIT_COMMIT_ID'
$id_name_pos = $id_line.line.IndexOf("SIM_GIT_COMMIT_ID")
$id = $id_line.Line.SubString($id_name_pos + 18, 8)
$datetime = Get-Date -Format "yyyy-mm-dd_hh-mm-ss"
rm -rf BIN/buildtools
rm -rf BIN/*-build
Compress-Archive -Path BIN/* -DestinationPath PACKAGES/simh-4.0-Current-$platform-$datetime-$id.zip
}
artifacts:
- path: PACKAGES\*.zip
notifications:
- provider: Email
to:
- Mark@infocomm.com
on_build_success: false