-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy path.travis.yml
109 lines (102 loc) · 3.39 KB
/
.travis.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
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
language: haxe
# TravisCI by default run on linux.
# Let's enable all linux, windows, and mac builds because why not?
os:
- linux
- windows
- osx
dist: bionic
# Test with multiple Haxe versions.
haxe:
- "4.1.2"
- "3.4.7"
- development
matrix:
# Allow Haxe development to fail.
allow_failures:
- haxe: development
addons:
apt:
packages:
# C++ (for rebuilding hxcpp)
- gcc-multilib
- g++-multilib
# Python
- python3
# PHP
- php-cli
- php-mbstring
# C#
- mono-devel
- mono-mcs
# Flash
- libglib2.0
- libfreetype6
# Lua
- cmake
- lua5.1
- luarocks
- libpcre3-dev
- libssl-dev
homebrew:
update: true
packages:
# Python
- python
# C#
- mono
# Lua
- lua
- luarocks
- pcre
install:
# For Flash Player to work.
- if [ "${TRAVIS_OS_NAME}" = "linux" ]; then
export DISPLAY=:99.0;
export AUDIODEV=null;
fi
# Various language runtimes for Windows
- if [ "${TRAVIS_OS_NAME}" = "windows" ]; then
choco install nodejs-lts --version 12.13.1 -y; export PATH="/c/Program Files/nodejs:$PATH";
choco install openjdk --version 11.0.1 -y; export PATH="/c/Program Files/OpenJDK/jdk-11.0.1/bin:$PATH";
choco install php --version 7.4.0 -y; export PATH="/c/tools/php74:$PATH"; sed -i 's/;extension_dir = "ext"/extension_dir = "ext"/; s/;extension=mbstring/extension=mbstring/' "/c/tools/php74/php.ini";
choco install python --version 3.7.1 -y; export PATH="/c/Python37/Scripts:/c/Python37:$PATH";
fi
# Magic to make haxelib works https://github.com/HaxeFoundation/neko/issues/196
- if [ "${TRAVIS_OS_NAME}" = "windows" ]; then
curl -sSLf https://lib.haxe.org/p/jQueryExtern/3.2.1/download/ -o /dev/null;
fi
# Haxe Lua dependencies
- if [ "${TRAVIS_OS_NAME}" = "linux" ] || [ "${TRAVIS_OS_NAME}" = "osx" ]; then
sudo luarocks install haxe-deps;
fi
# Download and setup a standalone flash player debugger
- haxe flash/install.hxml
# Prefer homebrew's python
- if [ "${TRAVIS_OS_NAME}" = "osx" ]; then
brew link --overwrite python@3;
fi
# Install haxelibs
- if [ "${TRAVIS_HAXE_VERSION}" = "development" ]; then
haxelib git hxcpp https://github.com/HaxeFoundation/hxcpp.git;
pushd $(haxelib path hxcpp | head -1);
pushd tools/hxcpp; haxe compile.hxml; popd;
pushd project; neko build.n; popd;
popd;
else
haxelib install hxcpp;
fi
- haxelib install hxjava
- haxelib install hxcs
- haxelib list
script:
- haxe build-interp.hxml
- haxe build-neko.hxml && neko bin/HelloWorld.n
- haxe build-js.hxml && node bin/HelloWorld.js
- haxe build-java.hxml && java -jar bin/HelloWorld.jar
- haxe build-php.hxml && php bin/index.php
- haxe build-cs.hxml && ( if [ "${TRAVIS_OS_NAME}" = "windows" ]; then bin/bin/HelloWorld.exe; else mono bin/bin/HelloWorld.exe; fi )
- haxe build-flash.hxml -D fdb && haxe flash/run.hxml bin/HelloWorld.swf
- haxe build-cpp.hxml && ./bin/HelloWorld
- haxe build-python.hxml && ( if [ "${TRAVIS_OS_NAME}" = "windows" ]; then python bin/HelloWorld.py; else python3 bin/HelloWorld.py; fi )
- haxe build-lua.hxml && ( if [ "${TRAVIS_OS_NAME}" = "linux" ] || [ "${TRAVIS_OS_NAME}" = "osx" ]; then lua bin/HelloWorld.lua; fi )