@@ -54,17 +54,17 @@ jobs:
5454 build_type : ' Debug'
5555 }
5656 - {
57- name : ' ubuntu-22.04 x64 release - assert warn' ,
57+ name : ' ubuntu-22.04 x64 debug - assert warn' ,
5858 os : ubuntu-22.04,
5959 arch : x64,
6060 build-system : ' cmake' ,
6161 diet-build : ' OFF' ,
6262 enable-asan : ' OFF' ,
63- build_type : ' Release ' ,
63+ build_type : ' Debug ' ,
6464 build_options : ' -DCAPSTONE_ASSERTION_WARNINGS=ON'
6565 }
6666 - {
67- name : ' ubuntu-22.04 x64 release - no asserts ' ,
67+ name : ' ubuntu-22.04 x64 release - no assert warnings ' ,
6868 os : ubuntu-22.04,
6969 arch : x64,
7070 build-system : ' cmake' ,
7373 build_type : ' Release' ,
7474 build_options : ' -DCAPSTONE_ASSERTION_WARNINGS=OFF'
7575 }
76+ - {
77+ name : ' ubuntu-22.04 x64 release - assert warn' ,
78+ os : ubuntu-22.04,
79+ arch : x64,
80+ build-system : ' cmake' ,
81+ diet-build : ' OFF' ,
82+ enable-asan : ' OFF' ,
83+ build_type : ' Release' ,
84+ build_options : ' -DCAPSTONE_ASSERTION_WARNINGS=ON'
85+ }
7686 - {
7787 name : ' ubuntu-24.04 x64 ASAN' ,
7888 os : ubuntu-24.04,
@@ -112,10 +122,10 @@ jobs:
112122 run : |
113123 mkdir build && cd build
114124 # build static library
115- cmake -DCAPSTONE_INSTALL=1 -DCMAKE_INSTALL_PREFIX=/usr -DENABLE_ASAN=${asan} -DCAPSTONE_BUILD_DIET=${diet_build} ${build_option} ..
125+ cmake -DCMAKE_BUILD_TYPE=${build_type} - DCAPSTONE_INSTALL=1 -DCMAKE_INSTALL_PREFIX=/usr -DENABLE_ASAN=${asan} -DCAPSTONE_BUILD_DIET=${diet_build} ${build_option} ..
116126 cmake --build . --config ${build_type}
117127 # build shared library
118- cmake -DCAPSTONE_INSTALL=1 -DCAPSTONE_BUILD_SHARED_LIBS=1 -DCMAKE_INSTALL_PREFIX=/usr -DCAPSTONE_BUILD_CSTEST=ON -DENABLE_ASAN=${asan} ${build_option} ..
128+ cmake -DCMAKE_BUILD_TYPE=${build_type} - DCAPSTONE_INSTALL=1 -DCAPSTONE_BUILD_SHARED_LIBS=1 -DCMAKE_INSTALL_PREFIX=/usr -DCAPSTONE_BUILD_CSTEST=ON -DENABLE_ASAN=${asan} ${build_option} ..
119129 sudo cmake --build . --config ${build_type} --target install
120130
121131 - name : Lower number of KASL randomized address bits
@@ -137,6 +147,16 @@ jobs:
137147 run : |
138148 sh suite/run_invalid_cstool.sh
139149
150+ - name : cstest negatives
151+ if : startsWith(matrix.config.build-system, 'cmake')
152+ run : |
153+ ctest --test-dir build --output-on-failure -R NegativeTests1
154+ ctest --test-dir build --output-on-failure -R NegativeTests2
155+ ctest --test-dir build --output-on-failure -R NegativeTests3
156+ ctest --test-dir build --output-on-failure -R NegativeTests4
157+ ctest --test-dir build --output-on-failure -R NegativeTests5
158+ ctest --test-dir build --output-on-failure -R NegativeTests6
159+
140160 - name : cstest MC
141161 if : startsWith(matrix.config.build-system, 'cmake')
142162 run : |
@@ -167,15 +187,23 @@ jobs:
167187 run : |
168188 sudo apt-get -y update
169189 sudo apt-get -y install valgrind
170- valgrind cstest tests
171-
172- - name : Comaptibility header generation
173- if : startsWith(matrix.config.build-system, 'cmake')
190+ valgrind --leak-check=full cstest tests/details
191+ valgrind --leak-check=full cstest tests/features
192+ valgrind --leak-check=full cstest tests/issues
193+ valgrind --leak-check=full cstest tests/MC
194+
195+ - name : Compatibility header generation
196+ # clang-format-17 is only available in Ubuntu 24.04
197+ # Hence the check only happens for it.
198+ if : startsWith(matrix.config.build-system, 'cmake') && startsWith(matrix.config.os, 'ubuntu-24.04')
174199 run : |
200+ sudo apt-get -y update
201+ sudo apt-get -y install clang-format-17
202+ clang-format-17 --version
175203 cp ./include/capstone/arm64.h arm64_compat_current.h
176204 cp ./include/capstone/systemz_compatibility.h systemz_compat_current.h
177- ./suite/auto-sync/src/autosync/HeaderPatcher.py -c --v6 ./include/capstone/aarch64.h --v5 ./include/capstone/arm64.h
178- ./suite/auto-sync/src/autosync/HeaderPatcher.py -c --v6 ./include/capstone/systemz.h --v5 ./include/capstone/systemz_compatibility.h
205+ ./suite/auto-sync/src/autosync/HeaderPatcher.py -C ./.clang-format - c --v6 ./include/capstone/aarch64.h --v5 ./include/capstone/arm64.h
206+ ./suite/auto-sync/src/autosync/HeaderPatcher.py -C ./.clang-format - c --v6 ./include/capstone/systemz.h --v5 ./include/capstone/systemz_compatibility.h
179207 diff ./include/capstone/arm64.h arm64_compat_current.h &&
180208 diff ./include/capstone/systemz_compatibility.h systemz_compat_current.h
181209
@@ -192,6 +220,14 @@ jobs:
192220 platform : windows
193221 python-arch : x64
194222 python-version : ' 3.9'
223+ diet_build : false
224+ - name : ' windows x64 MSVC 64bit DIET'
225+ os : windows-latest
226+ arch : x64
227+ platform : windows
228+ python-arch : x64
229+ python-version : ' 3.9'
230+ diet_build : true
195231
196232 steps :
197233 - uses : actions/checkout@v4
@@ -210,6 +246,6 @@ jobs:
210246 shell : bash
211247 run : |
212248 cmake --version
213- cmake --preset=${{ matrix.config.platform }}-x64
214- cmake --build --preset build-${{ matrix.config.platform }}-release
215- cmake --build --preset install-${{ matrix.config.platform }}-release
249+ cmake --preset=${{ matrix.config.platform }}-x64${{ matrix.config.diet_build == true && '-diet' || '' }}
250+ cmake --build --preset build-${{ matrix.config.platform }}${{ matrix.config.diet_build == true && '-diet' || '' }} -release
251+ cmake --build --preset install-${{ matrix.config.platform }}${{ matrix.config.diet_build == true && '-diet' || '' }} -release
0 commit comments