blob: f09b75e815a16cb8a89d22329c15e29f70f45a33 (
plain)
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
|
#!/usr/bin/env bash
if [[ $1 == "CI" ]]
then
ODIN="Odin/odin"
else
ODIN="odin"
fi
if [[ $1 == "CI" ]]
then
#BUG in odin test, it makes the executable with the same name as a folder and gets confused.
cd tests
../${ODIN} test ../tests -collection:shared=../src -opt:2
if ([ $? -ne 0 ])
then
echo "Test failed"
exit 1
fi
cd ..
fi
if [[ $1 == "test" ]]
then
#BUG in odin test, it makes the executable with the same name as a folder and gets confused.
cd tests
${ODIN} test ../tests -collection:shared=../src
if ([ $? -ne 0 ])
then
echo "Test failed"
exit 1
fi
cd ..
fi
${ODIN} build src/ -show-timings -collection:shared=src -out:ols -o:speed
|