1616 - uses : actions/checkout@v4
1717 - name : dependencies
1818 run : |
19- sudo apt install gcc-10 g++-10 libgcc-10-dev libunwind8-dev
19+ sudo apt install gcc-10 g++-10 libgcc-10-dev libunwind8-dev ninja-build
2020 pip3 install colorama
2121 - name : libdwarf
2222 run : |
@@ -36,15 +36,15 @@ jobs:
3636 - uses : actions/checkout@v4
3737 - name : dependencies
3838 run : |
39- sudo apt install gcc-10 g++-10 libgcc-10-dev libunwind8-dev
40- pip3 install colorama
39+ sudo apt install gcc-10 g++-10 libgcc-10-dev libunwind8-dev ninja-build
40+ pip3 install colorama
4141 - name : libdwarf
4242 run : |
43- cd ..
44- cpptrace/ci/setup-prerequisites.sh
43+ cd ..
44+ cpptrace/ci/setup-prerequisites.sh
4545 - name : build and test
4646 run : |
47- python3 ci/test-all-configs.py --${{matrix.compiler}} --default-config
47+ python3 ci/test-all-configs.py --${{matrix.compiler}} --default-config
4848 test-macos :
4949 runs-on : macos-14
5050 strategy :
@@ -125,7 +125,7 @@ jobs:
125125 - uses : actions/checkout@v4
126126 - name : dependencies
127127 run : |
128- sudo apt install gcc-10 g++-10 libgcc-10-dev libunwind8-dev
128+ sudo apt install gcc-10 g++-10 libgcc-10-dev libunwind8-dev ninja-build
129129 pip3 install colorama
130130 - name : libdwarf
131131 run : |
@@ -261,20 +261,21 @@ jobs:
261261 steps :
262262 - uses : actions/checkout@v4
263263 - name : dependencies
264- run : sudo apt install gcc-11 g++-11 libgcc-11-dev
264+ run : sudo apt install gcc-11 g++-11 libgcc-11-dev ninja-build
265265 - name : build
266266 run : |
267267 mkdir -p build
268268 cd build
269- cmake .. -DCMAKE_CXX_COMPILER=${{matrix.compiler}} -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=foo
270- make -j
271- make install
269+ cmake .. -GNinja - DCMAKE_CXX_COMPILER=${{matrix.compiler}} -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=foo
270+ ninja
271+ ninja install
272272 mkdir -p ../test/speedtest/build
273273 cd ../test/speedtest/build
274274 cmake .. \
275+ -GNinja \
275276 -DCMAKE_BUILD_TYPE=Debug \
276277 ${{matrix.config}}
277- make -j
278+ ninja
278279 - name : speedtest
279280 working-directory : test/speedtest/build
280281 run : |
@@ -298,8 +299,8 @@ jobs:
298299 cp -rv cpptrace/test/fetchcontent-integration .
299300 mkdir fetchcontent-integration/build
300301 cd fetchcontent-integration/build
301- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCPPTRACE_TAG=$tag -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
302- make
302+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DCPPTRACE_TAG=$tag -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
303+ ninja
303304 ./main
304305 test-linux-findpackage :
305306 runs-on : ubuntu-22.04
@@ -315,14 +316,14 @@ jobs:
315316 tag=$(git rev-parse --abbrev-ref HEAD)
316317 mkdir build
317318 cd build
318- cmake .. -DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
319- sudo make -j install
319+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
320+ sudo ninja install
320321 cd ../..
321322 cp -rv cpptrace/test/findpackage-integration .
322323 mkdir findpackage-integration/build
323324 cd findpackage-integration/build
324- cmake .. -DCMAKE_BUILD_TYPE=Debug
325- make
325+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug
326+ ninja
326327 ./main
327328 test-linux-add_subdirectory :
328329 runs-on : ubuntu-22.04
@@ -340,8 +341,8 @@ jobs:
340341 cp -rv cpptrace add_subdirectory-integration
341342 mkdir add_subdirectory-integration/build
342343 cd add_subdirectory-integration/build
343- cmake .. -DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
344- make
344+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
345+ ninja
345346 ./main
346347
347348 test-macos-fetchcontent :
@@ -361,8 +362,8 @@ jobs:
361362 cp -rv cpptrace/test/fetchcontent-integration .
362363 mkdir fetchcontent-integration/build
363364 cd fetchcontent-integration/build
364- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCPPTRACE_TAG=$tag -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
365- make
365+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DCPPTRACE_TAG=$tag -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
366+ ninja
366367 ./main
367368 test-macos-findpackage :
368369 runs-on : macos-14
@@ -379,14 +380,14 @@ jobs:
379380 echo $tag
380381 mkdir build
381382 cd build
382- cmake .. -DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
383- sudo make -j install
383+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
384+ sudo ninja install
384385 cd ../..
385386 cp -rv cpptrace/test/findpackage-integration .
386387 mkdir findpackage-integration/build
387388 cd findpackage-integration/build
388- cmake .. -DCMAKE_BUILD_TYPE=Debug
389- make
389+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug
390+ ninja
390391 ./main
391392 test-macos-add_subdirectory :
392393 runs-on : macos-14
@@ -404,8 +405,8 @@ jobs:
404405 cp -rv cpptrace add_subdirectory-integration
405406 mkdir add_subdirectory-integration/build
406407 cd add_subdirectory-integration/build
407- cmake .. -DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
408- make
408+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
409+ ninja
409410 ./main
410411
411412 test-mingw-fetchcontent :
@@ -425,8 +426,8 @@ jobs:
425426 cp -Recurse cpptrace/test/fetchcontent-integration .
426427 mkdir fetchcontent-integration/build
427428 cd fetchcontent-integration/build
428- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCPPTRACE_TAG="$tag" "-GUnix Makefiles " -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
429- make
429+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DCPPTRACE_TAG="$tag" -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
430+ ninja
430431 .\main.exe
431432 test-mingw-findpackage :
432433 runs-on : windows-2022
@@ -443,14 +444,14 @@ jobs:
443444 echo $tag
444445 mkdir build
445446 cd build
446- cmake .. -DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} "-GUnix Makefiles" -DCMAKE_INSTALL_PREFIX=C:/foo -DCPPTRACE_WERROR_BUILD=On
447- make -j install
447+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCMAKE_INSTALL_PREFIX=C:/foo -DCPPTRACE_WERROR_BUILD=On
448+ ninja install
448449 cd ../..
449450 mv cpptrace/test/findpackage-integration .
450451 mkdir findpackage-integration/build
451452 cd findpackage-integration/build
452- cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_PREFIX_PATH=C:/foo "-GUnix Makefiles"
453- make
453+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DCMAKE_PREFIX_PATH=C:/foo
454+ ninja
454455 ./main
455456 test-mingw-add_subdirectory :
456457 runs-on : windows-2022
@@ -468,8 +469,8 @@ jobs:
468469 cp -Recurse cpptrace add_subdirectory-integration
469470 mkdir add_subdirectory-integration/build
470471 cd add_subdirectory-integration/build
471- cmake .. -DCMAKE_BUILD_TYPE=Debug "-GUnix Makefiles" -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
472- make
472+ cmake .. -GNinja - DCMAKE_BUILD_TYPE=Debug -DBUILD_SHARED_LIBS=${{matrix.shared}} -DCPPTRACE_WERROR_BUILD=On
473+ ninja
473474 .\main.exe
474475 test-windows-fetchcontent :
475476 runs-on : windows-2022
@@ -559,7 +560,7 @@ jobs:
559560 - uses : actions/checkout@v4
560561 - name : dependencies
561562 run : |
562- sudo apt install gcc-10 g++-10 libgcc-10-dev ninja-build libc++-dev
563+ sudo apt install gcc-10 g++-10 libgcc-10-dev ninja-build libc++-dev ninja-build
563564 cd ..
564565 cpptrace/ci/setup-prerequisites-unittest.sh
565566 - name : build and test
@@ -598,7 +599,7 @@ jobs:
598599 - uses : actions/checkout@v4
599600 - name : dependencies
600601 run : |
601- sudo apt install gcc-10 g++-10 libgcc-10-dev ninja-build libc++-dev
602+ sudo apt install gcc-10 g++-10 libgcc-10-dev ninja-build libc++-dev ninja-build
602603 cd ..
603604 cpptrace/ci/setup-prerequisites-unittest.sh
604605 - name : build and test
@@ -650,3 +651,134 @@ jobs:
650651 cmake --build . --config ${{matrix.build_type}}
651652 ./${{matrix.build_type}}/unittest
652653 # TODO: Macos, mingw
654+
655+ unittest-linux-modules :
656+ runs-on : ubuntu-24.04
657+ needs : unittest-linux
658+ strategy :
659+ fail-fast : false
660+ steps :
661+ - uses : actions/checkout@v4
662+ - name : dependencies
663+ run : |
664+ sudo apt install ninja-build clang-19 clang-tools-19
665+ - name : build and test
666+ run : |
667+ mkdir build
668+ cd build
669+ cmake .. \
670+ -GNinja \
671+ -DCMAKE_BUILD_TYPE=Debug \
672+ -DCMAKE_CXX_COMPILER=clang++-19 \
673+ -DCMAKE_C_COMPILER=clang-19 \
674+ -DCMAKE_CXX_STANDARD=20 \
675+ -DCPPTRACE_WERROR_BUILD=On \
676+ -DCPPTRACE_STD_FORMAT=Off \
677+ -DCPPTRACE_BUILD_TESTING=On
678+ ninja
679+ ./unittest_module
680+
681+ unittest-linux-32-bit :
682+ runs-on : ubuntu-24.04
683+ needs : unittest-linux
684+ strategy :
685+ fail-fast : false
686+ matrix :
687+ compiler : [g++-10, clang++-18]
688+ steps :
689+ - uses : actions/checkout@v4
690+ - name : dependencies
691+ run : |
692+ sudo apt update
693+ sudo apt install gcc-10 g++-10 libgcc-10-dev clang-19 clang-tools-19 ninja-build gcc-multilib g++-multilib g++-10-multilib
694+ - name : build and test
695+ run : |
696+ mkdir build
697+ cd build
698+ cmake .. \
699+ -GNinja \
700+ -DCMAKE_BUILD_TYPE=Debug \
701+ -DCMAKE_CXX_COMPILER=${{matrix.compiler}} \
702+ -DCMAKE_C_COMPILER=${{matrix.compiler == 'clang++-18' && 'clang' || 'gcc'}} \
703+ -DCPPTRACE_WERROR_BUILD=On \
704+ -DCPPTRACE_STD_FORMAT=Off \
705+ -DCPPTRACE_BUILD_TESTING=On \
706+ -DCMAKE_C_FLAGS=-m32 \
707+ -DCMAKE_CXX_FLAGS=-m32
708+ ninja
709+ ./unittest
710+
711+ unittest-linux-gcc-4-8-5 :
712+ runs-on : ubuntu-24.04
713+ needs : unittest-linux
714+ steps :
715+ - uses : actions/checkout@v4
716+ - name : dependencies
717+ run : |
718+ sudo apt update
719+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/g++-4.8_4.8.5-4ubuntu8_amd64.deb
720+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/libstdc++-4.8-dev_4.8.5-4ubuntu8_amd64.deb
721+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/gcc-4.8-base_4.8.5-4ubuntu8_amd64.deb
722+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/gcc-4.8_4.8.5-4ubuntu8_amd64.deb
723+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/libgcc-4.8-dev_4.8.5-4ubuntu8_amd64.deb
724+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/cpp-4.8_4.8.5-4ubuntu8_amd64.deb
725+ wget http://mirrors.kernel.org/ubuntu/pool/universe/g/gcc-4.8/libasan0_4.8.5-4ubuntu8_amd64.deb
726+ sudo apt install ./gcc-4.8_4.8.5-4ubuntu8_amd64.deb ./gcc-4.8-base_4.8.5-4ubuntu8_amd64.deb ./libstdc++-4.8-dev_4.8.5-4ubuntu8_amd64.deb ./cpp-4.8_4.8.5-4ubuntu8_amd64.deb ./libgcc-4.8-dev_4.8.5-4ubuntu8_amd64.deb ./libasan0_4.8.5-4ubuntu8_amd64.deb ./g++-4.8_4.8.5-4ubuntu8_amd64.deb
727+ - name : build and test
728+ run : |
729+ mkdir build
730+ cd build
731+ cmake .. \
732+ -GNinja \
733+ -DCMAKE_BUILD_TYPE=Debug \
734+ -DCMAKE_CXX_COMPILER=g++-4.8 \
735+ -DCMAKE_C_COMPILER=gcc-4.8 \
736+ -DCPPTRACE_WERROR_BUILD=On \
737+ -DCPPTRACE_STD_FORMAT=Off
738+ ninja
739+
740+ unittest-windows-32-bit :
741+ runs-on : windows-2022
742+ needs : unittest-windows
743+ strategy :
744+ fail-fast : false
745+ matrix :
746+ build_type : [Debug]
747+ steps :
748+ - uses : actions/checkout@v4
749+ - name : Enable Developer Command Prompt
750+ 751+ - name : build and test
752+ run : |
753+ mkdir build
754+ cd build
755+ cmake .. `
756+ -A Win32 `
757+ -DCPPTRACE_WERROR_BUILD=On `
758+ -DCPPTRACE_BUILD_TESTING=On
759+ cmake --build . --config ${{matrix.build_type}}
760+ ./${{matrix.build_type}}/unittest
761+
762+ unittest-windows-clangcl :
763+ runs-on : windows-2022
764+ needs : unittest-windows
765+ strategy :
766+ fail-fast : false
767+ matrix :
768+ build_type : [Debug]
769+ arch : [x64, Win32]
770+ steps :
771+ - uses : actions/checkout@v4
772+ - name : Enable Developer Command Prompt
773+ 774+ - name : build and test
775+ run : |
776+ mkdir build
777+ cd build
778+ cmake .. `
779+ -T ClangCL `
780+ -A ${{matrix.arch}} `
781+ -DCPPTRACE_WERROR_BUILD=On `
782+ -DCPPTRACE_BUILD_TESTING=On
783+ cmake --build . --config ${{matrix.build_type}}
784+ ./${{matrix.build_type}}/unittest
0 commit comments