From e93cf4b851759f879d94ce7c531aef4193496da0 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 11:08:54 +0100 Subject: [PATCH 01/22] removed --- .github/workflows/CI-cygwin.yml | 49 ------- .github/workflows/CI-unixish.yml | 187 -------------------------- .github/workflows/CI-windows.yml | 151 --------------------- .github/workflows/asan.yml | 44 ------ .github/workflows/bughunting.yml | 47 ------- .github/workflows/buildman.yml | 25 ---- .github/workflows/clang-tidy.yml | 50 ------- .github/workflows/codeql-analysis.yml | 44 ------ .github/workflows/coverage.yml | 50 ------- .github/workflows/format.yml | 37 ----- .github/workflows/release-windows.yml | 121 ----------------- .github/workflows/scriptcheck.yml | 107 --------------- .github/workflows/ubsan.yml | 43 ------ .github/workflows/valgrind.yml | 52 ------- appveyor.yml | 72 ---------- 15 files changed, 1079 deletions(-) delete mode 100644 .github/workflows/CI-cygwin.yml delete mode 100644 .github/workflows/CI-unixish.yml delete mode 100644 .github/workflows/CI-windows.yml delete mode 100644 .github/workflows/asan.yml delete mode 100644 .github/workflows/bughunting.yml delete mode 100644 .github/workflows/buildman.yml delete mode 100644 .github/workflows/clang-tidy.yml delete mode 100644 .github/workflows/codeql-analysis.yml delete mode 100644 .github/workflows/coverage.yml delete mode 100644 .github/workflows/format.yml delete mode 100644 .github/workflows/release-windows.yml delete mode 100644 .github/workflows/scriptcheck.yml delete mode 100644 .github/workflows/ubsan.yml delete mode 100644 .github/workflows/valgrind.yml delete mode 100644 appveyor.yml diff --git a/.github/workflows/CI-cygwin.yml b/.github/workflows/CI-cygwin.yml deleted file mode 100644 index b640a38f43f..00000000000 --- a/.github/workflows/CI-cygwin.yml +++ /dev/null @@ -1,49 +0,0 @@ -# Some convenient links: -# - https://github.com/actions/virtual-environments/blob/master/images/win/Windows2019-Readme.md -# - -name: CI-cygwin - -on: [push,pull_request] - -defaults: - run: - shell: cmd - -jobs: - build_cygwin: - strategy: - matrix: - os: [windows-2019] - arch: [x64, x86] - fail-fast: true - - runs-on: ${{ matrix.os }} - - steps: - - uses: actions/checkout@v2 - - - name: Set up Cygwin - uses: egor-tensin/setup-cygwin@v3 - with: - platform: ${{ matrix.arch }} - - - name: Build cppcheck - run: | - C:\tools\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% && make -j2 - - - name: Build test - run: | - C:\tools\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% && make -j2 testrunner - - - name: Run test - run: | - C:\tools\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% && make -j2 check - - - name: Extra test for misra - run: | - C:\tools\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE%\addons\test - ..\..\cppcheck --dump -DDUMMY --suppress=uninitvar --inline-suppr misra\misra-test.c --std=c89 --platform=unix64 && python3 ..\misra.py -verify misra\misra-test.c.dump - C:\tools\cygwin\bin\bash.exe -l -c cd %GITHUB_WORKSPACE% - .\cppcheck --addon=misra --inline-suppr --enable=information --error-exitcode=1 addons\test\misra\misra-ctu-*-test.c - diff --git a/.github/workflows/CI-unixish.yml b/.github/workflows/CI-unixish.yml deleted file mode 100644 index 9caf53a767f..00000000000 --- a/.github/workflows/CI-unixish.yml +++ /dev/null @@ -1,187 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: CI-unixish - -on: [push, pull_request] - -jobs: - build: - - strategy: - matrix: - os: [ubuntu-18.04, ubuntu-20.04, macos-10.15] - fail-fast: false # Prefer quick result - - runs-on: ${{ matrix.os }} - - steps: - - uses: actions/checkout@v2 - - - name: Set up Python 3.10 - uses: actions/setup-python@v2 - with: - python-version: '3.10' - - - name: Install missing software on ubuntu 18.04 - if: matrix.os == 'ubuntu-18.04' - run: | - sudo apt-get update - sudo apt-get install libxml2-utils - sudo apt-get install z3 libz3-dev - cp externals/z3_version_old.h externals/z3_version.h - - - name: Install missing software on ubuntu 20.04 - if: matrix.os == 'ubuntu-20.04' - run: | - sudo apt-get update - sudo apt-get install libxml2-utils - sudo apt-get install z3 libz3-dev - - - name: Install missing software on macos - if: contains(matrix.os, 'macos') - run: | - brew install coreutils z3 - cp externals/z3_version_old.h externals/z3_version.h - - - name: Install missing Python packages - run: | - python -m pip install pip --upgrade - python -m pip install pytest - - - name: Install Qt - if: contains(matrix.os, 'ubuntu') - uses: jurplel/install-qt-action@v2 - with: - modules: 'qtcharts' - - - name: Test CMake build - run: | - mkdir cmake.output - cd cmake.output - cmake -G "Unix Makefiles" -DUSE_Z3=On -DHAVE_RULES=On -DBUILD_TESTS=On .. - make -j$(nproc) check - cd .. - - - name: Build and test with Unsigned char - run: | - make clean - make -j$(nproc) CXXFLAGS=-funsigned-char testrunner - ./testrunner TestSymbolDatabase - - - name: Check syntax with NONNEG - run: | - ls lib/*.cpp | xargs -n 1 -P $(nproc) g++ -fsyntax-only -std=c++0x -Ilib -Iexternals -Iexternals/picojson -Iexternals/simplecpp -Iexternals/tinyxml2 -DNONNEG - - - name: Build cppcheck - run: | - make clean - make -j$(nproc) USE_Z3=yes HAVE_RULES=yes - - - name: Build test - run: | - make -j$(nproc) testrunner USE_Z3=yes HAVE_RULES=yes - - - name: Run test - run: | - make -j$(nproc) check USE_Z3=yes HAVE_RULES=yes - - # the script uses sed parameters not supported by MacOS - - name: Run extra tests - if: contains(matrix.os, 'ubuntu') - run: | - tools/generate_and_run_more_tests.sh - - - name: Run test/cli - run: | - cd test/cli - pytest test-*.py - cd ../../.. - ln -s cppcheck 'cpp check' - cd 'cpp check/test/cli' - pytest test-*.py - - # fails on macos since some includes (e.g. sys/epoll.h) are not available - - name: Run cfg tests - if: contains(matrix.os, 'ubuntu') - run: | - make -j$(nproc) checkcfg - - # it seems macos has no "wc" command - - name: Run showtimetop5 tests - if: contains(matrix.os, 'ubuntu') - run: | - ./tools/test_showtimetop5.sh - - - name: Run --dump test - run: | - ./cppcheck test/testpreprocessor.cpp --dump - xmllint --noout test/testpreprocessor.cpp.dump - - - name: Validate - run: | - make -j$(nproc) checkCWEEntries validateXML - - - name: Test addons - run: | - ./cppcheck --addon=threadsafety addons/test/threadsafety - ./cppcheck --addon=threadsafety --std=c++03 addons/test/threadsafety - ./cppcheck --addon=misra --inline-suppr --enable=information --error-exitcode=1 addons/test/misra/misra-ctu-*-test.c - cd addons/test - ../../cppcheck --dump -DDUMMY --suppress=uninitvar --inline-suppr misra/misra-test.c --std=c89 --platform=unix64 && python3 ../misra.py -verify misra/misra-test.c.dump - ../../cppcheck --addon=misra --platform=avr8 --error-exitcode=1 misra/misra-test-avr8.c - - - name: Build GUI on ubuntu - if: contains(matrix.os, 'ubuntu') - run: | - pushd gui - qmake HAVE_QCHART=yes - make -j$(nproc) - - - name: Run GUI tests on ubuntu - if: contains(matrix.os, 'ubuntu') - run: | - pushd gui/test/projectfile - qmake - make -j$(nproc) - ./test-projectfile - popd - pushd gui/test/cppchecklibrarydata - qmake - make -j$(nproc) - ./test-cppchecklibrarydata - - - name: Generate Qt help file on ubuntu - if: contains(matrix.os, 'ubuntu') - run: | - pushd gui/help - qhelpgenerator online-help.qhcp -o online-help.qhc - - # Run self check after "Build GUI" to include generated headers in analysis - - name: Self check - if: matrix.os == 'ubuntu-20.04' - run: | - # compile with verification and ast matchers - make clean - make -j$(nproc) -s CPPFLAGS="-DCHECK_INTERNAL" CXXFLAGS="-g -O2" MATCHCOMPILER=yes VERIFY=1 - # self check lib/cli - mkdir b1 - ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck --cppcheck-build-dir=b1 -D__CPPCHECK__ --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=cppcheck-lib --addon=naming.json -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ -Icli --inconclusive --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings cli lib - # check gui with qt settings - mkdir b2 - ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck --cppcheck-build-dir=b2 -D__CPPCHECK__ -DQT_VERSION=0x050000 --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=qt --addon=naming.json -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings gui/*.cpp - # self check test and tools - ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=cppcheck-lib -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ -Icli -Igui --inconclusive --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings test/*.cpp tools - - - name: Build triage on ubuntu - if: matrix.os == 'ubuntu-20.04' - run: | - pushd tools/triage - qmake - make -j$(nproc) - - - name: Build Fuzzer - if: matrix.os == 'ubuntu-20.04' - run: | - pushd oss-fuzz - make -j$(nproc) CXX=clang++ CXXFLAGS="-fsanitize=address" fuzz-client translate - diff --git a/.github/workflows/CI-windows.yml b/.github/workflows/CI-windows.yml deleted file mode 100644 index fef067e66cc..00000000000 --- a/.github/workflows/CI-windows.yml +++ /dev/null @@ -1,151 +0,0 @@ -# Some convenient links: -# - https://github.com/actions/virtual-environments/blob/master/images/win/Windows2019-Readme.md -# - -name: CI-windows - -on: [push,pull_request] - -defaults: - run: - shell: cmd - -jobs: - - build: - strategy: - matrix: - os: [windows-2019] - arch: [x64, x86] - qt_ver: ['', 5.9.9, 5.15.2] - fail-fast: false - - runs-on: ${{ matrix.os }} - - steps: - - uses: actions/checkout@v2 - - - name: Set up Python 3.10 - if: matrix.qt_ver == '' - uses: actions/setup-python@v2 - with: - python-version: '3.10' - - - name: Setup msbuild.exe - if: matrix.qt_ver == '' - uses: microsoft/setup-msbuild@v1.0.2 - - - name: Install PCRE - if: false - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.arch }} || exit /b !errorlevel! - curl -fsSL https://ftp.pcre.org/pub/pcre/pcre-%PCRE_VERSION%.zip -o pcre-%PCRE_VERSION%.zip || exit /b !errorlevel! - 7z x pcre-%PCRE_VERSION%.zip || exit /b !errorlevel! - cd pcre-%PCRE_VERSION% || exit /b !errorlevel! - cmake . -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release -DPCRE_BUILD_PCRECPP=Off -DPCRE_BUILD_TESTS=Off -DPCRE_BUILD_PCREGREP=Off || exit /b !errorlevel! - nmake || exit /b !errorlevel! - copy pcre.h ..\externals || exit /b !errorlevel! - if "${{ matrix.arch }}" == "x86" ( - copy pcre.lib ..\externals\pcre.lib || exit /b !errorlevel! - ) else ( - copy pcre.lib ..\externals\pcre64.lib || exit /b !errorlevel! - ) - env: - # see https://www.pcre.org/original/changelog.txt - PCRE_VERSION: 8.44 - CL: /MP - - - name: Install Z3 library - run: | - curl -fsSL https://github.com/Z3Prover/z3/releases/download/z3-%Z3_VERSION%/z3-%Z3_VERSION%-${{ matrix.arch }}-win.zip -o z3-%Z3_VERSION%-win.zip || exit /b !errorlevel! - 7z x z3-%Z3_VERSION%-win.zip -oexternals -r -y || exit /b !errorlevel! - move externals\z3-%Z3_VERSION%-${{ matrix.arch }}-win externals\z3 || exit /b !errorlevel! - env: - # see https://github.com/Z3Prover/z3/releases: - Z3_VERSION: 4.8.10 - - # no 32-bit Qt available - - name: Install Qt ${{ matrix.qt_ver }} - if: matrix.qt_ver != '' && matrix.arch == 'x64' - uses: jurplel/install-qt-action@v2 - with: - version: ${{ matrix.qt_ver }} - modules: 'qtcharts' - - - name: Install missing Python packages - if: matrix.qt_ver == '' - run: | - python -m pip install pip --upgrade || exit /b !errorlevel! - python -m pip install pytest || exit /b !errorlevel! - python -m pip install pytest-custom_exit_code || exit /b !errorlevel! - - - name: Build GUI release - if: matrix.qt_ver != '' && matrix.arch == 'x64' - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.arch }} || exit /b !errorlevel! - cd gui || exit /b !errorlevel! - qmake HAVE_QCHART=yes || exit /b !errorlevel! - nmake release || exit /b !errorlevel! - env: - CL: /MP - - - name: Deploy GUI - if: matrix.qt_ver != '' && matrix.arch == 'x64' - run: | - windeployqt Build\gui || exit /b !errorlevel! - del Build\gui\cppcheck-gui.ilk || exit /b !errorlevel! - del Build\gui\cppcheck-gui.pdb || exit /b !errorlevel! - - - name: Configure MSBuild - if: matrix.qt_ver == '' - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.arch }} || exit /b !errorlevel! - set ARCH=${{ matrix.arch }} - if "${{ matrix.arch }}" == "x86" ( - set ARCH=Win32 - ) - rm -rf build - mkdir build - cd build - cmake -DBUILD_TESTS=On .. || exit /b !errorlevel! - - - name: Build CLI debug configuration using MSBuild - if: matrix.qt_ver == '' - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.arch }} || exit /b !errorlevel! - set ARCH=${{ matrix.arch }} - if "${{ matrix.arch }}" == "x86" ( - set ARCH=Win32 - ) - cmake --build build --target check --config Debug || exit /b !errorlevel! - - - name: Build CLI release configuration using MSBuild - if: matrix.qt_ver == '' - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.arch }} || exit /b !errorlevel! - set ARCH=${{ matrix.arch }} - if "${{ matrix.arch }}" == "x86" ( - set ARCH=Win32 - ) - cmake --build build --target check --config Release || exit /b !errorlevel! - - - name: Run test/cli - if: matrix.qt_ver == '' - run: | - :: since FILESDIR is not set copy the binary to the root so the addons are found - copy .\build\bin\Release\cppcheck.exe .\cppcheck.exe || exit /b !errorlevel! - cd test/cli || exit /b !errorlevel! - :: python -m pytest --suppress-no-test-exit-code test-clang-import.py || exit /b !errorlevel! - python -m pytest test-helloworld.py || exit /b !errorlevel! - python -m pytest test-inline-suppress.py || exit /b !errorlevel! - python -m pytest test-more-projects.py || exit /b !errorlevel! - python -m pytest test-proj2.py || exit /b !errorlevel! - python -m pytest test-suppress-syntaxError.py || exit /b !errorlevel! - - - name: Test addons - if: matrix.qt_ver == '' - run: | - .\cppcheck.exe --addon=misra --inline-suppr --enable=information --error-exitcode=1 addons\test\misra\misra-ctu-*-test.c - cd addons\test - ..\..\cppcheck.exe --dump -DDUMMY --suppress=uninitvar --inline-suppr misra\misra-test.c --std=c89 --platform=unix64 && python3 ..\misra.py -verify misra\misra-test.c.dump - diff --git a/.github/workflows/asan.yml b/.github/workflows/asan.yml deleted file mode 100644 index c1854a3481e..00000000000 --- a/.github/workflows/asan.yml +++ /dev/null @@ -1,44 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: address sanitizer - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - - env: - ASAN_OPTIONS: detect_stack_use_after_return=1 - - steps: - - uses: actions/checkout@v2 - - - name: Install missing software on ubuntu - run: | - sudo apt-get update - sudo apt-get install libz3-4 libz3-dev - - - name: Build - run: make -j$(nproc) cppcheck testrunner USE_Z3=yes HAVE_RULES=yes MATCHCOMPILER=yes VERIFY=1 - env: - CC: clang - CXX: clang++ - CXXFLAGS: "-fsanitize=address -O1 -g3 -DCPPCHK_GLIBCXX_DEBUG" - CPPFLAGS: "-DCHECK_INTERNAL" - - - name: Run tests - run: ./testrunner - -# Does not work -# - name: Self check -# run: | -# ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=cppcheck-lib -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ -Icli --inconclusive --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings cli lib -# ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ -DQT_VERSION=0x050000 --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=qt -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings gui/*.cpp -# ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=cppcheck-lib -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ -Icli -Igui --inconclusive --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings test/*.cpp tools - -# This takes too long time right now -# - name: Bughunting lib -# run: ./cppcheck -D__CPPCHECK__ --bug-hunting -j$(nproc) lib - diff --git a/.github/workflows/bughunting.yml b/.github/workflows/bughunting.yml deleted file mode 100644 index 8f88c2a6c43..00000000000 --- a/.github/workflows/bughunting.yml +++ /dev/null @@ -1,47 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: bughunting - -# TODO: enable this when -on: workflow_dispatch - -jobs: - build: - - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - - - name: Set up Python 3.10 - uses: actions/setup-python@v2 - with: - python-version: '3.10' - - - name: Install missing software - run: | - sudo apt-get update - sudo apt-get install z3 libz3-dev - - - name: Build cppcheck - run: | - make -j$(nproc) USE_Z3=yes HAVE_RULES=yes MATCHCOMPILER=yes - env: - CXXFLAGS: "-O2 -march=native" - - # currently to slow to execute it in the CI - - name: Run CVE suite - run: | - python test/bug-hunting/cve.py - - - name: Run ITC suite - run: | - git clone https://github.com/regehr/itc-benchmarks.git ~/itc - python test/bug-hunting/itc.py - - - name: Run juliet - run: | - mkdir ~/juliet - curl https://samate.nist.gov/SARD/testsuites/juliet/Juliet_Test_Suite_v1.3_for_C_Cpp.zip -o ~/juliet/juliet.zip - cd ~/juliet && unzip -qq ~/juliet/juliet.zip - python test/bug-hunting/juliet.py diff --git a/.github/workflows/buildman.yml b/.github/workflows/buildman.yml deleted file mode 100644 index cf2b5c2afcc..00000000000 --- a/.github/workflows/buildman.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: Build manual - -on: [push, pull_request] - -jobs: - convert_via_pandoc: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v2 - - - run: | - mkdir output - - - uses: docker://pandoc/latex:2.9 - with: - args: --output=output/manual.html man/manual.md - - - uses: docker://pandoc/latex:2.9 - with: - args: --output=output/manual.pdf man/manual.md - - - uses: actions/upload-artifact@v2 - with: - name: output - path: output diff --git a/.github/workflows/clang-tidy.yml b/.github/workflows/clang-tidy.yml deleted file mode 100644 index 3cbb5effcfc..00000000000 --- a/.github/workflows/clang-tidy.yml +++ /dev/null @@ -1,50 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: clang-tidy - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - - container: - image: "ubuntu:21.10" - - steps: - - uses: actions/checkout@v2 - - - name: Install missing software - run: | - apt-get update - apt-get install -y cmake g++ make - apt-get install -y z3 libz3-dev - apt-get install -y libpcre3-dev - apt-get install -y libffi7 # work around missing dependency for Qt install step - apt-get install -y software-properties-common - add-apt-repository universe - apt-get update - apt-get install -y clang-tidy-13 - - - name: Install Qt - uses: jurplel/install-qt-action@v2 - with: - install-deps: 'nosudo' - version: '5.15.2' - modules: 'qtcharts' - - - name: Prepare CMake - run: | - mkdir cmake.output - cd cmake.output - cmake -G "Unix Makefiles" -DUSE_Z3=On -DHAVE_RULES=On -DBUILD_TESTS=On -DBUILD_GUI=On -DBUILD_TESTS=On -DBUILD_GUI=On -DWITH_QCHART=On -DCMAKE_GLOBAL_AUTOGEN_TARGET=On .. - cd .. - - - name: Clang-Tidy - run: | - # make sure the precompiled headers exist - make -C cmake.output lib/CMakeFiles/lib_objs.dir/cmake_pch.hxx.cxx - make -C cmake.output test/CMakeFiles/testrunner.dir/cmake_pch.hxx.cxx - make -C cmake.output autogen - cmake --build cmake.output --target run-clang-tidy 2> /dev/null diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml deleted file mode 100644 index 1734626ef15..00000000000 --- a/.github/workflows/codeql-analysis.yml +++ /dev/null @@ -1,44 +0,0 @@ -name: "CodeQL" - -on: [push, pull_request] - -jobs: - analyze: - name: Analyze - runs-on: ubuntu-20.04 - - strategy: - fail-fast: false - matrix: - # Override automatic language detection by changing the below list - # Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python'] - language: ['cpp', 'python'] - # Learn more... - # https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection - - steps: - - name: Checkout repository - uses: actions/checkout@v2 - - - name: Install missing software on ubuntu - run: | - sudo apt-get update - sudo apt-get install libxml2-utils - sudo apt-get install libz3-dev libz3-4 - - # Initializes the CodeQL tools for scanning. - - name: Initialize CodeQL - uses: github/codeql-action/init@v1 - with: - languages: ${{ matrix.language }} - # If you wish to specify custom queries, you can do so here or in a config file. - # By default, queries listed here will override any specified in a config file. - # Prefix the list here with "+" to use these queries and those in the config file. - # queries: ./path/to/local/query, your-org/your-repo/queries@main - setup-python-dependencies: false - - - run: | - make -j$(nproc) USE_Z3=yes HAVE_RULES=yes cppcheck - - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v1 diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml deleted file mode 100644 index 120db3e9fd1..00000000000 --- a/.github/workflows/coverage.yml +++ /dev/null @@ -1,50 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: Coverage - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - - - name: Install missing software on ubuntu - run: | - sudo apt-get update - sudo apt-get install libxml2-utils - sudo apt-get install libz3-dev libz3-4 - sudo apt-get install lcov - sudo apt-get install libcppunit-dev - python -m pip install pip --upgrade - python -m pip install lcov_cobertura - - - name: Compile instrumented - run: | - make -j$(nproc) test CXXFLAGS="-g -fprofile-arcs -ftest-coverage" USE_Z3=yes HAVE_RULES=yes - - - name: Generate coverage report - run: | - rm -rf coverage_report - ./testrunner - test/cfg/runtests.sh - gcov lib/*.cpp -o lib/ - lcov --directory ./ --capture --output-file lcov_tmp.info -b ./ - lcov --extract lcov_tmp.info "$(pwd)/*" --output-file lcov.info - genhtml lcov.info -o coverage_report --frame --legend --demangle-cpp - - - uses: actions/upload-artifact@v2 - with: - name: Coverage results - path: coverage_report - - - uses: codecov/codecov-action@v1.2.1 - with: - # token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos - # file: ./coverage.xml # optional - flags: unittests # optional - name: ${{ github.repository }} # optional - fail_ci_if_error: true # optional (default = false): diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml deleted file mode 100644 index 8d5f8a19b64..00000000000 --- a/.github/workflows/format.yml +++ /dev/null @@ -1,37 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: format - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - - - name: Cache uncrustify - uses: actions/cache@v2 - id: cache-uncrustify - with: - path: | - ~/uncrustify - key: ${{ runner.os }}-uncrustify - - - name: build uncrustify - if: steps.cache-uncrustify.outputs.cache-hit != 'true' - run: | - wget https://github.com/uncrustify/uncrustify/archive/refs/tags/uncrustify-0.72.0.tar.gz - tar xzvf uncrustify-0.72.0.tar.gz && cd uncrustify-uncrustify-0.72.0 - mkdir build - cd build - cmake -DCMAKE_BUILD_TYPE=Release .. - make -j$(nproc) -s - mkdir ~/uncrustify - cp uncrustify ~/uncrustify/ - - - name: Uncrustify check - run: | - ~/uncrustify/uncrustify -c .uncrustify.cfg -l CPP --check */*.cpp */*.h diff --git a/.github/workflows/release-windows.yml b/.github/workflows/release-windows.yml deleted file mode 100644 index f63271f595b..00000000000 --- a/.github/workflows/release-windows.yml +++ /dev/null @@ -1,121 +0,0 @@ -# Some convenient links: -# - https://github.com/actions/virtual-environments/blob/master/images/win/Windows2019-Readme.md -# - -name: release-windows - -on: - push: - tags: - - '2.*' - schedule: - - cron: '0 0 * * *' - workflow_dispatch: - -defaults: - run: - shell: cmd - -jobs: - - build: - - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - - - name: Setup msbuild.exe - uses: microsoft/setup-msbuild@v1.0.2 - - - name: Install PCRE - run: | - curl -fsSL https://github.com/pfultz2/pcre/archive/refs/tags/8.45.zip -o pcre-8.45.zip - 7z x pcre-8.45.zip - cd pcre-8.45 - cmake . -G "Visual Studio 16 2019" -A x64 - msbuild -m PCRE.sln /p:Configuration=Release /p:Platform=x64 - dir - dir Release - dir x64 - dir x64\Release - copy pcre.h ..\externals - copy Release\pcre.lib ..\externals\pcre64.lib - - - name: Install Z3 library - run: | - curl -fsSL https://github.com/Z3Prover/z3/releases/download/z3-4.8.7/z3-4.8.7-x64-win.zip -o z3-4.8.7-win.zip - 7z x z3-4.8.7-win.zip -oexternals -r -y - move externals\z3-4.8.7-x64-win externals\z3 - - - name: Install Qt - uses: jurplel/install-qt-action@v2 - with: - version: '5.15.2' - modules: 'qtcharts qthelp' - - - name: Create .qm - run: | - cd gui - lupdate gui.pro - lrelease gui.pro -removeidentical - - - name: Matchcompiler - run: python tools\matchcompiler.py --write-dir lib - - - name: Build x64 release GUI - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat" - cd gui - qmake HAVE_QCHART=yes - nmake release - env: - CL: /MP - - - name: Deploy app - run: | - windeployqt Build\gui - del Build\gui\cppcheck-gui.ilk - del Build\gui\cppcheck-gui.pdb - - - name: Build CLI x64 release configuration using MSBuild - run: msbuild -m cppcheck.sln /t:cli /p:Configuration=Release-PCRE /p:Platform=x64 - - - name: Collect files - run: | - move Build\gui win_installer\files - mkdir win_installer\files\addons - copy addons\*.* win_installer\files\addons - mkdir win_installer\files\cfg - copy cfg\*.cfg win_installer\files\cfg - mkdir win_installer\files\platforms - copy platforms\*.xml win_installer\files\platforms - copy bin\cppcheck.exe win_installer\files - copy bin\cppcheck-core.dll win_installer\files - copy externals\z3\bin\libz3.dll win_installer\files - mkdir win_installer\files\help - xcopy /s gui\help win_installer\files\help - del win_installer\files\translations\*.qm - move gui\*.qm win_installer\files\translations - - - - name: Build Installer - run: | - call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat" - cd win_installer - REM Read ProductVersion - for /f "tokens=4 delims= " %%a in ('find "ProductVersion" productInfo.wxi') do set PRODUCTVER=%%a - REM Remove double quotes - set PRODUCTVER=%PRODUCTVER:"=% - echo ProductVersion=%PRODUCTVER% - msbuild -m cppcheck.wixproj /p:Platform=x64,ProductVersion=%PRODUCTVER%.${{ github.run_number }} - - - uses: actions/upload-artifact@v2 - with: - name: installer - path: win_installer/Build/ - - - uses: actions/upload-artifact@v2 - with: - name: deploy - path: win_installer\files diff --git a/.github/workflows/scriptcheck.yml b/.github/workflows/scriptcheck.yml deleted file mode 100644 index 9bb5dec874a..00000000000 --- a/.github/workflows/scriptcheck.yml +++ /dev/null @@ -1,107 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: scriptcheck - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - strategy: - matrix: - python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, '3.10'] - fail-fast: false - - steps: - - uses: actions/checkout@v2 - - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 - with: - python-version: ${{ matrix.python-version }} - - - name: Install missing software on ubuntu - run: | - sudo apt-get update - sudo apt-get install tidy libxml2-utils - - - name: Install missing software on ubuntu (Python 2) - if: matrix.python-version == '2.7' - run: | - python -m pip install pip --upgrade - python -m pip install pytest - python -m pip install pygments - - - name: Install missing software on ubuntu (Python 3) - if: matrix.python-version != '2.7' - run: | - sudo apt-get install shellcheck - python -m pip install pip --upgrade - python -m pip install natsort - python -m pip install pexpect - python -m pip install pylint - python -m pip install unittest2 - python -m pip install pytest - python -m pip install pygments - python -m pip install requests - python -m pip install psutil - - - name: run Shellcheck - if: matrix.python-version == '3.10' - run: | - find . -name "*.sh" | xargs shellcheck --exclude SC2002,SC2013,SC2034,SC2035,SC2043,SC2046,SC2086,SC2089,SC2090,SC2129,SC2211,SC2231 - - - name: run pylint - if: matrix.python-version == '3.10' - run: | - pylint --rcfile=pylintrc_travis --jobs $(nproc) addons/*.py htmlreport/cppcheck-htmlreport htmlreport/*.py tools/*.py - - - name: check .json files - if: matrix.python-version == '3.10' - run: | - find . -name '*.json' | xargs -n 1 python -m json.tool > /dev/null - - - name: Validate - if: matrix.python-version == '3.10' - run: | - make -j$(nproc) validateCFG validatePlatforms validateRules - - - name: check python syntax - if: matrix.python-version != '2.7' - run: | - python -m py_compile addons/*.py - python -m py_compile htmlreport/cppcheck-htmlreport - python -m py_compile htmlreport/*.py - python -m py_compile tools/*.py - - - name: compile addons - run: | - python -m compileall ./addons - - - name: test matchcompiler - run: | - python tools/test_matchcompiler.py - - - name: build cppcheck - run: | - make -j$(nproc) -s - - - name: test addons - run: | - python -m pytest addons/test/test-*.py - env: - PYTHONPATH: ./addons - - - name: test htmlreport - run: | - htmlreport/test_htmlreport.py - cd htmlreport - ./check.sh - - - name: dmake - if: matrix.python-version == '3.10' - run: | - make -j$(nproc) run-dmake - git diff --exit-code - diff --git a/.github/workflows/ubsan.yml b/.github/workflows/ubsan.yml deleted file mode 100644 index f50ef22c7b3..00000000000 --- a/.github/workflows/ubsan.yml +++ /dev/null @@ -1,43 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: undefined behaviour sanitizers - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - - env: - UBSAN_OPTIONS: print_stacktrace=1:halt_on_error=1 - - steps: - - uses: actions/checkout@v2 - - - name: Install missing software on ubuntu - run: | - sudo apt-get update - sudo apt-get install libz3-4 libz3-dev - - - name: Build - run: make -j$(nproc) cppcheck testrunner USE_Z3=yes HAVE_RULES=yes MATCHCOMPILER=yes VERIFY=1 - env: - CC: clang - CXX: clang++ - CXXFLAGS: "-fsanitize=undefined -fsanitize=nullability -fno-sanitize=signed-integer-overflow -O1 -g3 -DCPPCHK_GLIBCXX_DEBUG" - CPPFLAGS: "-DCHECK_INTERNAL" - - - name: Run tests - run: ./testrunner - - - name: Self check - run: | - ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=cppcheck-lib -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ -Icli --inconclusive --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings cli lib - ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ -DQT_VERSION=0x050000 --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=qt -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings gui/*.cpp - ./cppcheck -q -j$(nproc) --std=c++11 --template=selfcheck -D__CPPCHECK__ --error-exitcode=1 --inline-suppr --suppressions-list=.travis_suppressions --library=cppcheck-lib -Ilib -Iexternals/simplecpp/ -Iexternals/tinyxml2/ -Icli -Igui --inconclusive --enable=style,performance,portability,warning,internal --exception-handling --debug-warnings test/*.cpp tools - -# This takes too long time right now -# - name: Bughunting lib -# run: ./cppcheck -D__CPPCHECK__ --bug-hunting -j$(nproc) lib - diff --git a/.github/workflows/valgrind.yml b/.github/workflows/valgrind.yml deleted file mode 100644 index 5f9bb5b978d..00000000000 --- a/.github/workflows/valgrind.yml +++ /dev/null @@ -1,52 +0,0 @@ -# Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions -# Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners -name: valgrind - -on: [push, pull_request] - -jobs: - build: - - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - - - name: Prepare - run: | - sudo apt-get update - sudo apt-get install debian-goodies ubuntu-dbgsym-keyring - # the key expired and the ubuntu-dbgsym-keyring package does not yet include the latest one - see https://bugs.launchpad.net/ubuntu/+source/ubuntu-keyring/+bug/1920640 - wget -O - http://ddebs.ubuntu.com/dbgsym-release-key.asc | sudo apt-key add - - - - name: Add debug repos on ubuntu - run: | - echo "deb http://ddebs.ubuntu.com $(lsb_release -cs) main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ddebs.list - echo "deb http://ddebs.ubuntu.com $(lsb_release -cs)-updates main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ddebs.list - echo "deb http://ddebs.ubuntu.com $(lsb_release -cs)-proposed main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ddebs.list - - - name: Install missing software - run: | - sudo apt-get update - sudo apt-get install libxml2-utils - sudo apt-get install valgrind - sudo apt-get install libz3-dev libz3-4 libz3-4-dbgsym - sudo apt-get install libc6-dbg-amd64-cross - - - name: Build cppcheck - run: | - CXXFLAGS="-O1 -g" make -j$(nproc) USE_Z3=yes HAVE_RULES=yes MATCHCOMPILER=yes - - - name: Build test - run: | - CXXFLAGS="-O1 -g" make -j$(nproc) testrunner USE_Z3=yes HAVE_RULES=yes MATCHCOMPILER=yes - - - name: Run valgrind - run: | - valgrind --error-limit=yes --leak-check=full --num-callers=50 --show-reachable=yes --track-origins=yes --suppressions=valgrind/testrunner.supp --gen-suppressions=all --log-fd=9 --error-exitcode=42 ./testrunner TestGarbage TestOther TestSimplifyTemplate 9>memcheck.log - cat memcheck.log - - - uses: actions/upload-artifact@v2 - with: - name: Logs - path: ./*.log diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index c4b6a19aa4f..00000000000 --- a/appveyor.yml +++ /dev/null @@ -1,72 +0,0 @@ -version: '{build}' - -clone_depth: 10 - -matrix: - fast_finish: true - -environment: - matrix: - - VisualStudioVersion: 12.0 - platform: x64 - configuration: Debug - vcvarsall_platform: x64 - PlatformToolset: v120 - MYQTDIR: C:\Qt\5.6\msvc2013_64 - - VisualStudioVersion: 12.0 - platform: x64 - configuration: Release - vcvarsall_platform: x64 - PlatformToolset: v120 -# FIXME: These are disabled for now. They were broken by ae8653612802b41b70424ec9a5eefe8a1178f6d1 -# - VisualStudioVersion: 14.0 -# platform: x64 -# configuration: Debug -# vcvarsall_platform: x64 -# PlatformToolset: v140 -# MYQTDIR: C:\Qt\5.11\msvc2015_64 -# That platform causes frequent errors on appveyor due to an unknown infrastructure failure -# - VisualStudioVersion: 14.0 -# platform: x64 -# configuration: Release -# vcvarsall_platform: x64 -# PlatformToolset: v140 - -install: - - curl -fsSL https://github.com/Z3Prover/z3/releases/download/z3-4.8.9/z3-4.8.9-%platform%-win.zip -o z3-4.8.9-win.zip - - 7z x z3-4.8.9-win.zip -oexternals -r -y - - move externals\z3-4.8.9-%platform%-win externals\z3 - -build_script: - - ECHO Building %configuration% %platform% with MSVC %VisualStudioVersion% using %PlatformToolset% PlatformToolset - - 'CALL "C:\Program Files (x86)\Microsoft Visual Studio %VisualStudioVersion%\VC\vcvarsall.bat" %vcvarsall_platform%' - # Visual studio project.. - - mkdir vsbuild - - cd vsbuild - - cmake -DBUILD_TESTS=ON -DCTEST_TIMEOUT=240 .. - - cmake --build . --target check --config %configuration% - - cd .. - # the following builds are Debug ones so do not perform them in Release jobs - - 'IF "%configuration%" == "Release" exit /b 0' - # use all available processes for nmake - - set CL=/MP - # cmake.. - - mkdir build - - cd build - - cmake -DBUILD_TESTS=ON -G"NMake Makefiles" .. - - nmake - - copy bin\cppcheck.exe .. - - cd .. - # build gui.. - - ECHO MYQTDIR=%MYQTDIR% - - 'IF defined MYQTDIR cd gui' - - 'IF defined MYQTDIR set QTDIR=%MYQTDIR%' - - 'IF defined MYQTDIR set PATH=%PATH%;%QTDIR%\bin' - - 'IF defined MYQTDIR %QTDIR%\bin\qmake' - - 'IF defined MYQTDIR nmake' - - 'IF defined MYQTDIR cd ..' - -test_script: - - build\bin\testrunner.exe -q - - IF EXIST bin\debug\testrunner.exe bin\debug\testrunner.exe -q - - IF EXIST bin\testrunner.exe bin\testrunner.exe -q From 42c85f5710a0027172797745d2cce51723c58cd7 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 11:09:40 +0100 Subject: [PATCH 02/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 55fdadd5270..611f5e1fe93 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -9,7 +9,7 @@ jobs: strategy: matrix: - image: ["centos:7", "ubuntu:14.04", "ubuntu:16.04", "ubuntu:21.10"] + image: ["ubuntu:12.04"] fail-fast: false # Prefer quick result runs-on: ubuntu-20.04 From d2e9d9332a3f7fda2b7362116990b2f79569f949 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 17:58:35 +0100 Subject: [PATCH 03/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 611f5e1fe93..9536a3dac1b 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -18,6 +18,12 @@ jobs: image: ${{ matrix.image }} steps: + - name: Install missing software on ubuntu 12.04 + if: matrix.image == 'ubuntu:12.04' + run: | + apt-get update + apt-get install libstdc++6 + - uses: actions/checkout@v2 - name: Install missing software on CentOS 7 From f0af9548c3a9831f9858e20c3bd10173f632027f Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:18:42 +0100 Subject: [PATCH 04/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 9536a3dac1b..70913fe76f6 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -21,6 +21,9 @@ jobs: - name: Install missing software on ubuntu 12.04 if: matrix.image == 'ubuntu:12.04' run: | + echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list + echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list + echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list apt-get update apt-get install libstdc++6 From 994b1492a109011f47329f9c5fcf82baf49fbf64 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:23:15 +0100 Subject: [PATCH 05/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 70913fe76f6..21bcf68c112 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -18,14 +18,14 @@ jobs: image: ${{ matrix.image }} steps: - - name: Install missing software on ubuntu 12.04 + - name: Prepare EOL repositories for ubuntu 12.04 if: matrix.image == 'ubuntu:12.04' run: | echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list - apt-get update - apt-get install libstdc++6 + strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX + strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - uses: actions/checkout@v2 From 024ea04bdb25fc57a206d1c167db969e9d221e44 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:25:16 +0100 Subject: [PATCH 06/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 21bcf68c112..22dea90fe97 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -24,6 +24,8 @@ jobs: echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list + apt-get update + apt-get install binutils strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC From f44d4314a5a6266d4f66bd7ee48c39a3d5ded840 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:39:12 +0100 Subject: [PATCH 07/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 22dea90fe97..4ffb549398f 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -28,6 +28,11 @@ jobs: apt-get install binutils strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC + apt-get install software-properties-common + add-apt-repository ppa:ubuntu-toolchain-r/test + apt-get update + apt-get install libstdc++6-4.6-dev + strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX - uses: actions/checkout@v2 From 78d6efe9772ccd5237fbe4a023984d3ea3d8d922 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:40:17 +0100 Subject: [PATCH 08/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 4ffb549398f..d05f2ab86be 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -25,13 +25,13 @@ jobs: echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list apt-get update - apt-get install binutils + apt-get install -y binutils strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - apt-get install software-properties-common + apt-get install -y software-properties-common add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update - apt-get install libstdc++6-4.6-dev + apt-get install -y libstdc++6-4.6-dev strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX - uses: actions/checkout@v2 From e98bd789b98a3b8f039c16b65a05446e753d5efd Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:41:48 +0100 Subject: [PATCH 09/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index d05f2ab86be..930c612c5c8 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -28,7 +28,7 @@ jobs: apt-get install -y binutils strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - apt-get install -y software-properties-common + apt-get install -y python-software-properties add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update apt-get install -y libstdc++6-4.6-dev From ec65674de625681ac1ffa55fd7a062c498b7ab85 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:44:28 +0100 Subject: [PATCH 10/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 930c612c5c8..59b01a8adef 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -26,13 +26,12 @@ jobs: echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list apt-get update apt-get install -y binutils - strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC apt-get install -y python-software-properties add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update apt-get install -y libstdc++6-4.6-dev - strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX + strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - uses: actions/checkout@v2 From e042276555a770cde8a4cf8cabc68b4f91112137 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:52:40 +0100 Subject: [PATCH 11/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 59b01a8adef..5910bc299b9 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -31,6 +31,7 @@ jobs: add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update apt-get install -y libstdc++6-4.6-dev + apt-get -t testing install -< libc6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - uses: actions/checkout@v2 From 5aaa253810d7e91cf742952d0b4bfcc4bceea0df Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:52:48 +0100 Subject: [PATCH 12/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 5910bc299b9..8687620e716 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -31,7 +31,7 @@ jobs: add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update apt-get install -y libstdc++6-4.6-dev - apt-get -t testing install -< libc6-dev + apt-get -t testing install -y libc6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - uses: actions/checkout@v2 From b5ab7a3783c562a8409def1c1a419e527709c71c Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:54:55 +0100 Subject: [PATCH 13/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 8687620e716..59b01a8adef 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -31,7 +31,6 @@ jobs: add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update apt-get install -y libstdc++6-4.6-dev - apt-get -t testing install -y libc6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - uses: actions/checkout@v2 From 8b853eb02dd5ceee8f13f8ff8854372051283651 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:56:27 +0100 Subject: [PATCH 14/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 59b01a8adef..3140f7aa7e0 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -18,18 +18,21 @@ jobs: image: ${{ matrix.image }} steps: - - name: Prepare EOL repositories for ubuntu 12.04 + - name: Install prerequisites for ubuntu 12.04 if: matrix.image == 'ubuntu:12.04' run: | + # set up EOL repositories echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list apt-get update apt-get install -y binutils strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC + # add PPA to be able to install newer toolchains apt-get install -y python-software-properties add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update + # install to satisfy GLBCXX requirement from bin/node used by GitHub action - also gives us GCC 4.6 apt-get install -y libstdc++6-4.6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC From 77ecbcfeee3ae4a4c1b91d8849eb167213f5498b Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:56:58 +0100 Subject: [PATCH 15/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 3140f7aa7e0..994448d194a 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -25,6 +25,7 @@ jobs: echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list + # update so the new repositories are being used apt-get update apt-get install -y binutils strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC From 723b415aca8ad2132a3bb34738a6475f214d5b6f Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:57:09 +0100 Subject: [PATCH 16/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 994448d194a..9cc8a565d76 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -33,7 +33,7 @@ jobs: apt-get install -y python-software-properties add-apt-repository ppa:ubuntu-toolchain-r/test apt-get update - # install to satisfy GLBCXX requirement from bin/node used by GitHub action - also gives us GCC 4.6 + # install to satisfy GLBCXX requirement of bin/node used by GitHub action - also gives us GCC 4.6 apt-get install -y libstdc++6-4.6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC From 3efc1d861baec35b562adc14a8b3fa0343fea8b2 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:57:18 +0100 Subject: [PATCH 17/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 9cc8a565d76..aa4344e2c32 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -25,7 +25,6 @@ jobs: echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list - # update so the new repositories are being used apt-get update apt-get install -y binutils strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC From 2fb7fb70ffa73dc51e33056a7a3966ded7062b79 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:57:43 +0100 Subject: [PATCH 18/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index aa4344e2c32..2e9a6a2126a 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -36,7 +36,7 @@ jobs: apt-get install -y libstdc++6-4.6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - - uses: actions/checkout@v2 + - name: Install missing software on CentOS 7 if: matrix.image == 'centos:7' From 7018614e9bda0c19959f0e3f7e558c3581f6f510 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 18:59:17 +0100 Subject: [PATCH 19/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 2e9a6a2126a..2e6e250d954 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -50,6 +50,7 @@ jobs: apt-get update apt-get install -y cmake g++ make python libxml2-utils apt-get install -y libpcre3-dev + g++ --version # tests require CMake 3.4 - name: Test CMake build (no tests) From 6055e69c009d4e2c82b516373249205c777f7768 Mon Sep 17 00:00:00 2001 From: firewave Date: Sat, 6 Nov 2021 19:04:03 +0100 Subject: [PATCH 20/22] ub-12.04 --- .github/workflows/CI-unixish-docker.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 2e6e250d954..aa4344e2c32 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -36,7 +36,7 @@ jobs: apt-get install -y libstdc++6-4.6-dev strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - + - uses: actions/checkout@v2 - name: Install missing software on CentOS 7 if: matrix.image == 'centos:7' @@ -50,7 +50,6 @@ jobs: apt-get update apt-get install -y cmake g++ make python libxml2-utils apt-get install -y libpcre3-dev - g++ --version # tests require CMake 3.4 - name: Test CMake build (no tests) From 434536c1582e98945bbc6e91d5fdfc2be6a3c161 Mon Sep 17 00:00:00 2001 From: firewave Date: Tue, 30 Nov 2021 15:44:17 +0100 Subject: [PATCH 21/22] gcc46 --- .github/workflows/CI-unixish-docker.yml | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index aa4344e2c32..80033098373 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -9,7 +9,7 @@ jobs: strategy: matrix: - image: ["ubuntu:12.04"] + image: ["ubuntu:16.04"] fail-fast: false # Prefer quick result runs-on: ubuntu-20.04 @@ -18,23 +18,13 @@ jobs: image: ${{ matrix.image }} steps: - - name: Install prerequisites for ubuntu 12.04 - if: matrix.image == 'ubuntu:12.04' + - name: Install prerequisites for ubuntu 16.04 + if: matrix.image == 'ubuntu:16.04' run: | - # set up EOL repositories - echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise main restricted universe multiverse' > /etc/apt/sources.list - echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse' >> /etc/apt/sources.list - echo 'deb http://old-releases.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse' >> /etc/apt/sources.list apt-get update - apt-get install -y binutils - strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC - # add PPA to be able to install newer toolchains - apt-get install -y python-software-properties - add-apt-repository ppa:ubuntu-toolchain-r/test - apt-get update - # install to satisfy GLBCXX requirement of bin/node used by GitHub action - also gives us GCC 4.6 - apt-get install -y libstdc++6-4.6-dev - strings /lib/x86_64-linux-gnu/libc.so.6 | grep GLIBC + apt-get install -y gcc-4.6 + # set compiler for subsequent steps + echo "CXX=gcc-4.6" >> $GITHUB_ENV - uses: actions/checkout@v2 From 1eee42badc4717869bef4fe188976fc6c9bb4183 Mon Sep 17 00:00:00 2001 From: firewave Date: Tue, 30 Nov 2021 15:48:51 +0100 Subject: [PATCH 22/22] gcc46 --- .github/workflows/CI-unixish-docker.yml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index 80033098373..7a9f9f2b105 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -9,7 +9,7 @@ jobs: strategy: matrix: - image: ["ubuntu:16.04"] + image: ["gcc:4.6"] fail-fast: false # Prefer quick result runs-on: ubuntu-20.04 @@ -18,13 +18,10 @@ jobs: image: ${{ matrix.image }} steps: - - name: Install prerequisites for ubuntu 16.04 - if: matrix.image == 'ubuntu:16.04' + - name: Install prerequisites for gcc:4.6 + if: matrix.image == 'gcc:4.6' run: | - apt-get update - apt-get install -y gcc-4.6 - # set compiler for subsequent steps - echo "CXX=gcc-4.6" >> $GITHUB_ENV + #echo "CXX=gcc-4.6" >> $GITHUB_ENV - uses: actions/checkout@v2