diff --git a/.github/workflows/CI-unixish-docker.yml b/.github/workflows/CI-unixish-docker.yml index a38feb452f0..d4468732028 100644 --- a/.github/workflows/CI-unixish-docker.yml +++ b/.github/workflows/CI-unixish-docker.yml @@ -87,7 +87,7 @@ jobs: strategy: matrix: - image: ["ubuntu:24.04", "ubuntu:25.10", "alpine:3.23"] + image: ["ubuntu:24.04", "ubuntu:25.10", "alpine:3.23", "oraclelinux:8"] fail-fast: false # Prefer quick result runs-on: ubuntu-22.04 @@ -111,6 +111,12 @@ jobs: run: | apk add make g++ pcre-dev bash python3 libxml2-utils + - name: Install missing software on Oracle Linux + if: contains(matrix.image, 'oraclelinux') + run: | + yum install -y git python3 which epel-release + yum install -y cmake3 gcc-c++ make pcre-devel + # needs to be called after the package installation since # - it doesn't call "apt-get update" - name: ccache diff --git a/lib/settings.cpp b/lib/settings.cpp index 95d4c4e953b..57c5def45a0 100644 --- a/lib/settings.cpp +++ b/lib/settings.cpp @@ -79,8 +79,8 @@ Settings::~Settings() = default; Settings::Settings(const Settings&) = default; Settings & Settings::operator=(const Settings &) = default; -Settings::Settings(Settings&&) noexcept = default; -Settings & Settings::operator=(Settings &&) noexcept = default; +Settings::Settings(Settings&&) NOEXCEPT = default; +Settings & Settings::operator=(Settings &&) NOEXCEPT = default; std::string Settings::loadCppcheckCfg(Settings& settings, Suppressions& suppressions, bool debug) { diff --git a/lib/settings.h b/lib/settings.h index 04ddb9adb9a..3af7f08fb71 100644 --- a/lib/settings.h +++ b/lib/settings.h @@ -94,6 +94,18 @@ class SimpleEnableGroup { }; +#if defined(__GNUC__) && __GNUC__ <= 9 +// Hack to workaround GCC bug. +// Details: https://trac.cppcheck.net/ticket/14850 +// seen on: +// oraclelinux:8, g++-8.5 +// ubuntu:20.04, g++-9.4.0 +#define NOEXCEPT +#else +#define NOEXCEPT noexcept +#endif + + /** * @brief This is just a container for general settings so that we don't need * to pass individual values to functions or constructors now or in the @@ -113,8 +125,8 @@ class CPPCHECKLIB WARN_UNUSED Settings { Settings(const Settings&); Settings& operator=(const Settings&); - Settings(Settings&&) noexcept; - Settings& operator=(Settings&&) noexcept; + Settings(Settings&&) NOEXCEPT; + Settings& operator=(Settings&&) NOEXCEPT; static std::string loadCppcheckCfg(Settings& settings, Suppressions& suppressions, bool debug = false);