From nobody Sun Feb 8 23:06:18 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 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=1594893888; cv=none; d=zohomail.com; s=zohoarc; b=drD/I7Y4Ye1fzRkGpo3dB4R4DtDLjCEi5uBQxfX7SxILllWrbIoMX41XVWqSmVfsPzbDVuBoya8n8LRqUTcmuq5V9bASEJ/0xsfBkqO/r77qIdo9SxTR6ewnXUgMGTVv5mFJDFPYMiOq8dLdKZFs/vsEBYqYjbdrD+moI6O1CRc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1594893888; 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=DpeVVfqdkTZmQdAWlHiNB3ogHqRRhIKYV0Lp4U0IuME=; b=mN1mwcWURdQNaOtu1LQZCOIw/IZgzpExGIF5WczwhCBXxpAonAovxojlCrs+fzrJAd8JM5eA5HBmVQnYD2DZjHtzVdXiFcM0a0mSoKdd1QOBC8upLEBGg1bi0bg9w74nGeMVBrTK2ujmAUo+ZXlgAFM9EsMxwmK/UWjJk9MQ/Ec= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 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-delivery-1.mimecast.com (us-smtp-2.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1594893888279737.4689321116201; Thu, 16 Jul 2020 03:04:48 -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-467-IPKlCz-zO866kchbT8BzFA-1; Thu, 16 Jul 2020 06:03:27 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 2F47B1888AD1; Thu, 16 Jul 2020 10:03:20 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0C4C574F64; Thu, 16 Jul 2020 10:03:20 +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 CFBF29624E; Thu, 16 Jul 2020 10:03:19 +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 06GA3Igj017103 for ; Thu, 16 Jul 2020 06:03:18 -0400 Received: by smtp.corp.redhat.com (Postfix) id D06D72B6E2; Thu, 16 Jul 2020 10:03:18 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.194.85]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4A17C2DE6D for ; Thu, 16 Jul 2020 10:03:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594893886; 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=DpeVVfqdkTZmQdAWlHiNB3ogHqRRhIKYV0Lp4U0IuME=; b=V2NX0mfhO5f1Oc/URzjROa+jFqEE8WZ3QtpPKfEnq1AO2LMyzxgtCFJGtVUjaHG7b0K0V9 WYAJf1WNIyJLM8WIrrHB2/tO4JpSKGiAa6ej9cK0NAAkYp3p3+bKE//aLqPVd+SAvDZ47p k7CigGtN/kZvt/6nSMKqP/t/ambLo3o= X-MC-Unique: IPKlCz-zO866kchbT8BzFA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH 116/351] meson: add dtrace build dependency Date: Thu, 16 Jul 2020 11:55:52 +0200 Message-Id: <0d61f9e3b54b419ab604b1659e1d84da17bb220d.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.13 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 --- configure.ac | 7 ------- m4/virt-dtrace.m4 | 45 --------------------------------------------- meson.build | 8 ++++++++ meson_options.txt | 1 + 4 files changed, 9 insertions(+), 52 deletions(-) delete mode 100644 m4/virt-dtrace.m4 diff --git a/configure.ac b/configure.ac index d97bc702299..2f486df2e23 100644 --- a/configure.ac +++ b/configure.ac @@ -73,10 +73,6 @@ case $host in *-*-mingw* | *-*-msvc* ) with_win=3Dyes ;; esac =20 -if test $with_linux =3D no; then - with_dtrace=3Dno -fi - AM_CONDITIONAL([WITH_LINUX], [test "$with_linux" =3D "yes"]) AM_CONDITIONAL([WITH_FREEBSD], [test "$with_freebsd" =3D "yes"]) AM_CONDITIONAL([WITH_MACOS], [test "$with_macos" =3D "yes"]) @@ -101,7 +97,6 @@ dnl dnl Miscellaneous checks dnl =20 -LIBVIRT_ARG_DTRACE LIBVIRT_ARG_NUMAD LIBVIRT_ARG_INIT_SCRIPT LIBVIRT_ARG_LOGIN_SHELL @@ -110,7 +105,6 @@ LIBVIRT_ARG_TLS_PRIORITY LIBVIRT_ARG_SYSCTL_CONFIG =20 =20 -LIBVIRT_CHECK_DTRACE LIBVIRT_CHECK_NUMAD LIBVIRT_CHECK_INIT_SCRIPT LIBVIRT_CHECK_LOGIN_SHELL @@ -185,7 +179,6 @@ LIBVIRT_WIN_RESULT_WINDRES AC_MSG_NOTICE([]) AC_MSG_NOTICE([Miscellaneous]) AC_MSG_NOTICE([]) -LIBVIRT_RESULT_DTRACE LIBVIRT_RESULT_NUMAD LIBVIRT_RESULT_INIT_SCRIPT LIBVIRT_RESULT_LOGIN_SHELL diff --git a/m4/virt-dtrace.m4 b/m4/virt-dtrace.m4 deleted file mode 100644 index 3dc20d53436..00000000000 --- a/m4/virt-dtrace.m4 +++ /dev/null @@ -1,45 +0,0 @@ -dnl The DTrace static probes -dnl -dnl Copyright (C) 2016 Red Hat, Inc. -dnl -dnl This library is free software; you can redistribute it and/or -dnl modify it under the terms of the GNU Lesser General Public -dnl License as published by the Free Software Foundation; either -dnl version 2.1 of the License, or (at your option) any later version. -dnl -dnl This library is distributed in the hope that it will be useful, -dnl but WITHOUT ANY WARRANTY; without even the implied warranty of -dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -dnl Lesser General Public License for more details. -dnl -dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library. If not, see -dnl . -dnl - -AC_DEFUN([LIBVIRT_ARG_DTRACE], [ - LIBVIRT_ARG_WITH([DTRACE], [use dtrace for static probing], [check]) -]) - -AC_DEFUN([LIBVIRT_CHECK_DTRACE], [ - if test "$with_dtrace" !=3D "no" ; then - AC_PATH_PROG([DTRACE], [dtrace], [], [$LIBVIRT_SBIN_PATH]) - if test -z "$DTRACE" ; then - if test "$with_dtrace" =3D "check"; then - with_dtrace=3Dno - else - AC_MSG_ERROR([You must install the 'dtrace' binary to enable libvi= rt static probes]) - fi - else - with_dtrace=3Dyes - fi - if test "$with_dtrace" =3D "yes"; then - AC_DEFINE_UNQUOTED([WITH_DTRACE_PROBES], 1, [whether DTrace static p= robes are available]) - fi - fi - AM_CONDITIONAL([WITH_DTRACE_PROBES], [test "$with_dtrace" !=3D "no"]) -]) - -AC_DEFUN([LIBVIRT_RESULT_DTRACE], [ - LIBVIRT_RESULT([DTrace], [$with_dtrace]) -]) diff --git a/meson.build b/meson.build index 681874fd447..c7c5cdd3b40 100644 --- a/meson.build +++ b/meson.build @@ -2073,6 +2073,13 @@ if conf.has('WITH_LIBVIRTD') driver_modules_flags =3D libvirt_export_dynamic endif =20 +if host_machine.system() =3D=3D 'linux' + dtrace_prog =3D find_program('dtrace', required: get_option('dtrace'), d= irs: libvirt_sbin_path) + if dtrace_prog.found() + conf.set('WITH_DTRACE_PROBES', 1) + endif +endif + =20 # define top include directory =20 @@ -2197,6 +2204,7 @@ misc_summary =3D { 'Debug': conf.has('ENABLE_DEBUG'), 'Use -Werror': cc_flags.contains('-Werror'), 'Warning Flags': supported_cc_flags, + 'DTrace': conf.has('WITH_DTRACE_PROBES'), 'Char device locks': chrdev_lock_files, 'Default Editor': conf.get_unquoted('DEFAULT_EDITOR'), } diff --git a/meson_options.txt b/meson_options.txt index 476ed12a933..b12d0aa3d7b 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -93,3 +93,4 @@ option('storage_zfs', type: 'feature', value: 'auto', des= cription: 'ZFS backend option('chrdev_lock_files', type: 'string', value: '', description: 'locat= ion for UUCP style lock files for character devices (leave empty for defaul= t paths on some platforms)') option('debug_logs', type: 'boolean', value: true, description: 'enable de= bugging output') option('default_editor', type: 'string', value: 'vi', description: 'Editor= to use for interactive commands') +option('dtrace', type: 'feature', value: 'auto', description: 'use dtrace = for static probing') --=20 2.26.2