forked from OpenDungeons/OpenDungeons
-
Notifications
You must be signed in to change notification settings - Fork 1
/
appveyor.yml
50 lines (47 loc) · 2.02 KB
/
appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
os:
- Windows Server 2012 R2
configuration: Release
environment:
matrix:
- generator: "mingw32"
- generator: "msvc12"
branches:
only:
- development
clone_depth: 10
install:
# We need some packages from MinGW like binutils-dev that are not installed on the server. Because we want to make sure everything is consistent, we download the whole package
- ps: |
if($env:generator -eq 'mingw32')
{
mkdir c:\dev
$file = "C:\dev\MinGW32.7z"
$urlDeps = "http://download.tuxfamily.org/opendungeons/dependency/MinGW32.7z"
Write-Host "Downloading MinGW32"
appveyor DownloadFile $urlDeps -FileName $file
Write-Host "Unzip MinGW32"
7z x -oC:\dev $file > $null
}
# download dependencies
- ps: |
$file = "C:\od-deps-win32.7z"
$urlDeps = "http://download.tuxfamily.org/opendungeons/dependency/od-deps-win32.7z"
Write-Host "Downloading deps"
appveyor DownloadFile $urlDeps -FileName $file
Write-Host "Unzip deps"
7z x -oC:\ $file > $null
- set OD_DEPS=C:\od-deps-win32
# We try to keep as few things in path as possible to make sure cmake won't find a needed library in some unexpected place
- if "%generator%" == "mingw32" (set "PATH=c:\dev\MinGW\bin;C:\od-deps-win32\bin\mingw48;")
- if "%generator%" == "msvc12" (set "PATH=C:\Program Files (x86)\MSBuild\12.0\Bin;C:\od-deps-win32\bin\msvc;")
- echo %PATH%
build_script:
- if [%generator%]==[msvc12] "C:\Program Files (x86)\CMake\bin\cmake" -G "Visual Studio 12" -DOD_BUILD_TESTING=ON -DCMAKE_INSTALL_PREFIX="%cd%/inst" && msbuild INSTALL.vcxproj /verbosity:normal /p:Configuration=Release
- if [%generator%]==[mingw32] "C:\Program Files (x86)\CMake\bin\cmake" -G "MinGW Makefiles" -DOD_BUILD_TESTING=ON -DCMAKE_INSTALL_PREFIX="%cd%/inst" -DCMAKE_BUILD_TYPE=Release && mingw32-make install
test_script:
- scripts\win32\OpenDungeonsTests.bat
artifacts:
- path: OpenDungeons.exe
name: OpenDungeons exe
- path: Release/OpenDungeons.exe
name: OpenDungeons exe