-
Notifications
You must be signed in to change notification settings - Fork 65
/
.cirrus.yml
67 lines (57 loc) · 1.82 KB
/
.cirrus.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
main_task:
matrix:
- name: freebsd_12_1
freebsd_instance:
image_family: freebsd-12-1
- name: freebsd_13_0
freebsd_instance:
image_family: freebsd-13-0
install_script:
- uname -a
- pkg install -y cmake
script:
- CMAKE_C_FLAGS="-Werror"
- CMAKE_CXX_FLAGS="-Werror"
- ls
- cc --version
- c++ --version
# Basic c build
- cd lib
- cc -Wall -Wextra -Werror --std=gnu89 fort.c -c -o fort.o
- rm fort.o
- cd ..
# Basic c++ build
- cd lib
- cp fort.c fort.cpp
- c++ -Wall -Wextra -Werror fort.cpp -c -o fort.o
- rm fort.o
- rm fort.cpp
- cd ..
# Perform out-of-source build(CMake backend generation, build, and test)
# Test build without optimizations and with asan
- mkdir -p build
- cd build
- cmake .. -DFORT_BUILD_TYPE=asan -DCMAKE_BUILD_TYPE=Debug -DCMAKE_C_STANDARD=99 -DCMAKE_CXX_STANDARD=11 -DCMAKE_C_FLAGS="${CMAKE_C_FLAGS}" -DCMAKE_CXX_FLAGS="${CMAKE_CXX_FLAGS}"
- cmake --build . --target all
- ls
- ctest -VV
- cd ..
- rm -r build/*
# Test build without optimizations and with ubsan
- mkdir -p build
- cd build
- cmake .. -DFORT_BUILD_TYPE=ubsan -DCMAKE_BUILD_TYPE=Debug -DCMAKE_C_STANDARD=99 -DCMAKE_CXX_STANDARD=11 -DCMAKE_C_FLAGS="${CMAKE_C_FLAGS}" -DCMAKE_CXX_FLAGS="${CMAKE_CXX_FLAGS}"
- cmake --build . --target all
- ls
- ctest -VV
- cd ..
- rm -r build/*
# Test without WCHAR and UTF-8 support
- mkdir -p build
- cd build
- cmake .. -DFORT_ENABLE_WCHAR=OFF -DFORT_ENABLE_UTF8=OFF -DCMAKE_BUILD_TYPE=Debug -DCMAKE_C_STANDARD=99 -DCMAKE_CXX_STANDARD=11 -DCMAKE_C_FLAGS="${CMAKE_C_FLAGS}" -DCMAKE_CXX_FLAGS="${CMAKE_CXX_FLAGS}"
- cmake --build . --target all
- ls
- ctest -VV
- cd ..
- rm -r build/*