forked from enigma-dev/enigma-dev
/
appveyor.yml
89 lines (86 loc) · 4.96 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
# fetch repository as zip archive
shallow_clone: true
# disable automatic tests
test: off
# don't build "feature" branches
skip_branch_with_pr: true
branches:
only:
- master
init:
- echo "%APPVEYOR_JOB_ID%"
# store the name of the archive job in an environment variable
# this designates the first job of every build as the archive job
- ps: |
$apiURL = "https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG"
$project = Invoke-RestMethod -Method Get -Uri $apiURL/build/$env:APPVEYOR_BUILD_VERSION
$env:ARCHIVE_JOB = $project.build.jobs[0].jobId
- echo "%ARCHIVE_JOB%"
- cd %APPVEYOR_BUILD_FOLDER%
environment:
OUTPUT: /tmp/test.exe
MSYS2_FC_CACHE_SKIP: yes
matrix:
#BEGIN WINDOWS
# Game Modes
- {COMPILER: gcc, PLATFORM: Win32, MODE: Run, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "None"}
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "None"}
- {COMPILER: gcc, PLATFORM: Win32, MODE: Compile, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "None"}
# Platforms
- {COMPILER: gcc, PLATFORM: SDL, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "None"}
# Graphics
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D11, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "None"}
# Audio
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: DirectSound, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "None"}
# Widgets
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: Win32, EXTENSIONS: "None"}
# Extensions
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "DirectShow"}
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "WindowsTouch"}
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "XInput"}
- {COMPILER: gcc, PLATFORM: Win32, MODE: Debug, GRAPHICS: Direct3D9, AUDIO: None, COLLISION: None, NETWORK: None, WIDGETS: None, EXTENSIONS: "MediaControlInterface"}
#END WINDOWS
install:
- set PATH=c:\msys64;C:\msys64\mingw64\bin;c:\msys64\usr\local\bin;c:\msys64\usr\bin;%PATH%
- set MSYSTEM=MINGW64
- set MSYSTEM_PREFIX=/mingw64
- set MSYSTEM_CHOST=x86_64-w64-mingw32
- set CONFIG_SITE=/mingw64/etc/config.site
- set MINGW_PACKAGE_PREFIX=mingw-w64-x86_64
- set MINGW_PREFIX=/mingw64
- set MINGW_CHOST=x86_64-w64-mingw32
- set PKG_CONFIG_PATH=/mingw64/lib/pkgconfig:/mingw64/share/pkgconfig
- >
pacman --noconfirm -S mingw-w64-x86_64-boost mingw-w64-x86_64-openal mingw-w64-x86_64-dumb mingw-w64-x86_64-libvorbis
mingw-w64-x86_64-libogg mingw-w64-x86_64-flac mingw-w64-x86_64-mpg123 mingw-w64-x86_64-libsndfile mingw-w64-x86_64-libgme
mingw-w64-x86_64-sfml mingw-w64-x86_64-gtk2 mingw-w64-x86_64-box2d mingw-w64-x86_64-bullet mingw-w64-x86_64-glew
mingw-w64-x86_64-protobuf mingw-w64-x86_64-grpc mingw-w64-x86_64-pugixml mingw-w64-x86_64-rapidjson mingw-w64-x86_64-yaml-cpp
mingw-w64-x86_64-SDL2
- gcc -v
- ps: |
If ($env:APPVEYOR_JOB_NUMBER -eq 1) {
# use our first job to build JDI and the CLI
bash -lc "cd '$env:APPVEYOR_BUILD_FOLDER'; make -j 4; CLI_ENABLE_EGM=FALSE make -j 4 emake"
# create a daemon PowerShell "job" (not the same as an AppVeyor build job) to zip and upload
# the blobs artifact while we start building the engine
$archive = {
Set-Location $using:PWD
7z a -t7z -mm=lzma2 -mx=4 -mmt blobs.zip compileEGMf.dll libEGM.dll libProtocols.dll emake.exe
appveyor PushArtifact blobs.zip -Type Zip
}
$daemon = Start-Job -ScriptBlock $archive
# register a callback so we can show the zip and upload output when it completes
$jobEvent = Register-ObjectEvent $daemon StateChanged -Action {
$result = Receive-Job -Job $daemon
Write-Host ('Artifact daemon has completed.') -foregroundcolor "Magenta"
Write-Host ($result | Out-String) -foregroundcolor "Gray"
}
} Else {
# simply restore JDI and the CLI from the archive artifact of this same build using REST API
$artifactsURL = "https://ci.appveyor.com/api/buildjobs/$env:ARCHIVE_JOB/artifacts/"
appveyor DownloadFile ($artifactsURL + "blobs.zip") -FileName blobs.zip
7z e -mmt blobs.zip
}
build_script:
# AppVeyor overrides %PLATFORM% because it's part of its API, so export it
- bash -lc "cd $APPVEYOR_BUILD_FOLDER; export PLATFORM=%PLATFORM%; ./ci-build.sh"