-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
42 lines (37 loc) · 1.79 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
dist: xenial
language: haxe
haxe:
- "4.0.5"
before_install:
# Cmake 1.13 minimum
- wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | sudo apt-key add - &&
sudo apt-add-repository 'deb https://apt.kitware.com/ubuntu/ xenial main' &&
sudo apt-get update &&
sudo apt-get install cmake
# libraries used for testing
- sudo apt-get install -y libcairo2 libpng-dev libjpeg-turbo8-dev libturbojpeg libvorbis-dev libopenal-dev libsdl2-dev libmbedtls-dev libuv1-dev
- sudo ln -s /usr/lib/x86_64-linux-gnu/libturbojpeg.so.0.1.0 /usr/lib/x86_64-linux-gnu/libturbojpeg.so
# dependencies
- script/get_libffi.sh download linux-x86-64
- script/get_libffi.sh install linux-x86-64
- script/get_hashlink.sh download linux-x86-64
- script/get_hashlink.sh install linux-x86-64
install:
- yes | haxelib install hxcpp
- yes | haxelib install hashlink
- yes | haxelib install test.hxml
script:
- mkdir -p out/ && cd out/ && /usr/bin/cmake .. -DCMAKE_BUILD_TYPE=Debug -DLIBFFI_INCLUDE_PATH:PATH=/usr/local/include/ -DLIBFFI_LIB_PATH:FILEPATH=/usr/local/lib/libffi.so
- make && make examplelib
- cd ../
- haxe hxml/test.cpp.hxml -D callfunc_unit_test
- haxe hxml/test.hl.hxml -D callfunc_unit_test
- haxe hxml/test.hl.c.hxml -D callfunc_unit_test
- gcc -g -o out/hl/test/test out/hl/test/test.c -I out/hl/test/ -std=c11 -lhl -lm out/callfunc/callfunc.hdll
- source script/export_ld_path.sh && ./out/cpp/TestAll-debug
- source script/export_ld_path.sh && hl out/hl/test.hl
- source script/export_ld_path.sh && out/hl/test/test
- haxe hxml/example_curl.cpp.hxml -D callfunc_unit_test
- haxe hxml/example_curl.hl.hxml -D callfunc_unit_test
- haxe hxml/example_random.cpp.hxml -D callfunc_unit_test
- haxe hxml/example_random.hl.hxml -D callfunc_unit_test