From 3312a9f93466ee7f681135a354880d9dce9e0f3c Mon Sep 17 00:00:00 2001 From: Coldfirex Date: Tue, 20 Jul 2021 04:04:20 -0500 Subject: [PATCH] Add support for Haiku (#3342) * Update cppcheckexecutor.cpp * Update threadexecutor.cpp --- cli/cppcheckexecutor.cpp | 2 +- cli/threadexecutor.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cli/cppcheckexecutor.cpp b/cli/cppcheckexecutor.cpp index 1e5cdb3c5..5066ff3d3 100644 --- a/cli/cppcheckexecutor.cpp +++ b/cli/cppcheckexecutor.cpp @@ -53,7 +53,7 @@ # include # undef _XOPEN_SOURCE -#elif !defined(__OpenBSD__) +#elif !defined(__OpenBSD__) && !defined(__HAIKU__) # include #endif #ifdef __linux__ diff --git a/cli/threadexecutor.cpp b/cli/threadexecutor.cpp index b1b3c6ffc..c7b2e1fad 100644 --- a/cli/threadexecutor.cpp +++ b/cli/threadexecutor.cpp @@ -149,7 +149,7 @@ int ThreadExecutor::handleRead(int rpipe, unsigned int &result) bool ThreadExecutor::checkLoadAverage(size_t nchildren) { -#if defined(__CYGWIN__) || defined(__QNX__) // getloadavg() is unsupported on Cygwin, Qnx. +#if defined(__CYGWIN__) || defined(__QNX__) || defined(__HAIKU__) // getloadavg() is unsupported on Cygwin, Qnx, Haiku. return true; #else if (!nchildren || !mSettings.loadAverage) {