From nobody Sun Feb 8 22:08:26 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1594893660; cv=none; d=zohomail.com; s=zohoarc; b=ZXV+pOcO7s9bcmv3sk+9mhwNZfqrUzYELRQmGNLVnuVnjPmrsP7fsdhtmYubArwnrMSwGS8uI9ELywkvwUkGDziZJxyEr5iodMax3VG099UbBAiiYn+27vXpFWRK3umVa+lAlg2wnyKBCKx5fqJ7nhLtbu/GMeGKBvr752hc4Es= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1594893660; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=7qt9RIWZ+rSaqE+o1kSQ6frt5wpOCZMl7xE4SJnOESc=; b=OQnJ8mqvlrzeInCbRRney5CRSLoV/xhGQLFz1baPYbfJPPxqBv8BBv4S8xiG+p+6PRB/kQRt0gUZwmxRPh6WJrmkkm1YNj6TJDknvl+hwtHaLO7e182t4LVbIC10wK+od+1YOQ8E941zqHjX910Zo2jndeiBgIO0HW86bUPCk0E= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1594893660568935.8798997677479; Thu, 16 Jul 2020 03:01:00 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-168-OWV8RQ8XOtqLRCfYaxR9HA-1; Thu, 16 Jul 2020 06:00:56 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id BF3D41005260; Thu, 16 Jul 2020 10:00:48 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9EC39710D7; Thu, 16 Jul 2020 10:00:48 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 6B3F41805319; Thu, 16 Jul 2020 10:00:48 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 06GA0cPF015373 for ; Thu, 16 Jul 2020 06:00:38 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0AF2D2B6E6; Thu, 16 Jul 2020 10:00:38 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.194.85]) by smtp.corp.redhat.com (Postfix) with ESMTP id 794E22B6E2 for ; Thu, 16 Jul 2020 10:00:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594893659; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=7qt9RIWZ+rSaqE+o1kSQ6frt5wpOCZMl7xE4SJnOESc=; b=XDF5kBQVWgdkY7lMzGoDo4wu88Qqu25lkiMv3LSVAUEdTgL7YJlMLsbyrWvDMF/nlriMAF ik7AX95GjgaXzSrqYmQmVP4PSPniOE3u/l7H5orC/79y9vD3jrHQh0UeZlTuV0o5MtkN4B E8I5iPwPTcyKBC1jlaTNUreb8omlxis= X-MC-Unique: OWV8RQ8XOtqLRCfYaxR9HA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH 019/351] meson: add static analysis detection Date: Thu, 16 Jul 2020 11:54:15 +0200 Message-Id: <61f69916effc9f68992d4d0def092b4ec4c0273d.1594891445.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Pavel Hrdina Reviewed-by: J=C3=A1n Tomko --- configure.ac | 15 --------------- meson.build | 13 +++++++++++++ 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/configure.ac b/configure.ac index d76c2d22fc2..8f16b364de6 100644 --- a/configure.ac +++ b/configure.ac @@ -722,21 +722,6 @@ if test "$want_ifconfig" =3D "yes"; then AC_DEFINE_UNQUOTED([IFCONFIG_PATH], "$IFCONFIG_PATH", [path to ifconf= ig binary]) fi =20 -# Detect when running under the clang static analyzer's scan-build driver -# or Coverity-prevent's cov-build. Define STATIC_ANALYSIS accordingly. -AC_CACHE_CHECK([whether this build is done by a static analysis tool], - [lv_cv_static_analysis], [ - lv_cv_static_analysis=3Dno - if test -n "${CCC_ANALYZER_ANALYSIS+set}" || \ - test -n "$COVERITY_BUILD_COMMAND$COVERITY_LD_PRELOAD"; then - lv_cv_static_analysis=3Dyes - fi - ]) -t=3D0 -test "x$lv_cv_static_analysis" =3D xyes && t=3D1 -AC_DEFINE_UNQUOTED([STATIC_ANALYSIS], [$t], - [Define to 1 when performing static analysis.]) - GNUmakefile=3DGNUmakefile m4_if(m4_version_compare([2.61a.100], m4_defn([m4_PACKAGE_VERSION])), [1], [], diff --git a/meson.build b/meson.build index e91d664a77a..be5e64fc6d2 100644 --- a/meson.build +++ b/meson.build @@ -143,6 +143,19 @@ if get_option('test_coverage') endif =20 =20 +# Detect when running under the + +rc =3D run_command( + 'sh', '-c', + 'test -n "${CCC_ANALYZER_HTML}"' + + ' -o -n "${CCC_ANALYZER_ANALYSIS+set}"' + + ' -o -n "$COVERITY_BUILD_COMMAND$COVERITY_LD_PRELOAD"', +) +if rc.returncode() =3D=3D 0 + conf.set('STATIC_ANALYSIS', 1) +endif + + # figure out libvirt version strings =20 arr_version =3D meson.project_version().split('.') --=20 2.26.2