From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) client-ip=63.128.21.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 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=1618852484; cv=none; d=zohomail.com; s=zohoarc; b=hBisaxtpWJrUT6MYQGfRxMJ8xCV3P+4b759SUh+ovB0KO10BwvCCLVUHeB47G6XA/iE8PHwuPD3orscMwd1ENXJecw8aWOq0/JqznOhJH0XIfo6LlRQ/hr7GeceLXgmIqjuW9AYY5KvWaO7tsHSGaVl9TKs/dlRymfl06LjXeII= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852484; 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=r0S4jNo0m9RyHA6CgdVr+owipUpZWhAOAxHJ7hPgigY=; b=oJDFLjOxAd+qmPRVw0G+/Y21c2u+aAeiPq+joAgEZMyJHvTdQPfVAjDAUjOy7JDjmzHUxEhc2nUIkrTdgdlCHoMFQFfaDSnQ6bEA8skpfwbhPkbjcWQA+uzDxMuUxjpOyqVcLUkvxvcO3ECL9ndGK3uM8ZAVuzhj7rekIBKPX+U= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.zohomail.com with SMTPS id 1618852484214717.986927964931; Mon, 19 Apr 2021 10:14:44 -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-594-w3ipt665MoyUZlfjiCVc3g-1; Mon, 19 Apr 2021 13:14:41 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 40B556D582; Mon, 19 Apr 2021 17:14:36 +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 23BCD19C66; Mon, 19 Apr 2021 17:14:35 +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 7BE291809C82; Mon, 19 Apr 2021 17:14:33 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEUB2021789 for ; Mon, 19 Apr 2021 13:14:30 -0400 Received: by smtp.corp.redhat.com (Postfix) id 539CA5D72E; Mon, 19 Apr 2021 17:14:30 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id C89AE5D742 for ; Mon, 19 Apr 2021 17:14:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852483; 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=r0S4jNo0m9RyHA6CgdVr+owipUpZWhAOAxHJ7hPgigY=; b=NjCl3vcH8uGSPPvGSaiWQxtL9NExanS3kuA8+yREBqWYE+YuZVxeQJZ15nLIffsBw9fulm JjUiXghxCQ1S/LHagzwrY2Whpqae5gfRPfVdCY8auwnTUE7i2GVCvvxekUBGOOOaQaTYQZ lSITtq9D81tU3/784Ta1tXQn8a915mM= X-MC-Unique: w3ipt665MoyUZlfjiCVc3g-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 01/21] bridge_driver: fix comment about dnsmasqCaps Date: Mon, 19 Apr 2021 19:14:04 +0200 Message-Id: <93cf95c44abae910dd59ee539cf172a60968d22e.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.84 on 10.5.11.23 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" We will never call dnsmasqCapsRefresh() so reflect what actually happens. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- src/network/bridge_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 1172dbbc18..706a557ee8 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -748,7 +748,7 @@ networkStateInitialize(bool privileged, false, getpid())) < 0) goto error; =20 - /* if this fails now, it will be retried later with dnsmasqCapsRefresh= () */ + /* if this fails now, it will be retried later with networkDnsmasqCaps= Refresh() */ network_driver->dnsmasqCaps =3D dnsmasqCapsNewFromBinary(DNSMASQ); =20 if (!(network_driver->networks =3D virNetworkObjListNew())) --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852486; cv=none; d=zohomail.com; s=zohoarc; b=bhSPkLZnL0iKY5PkTdBeWV4gkGI3/Koubz2202QDvmmvtR+HGl198UCCSgzz2d27EoSpzI/S6W/5W7uz/JhUe+/kIcJXTGBfH6CL6Gw74H3+/5lPmEIJvnbaUxQYrFf1IzAxJg8k6kKy2L9bWWXshN/g7RGJFkKtPJ6j9RKCgXo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852486; 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=TUKHwKK7e/SiegowJeTYhC7bUp0Z002iHvAO9PiP2/o=; b=fWougt5dZuOP4G7ciaob/LkAoyIJn/w10zWlbbUzP07a53qNI+NrALT6lAan1mAiMN9cLG/zcXMuFq/rluEt0MRBzLAhCZymXBMtg1NDTT288jWEgAOPTXC4sWTxheUQwctG8NGJMPmRIQ5VMiHgIJuACqAxGO2Ej7uRSkqsM9o= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852486094201.70968525261674; Mon, 19 Apr 2021 10:14:46 -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-153-exSLvqw9P16m_tto0otH8Q-1; Mon, 19 Apr 2021 13:14:42 -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 61DCF85EE8B; Mon, 19 Apr 2021 17:14:36 +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 4260D60CED; Mon, 19 Apr 2021 17:14:36 +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 C0C0644A57; Mon, 19 Apr 2021 17:14:34 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEVvN021797 for ; Mon, 19 Apr 2021 13:14:31 -0400 Received: by smtp.corp.redhat.com (Postfix) id 333015D742; Mon, 19 Apr 2021 17:14:31 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id A5F1E5D72E for ; Mon, 19 Apr 2021 17:14:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852484; 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=TUKHwKK7e/SiegowJeTYhC7bUp0Z002iHvAO9PiP2/o=; b=Opdf90kYDmmx6lFvhu+fvz2N0fRiZPtJDQBqOAnFJ7jX76895huZcy8GZAkktutz63BWx8 1iDR5QpkgqpyaTE/01yympdxc/yy6AVDNpfLlbaaNdPRKEDR/CW8iDXDNlNJwfsgIWtNXz Lo3Y4Q/MQUGNPMftxP6xVAh8XzmLz80= X-MC-Unique: exSLvqw9P16m_tto0otH8Q-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 02/21] virdnsmasq: drop unused dnsmasqCapsNewFromFile function Date: Mon, 19 Apr 2021 19:14:05 +0200 Message-Id: <845d5249d9031e9368c37fc717cd468a0c1a3bc0.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Instead of removing binaryPath let's drop the function completely as it is not used anywhere. Signed-off-by: Pavel Hrdina --- src/libvirt_private.syms | 1 - src/util/virdnsmasq.c | 30 ------------------------------ src/util/virdnsmasq.h | 2 -- 3 files changed, 33 deletions(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index fe3b443171..d60d15a43e 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -2091,7 +2091,6 @@ dnsmasqCapsGetBinaryPath; dnsmasqCapsGetVersion; dnsmasqCapsNewFromBinary; dnsmasqCapsNewFromBuffer; -dnsmasqCapsNewFromFile; dnsmasqCapsRefresh; dnsmasqContextFree; dnsmasqContextNew; diff --git a/src/util/virdnsmasq.c b/src/util/virdnsmasq.c index 3db718c1d9..57f7ef67f1 100644 --- a/src/util/virdnsmasq.c +++ b/src/util/virdnsmasq.c @@ -673,21 +673,6 @@ dnsmasqCapsSetFromBuffer(dnsmasqCaps *caps, const char= *buf) =20 } =20 -static int -dnsmasqCapsSetFromFile(dnsmasqCaps *caps, const char *path) -{ - int ret =3D -1; - g_autofree char *buf =3D NULL; - - if (virFileReadAll(path, 1024 * 1024, &buf) < 0) - goto cleanup; - - ret =3D dnsmasqCapsSetFromBuffer(caps, buf); - - cleanup: - return ret; -} - static int dnsmasqCapsRefreshInternal(dnsmasqCaps *caps, bool force) { @@ -773,21 +758,6 @@ dnsmasqCapsNewFromBuffer(const char *buf, const char *= binaryPath) return caps; } =20 -dnsmasqCaps * -dnsmasqCapsNewFromFile(const char *dataPath, const char *binaryPath) -{ - dnsmasqCaps *caps =3D dnsmasqCapsNewEmpty(binaryPath); - - if (!caps) - return NULL; - - if (dnsmasqCapsSetFromFile(caps, dataPath) < 0) { - virObjectUnref(caps); - return NULL; - } - return caps; -} - dnsmasqCaps * dnsmasqCapsNewFromBinary(const char *binaryPath) { diff --git a/src/util/virdnsmasq.h b/src/util/virdnsmasq.h index 6cdc619d8f..09e6164dc0 100644 --- a/src/util/virdnsmasq.h +++ b/src/util/virdnsmasq.h @@ -101,8 +101,6 @@ int dnsmasqReload(pid_t pid); =20 dnsmasqCaps *dnsmasqCapsNewFromBuffer(const char *buf, const char *binaryPath); -dnsmasqCaps *dnsmasqCapsNewFromFile(const char *dataPath, - const char *binaryPath); dnsmasqCaps *dnsmasqCapsNewFromBinary(const char *binaryPath); int dnsmasqCapsRefresh(dnsmasqCaps **caps, const char *binaryPath); bool dnsmasqCapsGet(dnsmasqCaps *caps, dnsmasqCapsFlags flag); --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852498; cv=none; d=zohomail.com; s=zohoarc; b=Pg8IrtnYJfnaSmfGne4Bsmw9EWJwMML6/VMijRKh86Laq+zRHTwKfOorVlg3FHTLKUoZaqOF5lLDYS3FaA/dazQSbQRVs+CWULA7P8jJc7LfeQGPgsZYc/8bdnxX2dKMz+3yt19onnVTyJqe7V4A3k5fpp2aqwzJgMaG4sFcuOE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852498; 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=5tcvl//yjTV4tVf47d1wU2NNrjuVt34ROjCspGU9smc=; b=iR01HUn+j/dxZETkW3Led4h/sK/gOLGL6X/WB2xVnwTIh28O8iD99SVtqbIIlo0YUJRuI6DWXn4SI2MWz2IBjChKcf9WnQrY9UvRjiaKP0Rto0+FmcU2Gw+2pAKfsS+K+QvbO01aqkwwLLgAl8QOkK9Vs1FAF/Ic7XyFTroXt2M= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1618852498034405.6570474029604; Mon, 19 Apr 2021 10:14:58 -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-44-dm1dFjk5OSKkZ3ePmc3Jig-1; Mon, 19 Apr 2021 13:14:52 -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 5DC0D18397A3; Mon, 19 Apr 2021 17:14:47 +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 3FAEB614FD; Mon, 19 Apr 2021 17:14:47 +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 0720D44A63; Mon, 19 Apr 2021 17:14:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEWT0021807 for ; Mon, 19 Apr 2021 13:14:32 -0400 Received: by smtp.corp.redhat.com (Postfix) id 1021E5D72E; Mon, 19 Apr 2021 17:14:32 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 85A7D5D743 for ; Mon, 19 Apr 2021 17:14:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852494; 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=5tcvl//yjTV4tVf47d1wU2NNrjuVt34ROjCspGU9smc=; b=JIVGNtQ2m0JnjKOhJMjQW4qmu+7mCVYQALI2gJtohzFTCaaZ2V83aPpFAfcziGfez64tz8 wvkwlbnTneB9BP4SyjHR15xnlf0HAdK6LSDvX7KHeArn+3o4wSx3LjSLdmZ3+fsfvhNy77 jdh3jQzkWbM4MgmCkQe8JFZDcfDrPQQ= X-MC-Unique: dm1dFjk5OSKkZ3ePmc3Jig-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 03/21] virdnsmasq: drop unused dnsmasqCapsRefresh function Date: Mon, 19 Apr 2021 19:14:06 +0200 Message-Id: <7134aa6dada72bfaf0a55f826e07ce36a2e67517.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Instead of removing binaryPath let's drop the function completely as it is not used anywhere. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- src/libvirt_private.syms | 1 - src/util/virdnsmasq.c | 17 ----------------- src/util/virdnsmasq.h | 1 - 3 files changed, 19 deletions(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index d60d15a43e..34e22d37d6 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -2091,7 +2091,6 @@ dnsmasqCapsGetBinaryPath; dnsmasqCapsGetVersion; dnsmasqCapsNewFromBinary; dnsmasqCapsNewFromBuffer; -dnsmasqCapsRefresh; dnsmasqContextFree; dnsmasqContextNew; dnsmasqDelete; diff --git a/src/util/virdnsmasq.c b/src/util/virdnsmasq.c index 57f7ef67f1..89f33c22a8 100644 --- a/src/util/virdnsmasq.c +++ b/src/util/virdnsmasq.c @@ -773,23 +773,6 @@ dnsmasqCapsNewFromBinary(const char *binaryPath) return caps; } =20 -/** dnsmasqCapsRefresh: - * - * Refresh an existing caps object if the binary has changed. If - * there isn't yet a caps object (if it's NULL), create a new one. - * - * Returns 0 on success, -1 on failure - */ -int -dnsmasqCapsRefresh(dnsmasqCaps **caps, const char *binaryPath) -{ - if (!*caps) { - *caps =3D dnsmasqCapsNewFromBinary(binaryPath); - return *caps ? 0 : -1; - } - return dnsmasqCapsRefreshInternal(*caps, false); -} - const char * dnsmasqCapsGetBinaryPath(dnsmasqCaps *caps) { diff --git a/src/util/virdnsmasq.h b/src/util/virdnsmasq.h index 09e6164dc0..8b9474f774 100644 --- a/src/util/virdnsmasq.h +++ b/src/util/virdnsmasq.h @@ -102,7 +102,6 @@ int dnsmasqReload(pid_t pid); dnsmasqCaps *dnsmasqCapsNewFromBuffer(const char *buf, const char *binaryPath); dnsmasqCaps *dnsmasqCapsNewFromBinary(const char *binaryPath); -int dnsmasqCapsRefresh(dnsmasqCaps **caps, const char *binaryPath); bool dnsmasqCapsGet(dnsmasqCaps *caps, dnsmasqCapsFlags flag); const char *dnsmasqCapsGetBinaryPath(dnsmasqCaps *caps); unsigned long dnsmasqCapsGetVersion(dnsmasqCaps *caps); --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852540; cv=none; d=zohomail.com; s=zohoarc; b=g/6WRI0JNgdIdE1O+6TZ1EFVRSNz1UFvLSAxcCD4lqyacnaZ6FFVzzFH278X2hbiDIRsWqJ6wjaU+97uOOAvRE2eOv6s5bYnsahibpC3NIQxt6if1A0/fsTx8tSPqfbLtUVYO5WeTsElTwwQrCDCnVNug0zjWksLa9OqpqdcEWM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852540; 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=vf4Sqd0GN6rY8Exu3uYEeo5SPd0zlPpYYMvgglnQwAw=; b=MCfeAh+6Sc5c+v5Ij6yHJ591hT2Sp9I+PfuWZbzY1JzCZt8cYp85HtQxdUjpdWS2ScO8PwZVw+32kKhRC5lc95CDcMbISBYao6FsPhcpJhsnUu1y7dDCCUIH8dhf9QEchn23PgakplDATqWp0Ti+oqHeiD6vgdSNoS733aWFoBk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852540242409.8986804852725; Mon, 19 Apr 2021 10:15:40 -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-509-SRIIGOaKMXa5fA9_sPYm8A-1; Mon, 19 Apr 2021 13:14:53 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 89811107ACE6; Mon, 19 Apr 2021 17:14:47 +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 6452A10013D7; Mon, 19 Apr 2021 17:14:47 +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 353B31806D1C; Mon, 19 Apr 2021 17:14:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEWoA021815 for ; Mon, 19 Apr 2021 13:14:32 -0400 Received: by smtp.corp.redhat.com (Postfix) id E24485D742; Mon, 19 Apr 2021 17:14:32 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 630AA5D72E for ; Mon, 19 Apr 2021 17:14:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852497; 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=vf4Sqd0GN6rY8Exu3uYEeo5SPd0zlPpYYMvgglnQwAw=; b=bKSN0tZEdpuwpk4r+TThcxPcIi1Hocmi+hBVJpTcVJKcCSDvVZG8LSKo8FDZFoiJREcpYY i7JOo0ckcdo25UT62v83Laj4oC7hxbOFKik8WJF7FSqLD+DegWvvAzNoc2GA2N0bdC+C03 3fYgz7U/pc0RgDxWFO08V6abRGWXNnw= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852538; 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=vf4Sqd0GN6rY8Exu3uYEeo5SPd0zlPpYYMvgglnQwAw=; b=JMVkMfCdNBLBgPprhjuZ9v+8W7OQJ/l3nK7UHQQai15xUU+qPn/HL64tMmmIXjGXlu8JuF hPHVH6XjjnwZM5IBGlgIfK5zFDC6Q9OQHmwVXlfAqv46XEG7/ZHDeOvSmQzCENE9oNRv5Z wmJUUj3Bi/s+y7y3dEO56I7Id+8xV6Q= X-MC-Unique: SRIIGOaKMXa5fA9_sPYm8A-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 04/21] virdnsmasq: remove binaryPath argument from dnsmasqCapsNewFromBuffer Date: Mon, 19 Apr 2021 19:14:07 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) (identity @redhat.com) Content-Type: text/plain; charset="utf-8" We always pass DNSMASQ so there is no need for the argument at all. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- src/util/virdnsmasq.c | 4 ++-- src/util/virdnsmasq.h | 3 +-- tests/networkxml2conftest.c | 6 +++--- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/util/virdnsmasq.c b/src/util/virdnsmasq.c index 89f33c22a8..82a26e83e9 100644 --- a/src/util/virdnsmasq.c +++ b/src/util/virdnsmasq.c @@ -744,9 +744,9 @@ dnsmasqCapsNewEmpty(const char *binaryPath) } =20 dnsmasqCaps * -dnsmasqCapsNewFromBuffer(const char *buf, const char *binaryPath) +dnsmasqCapsNewFromBuffer(const char *buf) { - dnsmasqCaps *caps =3D dnsmasqCapsNewEmpty(binaryPath); + dnsmasqCaps *caps =3D dnsmasqCapsNewEmpty(DNSMASQ); =20 if (!caps) return NULL; diff --git a/src/util/virdnsmasq.h b/src/util/virdnsmasq.h index 8b9474f774..cf6d50fe38 100644 --- a/src/util/virdnsmasq.h +++ b/src/util/virdnsmasq.h @@ -99,8 +99,7 @@ int dnsmasqSave(const dnsmasqContext *ctx); int dnsmasqDelete(const dnsmasqContext *ctx); int dnsmasqReload(pid_t pid); =20 -dnsmasqCaps *dnsmasqCapsNewFromBuffer(const char *buf, - const char *binaryPath); +dnsmasqCaps *dnsmasqCapsNewFromBuffer(const char *buf); dnsmasqCaps *dnsmasqCapsNewFromBinary(const char *binaryPath); bool dnsmasqCapsGet(dnsmasqCaps *caps, dnsmasqCapsFlags flag); const char *dnsmasqCapsGetBinaryPath(dnsmasqCaps *caps); diff --git a/tests/networkxml2conftest.c b/tests/networkxml2conftest.c index 402244ea4a..7444390b77 100644 --- a/tests/networkxml2conftest.c +++ b/tests/networkxml2conftest.c @@ -123,11 +123,11 @@ mymain(void) { int ret =3D 0; dnsmasqCaps *restricted - =3D dnsmasqCapsNewFromBuffer("Dnsmasq version 2.48", DNSMASQ); + =3D dnsmasqCapsNewFromBuffer("Dnsmasq version 2.48"); dnsmasqCaps *full - =3D dnsmasqCapsNewFromBuffer("Dnsmasq version 2.63\n--bind-dynamic= ", DNSMASQ); + =3D dnsmasqCapsNewFromBuffer("Dnsmasq version 2.63\n--bind-dynamic= "); dnsmasqCaps *dhcpv6 - =3D dnsmasqCapsNewFromBuffer("Dnsmasq version 2.64\n--bind-dynamic= ", DNSMASQ); + =3D dnsmasqCapsNewFromBuffer("Dnsmasq version 2.64\n--bind-dynamic= "); =20 #define DO_TEST(xname, xcaps) \ do { \ --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) client-ip=63.128.21.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 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=1618852593; cv=none; d=zohomail.com; s=zohoarc; b=PRoZCMSzNVii0tNibL8uGHmeNmMVn+s18kcKfUm+3CTpLMvoyRwTg+OEMQjjB+UCh7JNlrQccvjnuv6OVJrGu9Y+7TdB3/l0Wm6OB40qxr8gD/W/VlKOjdrl96OxmJaKUHx/BF248usam+VzPZBd8FwpJgZpX2mF4+4TQRoRaeA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852593; 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=FlFbMWBcLapYZo2im8O+ASlZX+bxXCEIJwk1DPSJZnY=; b=VM1z6qnxFEM+zqKOtJrzNDqZ0KqfxdhVdyenJN0cbbR5PT2ZzOMLx6XTgh0vMJW5UfZMAo2JnVOhmd6ZhZ7gTNLV6JKgRaG7YGFp8MJwpy7IbwsjelErWJRM56yxL2RdHJvb0NFnZsZQt96/3JlLPGNcD9HKYm+HVNUNPXQBWLE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.zohomail.com with SMTPS id 1618852593729405.96083771674455; Mon, 19 Apr 2021 10:16:33 -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-564-nd-zdpmRNLG-_uPW0z151Q-1; Mon, 19 Apr 2021 13:14:56 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 5D9011006C90; Mon, 19 Apr 2021 17:14:50 +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 3BEA15D9F0; Mon, 19 Apr 2021 17:14:50 +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 0106E44A65; Mon, 19 Apr 2021 17:14:49 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEXQo021823 for ; Mon, 19 Apr 2021 13:14:33 -0400 Received: by smtp.corp.redhat.com (Postfix) id BFF155D72E; Mon, 19 Apr 2021 17:14:33 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4058D5D742 for ; Mon, 19 Apr 2021 17:14:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852591; 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=FlFbMWBcLapYZo2im8O+ASlZX+bxXCEIJwk1DPSJZnY=; b=dHoNhaG8qpjoo5v6kWHhvzJykN05qHA84zB/+b6dzAe9eByw2lQHBT3kiVMiwtQT7Kdse3 A5kyonjdJ/h30tJF0kH/FntxohES/8SUnhVZnUarA1YTmX7/MXkw9UJ2G58vaZ1FBToDEP hf5FiKXZ5JrBvAKCgJYcoXOtvB597MQ= X-MC-Unique: nd-zdpmRNLG-_uPW0z151Q-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 05/21] virdnsmasq: remove binaryPath argument from dnsmasqCapsNewFromBinary Date: Mon, 19 Apr 2021 19:14:08 +0200 Message-Id: <9dd507758e684da71a3090a4d5cb555f026acafd.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.14 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" We always pass DNSMASQ so there is no need for the argument at all. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- src/network/bridge_driver.c | 4 ++-- src/util/virdnsmasq.c | 4 ++-- src/util/virdnsmasq.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 706a557ee8..ee3f9dab0a 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -130,7 +130,7 @@ networkDnsmasqCapsRefresh(virNetworkDriverState *driver) { dnsmasqCaps *caps; =20 - if (!(caps =3D dnsmasqCapsNewFromBinary(DNSMASQ))) + if (!(caps =3D dnsmasqCapsNewFromBinary())) return -1; =20 networkDriverLock(driver); @@ -749,7 +749,7 @@ networkStateInitialize(bool privileged, goto error; =20 /* if this fails now, it will be retried later with networkDnsmasqCaps= Refresh() */ - network_driver->dnsmasqCaps =3D dnsmasqCapsNewFromBinary(DNSMASQ); + network_driver->dnsmasqCaps =3D dnsmasqCapsNewFromBinary(); =20 if (!(network_driver->networks =3D virNetworkObjListNew())) goto error; diff --git a/src/util/virdnsmasq.c b/src/util/virdnsmasq.c index 82a26e83e9..f2f606913f 100644 --- a/src/util/virdnsmasq.c +++ b/src/util/virdnsmasq.c @@ -759,9 +759,9 @@ dnsmasqCapsNewFromBuffer(const char *buf) } =20 dnsmasqCaps * -dnsmasqCapsNewFromBinary(const char *binaryPath) +dnsmasqCapsNewFromBinary(void) { - dnsmasqCaps *caps =3D dnsmasqCapsNewEmpty(binaryPath); + dnsmasqCaps *caps =3D dnsmasqCapsNewEmpty(DNSMASQ); =20 if (!caps) return NULL; diff --git a/src/util/virdnsmasq.h b/src/util/virdnsmasq.h index cf6d50fe38..ee9839cd25 100644 --- a/src/util/virdnsmasq.h +++ b/src/util/virdnsmasq.h @@ -100,7 +100,7 @@ int dnsmasqDelete(const dnsmasqContext *ct= x); int dnsmasqReload(pid_t pid); =20 dnsmasqCaps *dnsmasqCapsNewFromBuffer(const char *buf); -dnsmasqCaps *dnsmasqCapsNewFromBinary(const char *binaryPath); +dnsmasqCaps *dnsmasqCapsNewFromBinary(void); bool dnsmasqCapsGet(dnsmasqCaps *caps, dnsmasqCapsFlags flag); const char *dnsmasqCapsGetBinaryPath(dnsmasqCaps *caps); unsigned long dnsmasqCapsGetVersion(dnsmasqCaps *caps); --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852497; cv=none; d=zohomail.com; s=zohoarc; b=WsGv7PPIoS4a8TicpQ26rQQS796fmvtj10hesJ/Gv9ZFTHNK5EdZXzfUneOaZNr6GPlMZJeRklonc++FUeTH+bix45YAiCprXKYb2qJIxKEa2xZz9F4aNlbvhiXOx0MDs220zJ2Q31C862OCGeEZAQy+7KYeoWm6/prQSO0YgSY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852497; 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=TL2VLIOawBDLyAIBDvw8qA5h6AHwFPubOVd7hSe43eQ=; b=DM5zfbPwMa6iOdr8A9wvuZqGjNG9Mb70mchYgc5jfVnfF1lW9xoKy/cYLzbkB7vMqtVzDGP7MYLMziM3ekKgavut5d7KCu2UgZ1wh9bSpdmV4AusRhWBiEN8eANOQZUsVVvleAL/E1zjitcdUR5EcB1Coz6yfT1165LDemtK6eM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1618852497757747.3181128545976; Mon, 19 Apr 2021 10:14:57 -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-152-IcuafgqQPJq_3n-i-2pPTA-1; Mon, 19 Apr 2021 13:14:52 -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 5BC206D582; Mon, 19 Apr 2021 17:14:47 +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 3D76760CED; Mon, 19 Apr 2021 17:14:47 +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 065661806D1B; Mon, 19 Apr 2021 17:14:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEYMP021836 for ; Mon, 19 Apr 2021 13:14:34 -0400 Received: by smtp.corp.redhat.com (Postfix) id 9E3A15D742; Mon, 19 Apr 2021 17:14:34 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1E5595D72E for ; Mon, 19 Apr 2021 17:14:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852494; 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=TL2VLIOawBDLyAIBDvw8qA5h6AHwFPubOVd7hSe43eQ=; b=MAenkQZwj3gGOZzMeGBIaQz1j2/K4JMyqIXyJkDGoUqqz/SZYYX935wtSAcSDiLjPM3Z01 mCO99wSu6FpRITKN6cmOflvrD0A/11U0aMNRkPvmqNPxhfKbS8N7hef84usvKgjVa3sCni 541ekC2AnxI80FT3yumvj6NE2mN8lJw= X-MC-Unique: IcuafgqQPJq_3n-i-2pPTA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 06/21] virfirewall: use virFindFileInPath instead of virFileIsExecutable Date: Mon, 19 Apr 2021 19:14:09 +0200 Message-Id: <8b9387c6d96b0b3d81abb5bd335808a9b632528b.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Following patches will make this change necessary as we will stop detecting the full path during compile time. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- src/util/virfirewall.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/util/virfirewall.c b/src/util/virfirewall.c index 78aa7e580e..e79fe52ac8 100644 --- a/src/util/virfirewall.c +++ b/src/util/virfirewall.c @@ -104,7 +104,9 @@ virFirewallValidateBackend(virFirewallBackend backend) size_t i; =20 for (i =3D 0; i < G_N_ELEMENTS(commands); i++) { - if (!virFileIsExecutable(commands[i])) { + g_autofree char *path =3D virFindFileInPath(commands[i]); + + if (!path) { virReportSystemError(errno, _("%s not available, firewall backend wil= l not function"), commands[i]); --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852500; cv=none; d=zohomail.com; s=zohoarc; b=CyZJuf2SieP9PRGreqVOb5AM6oSKo/ExJ1aum3fP/k+HqbSNCCj5/qM9sSfN9tEV8hU9BphJxh53kR5g5kbb65KbBY1wjHhXNmfO8JG9hPUX6KEs9nUA81Mr4BCGcpCePG6pEv/wuOohmgFC0xJo+elMNl7iLWvxHM+AlWtv/fw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852500; 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=fBpwqYsKGF9Ojt8HsQiK1Tv269dPokUT1WXpImitSb4=; b=nahvrTZwQhvvyXz9+ySvsB1urTqJaWndczFT4TdcohfHI7vpJkWRxypJLDgx02vEGvgmM66usyEl/Jb+GSCQoFk0qDNUo27g+5+IXjNue4VkqHxqGI8EW00dvkE+lnbEL+iDSyl/dyXa84PoKlaJ0555CcgGabGkRH04IehHd28= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852500458471.2316684101029; Mon, 19 Apr 2021 10:15: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-161-f4EIyvV1OE6_TSFOK0-RkA-1; Mon, 19 Apr 2021 13:14:56 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 132551006C8E; Mon, 19 Apr 2021 17:14:50 +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 E23B35C23E; Mon, 19 Apr 2021 17:14:49 +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 AE9661806D1A; Mon, 19 Apr 2021 17:14:49 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEZKI021849 for ; Mon, 19 Apr 2021 13:14:35 -0400 Received: by smtp.corp.redhat.com (Postfix) id 7ACD45D742; Mon, 19 Apr 2021 17:14:35 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id F01C35D72E for ; Mon, 19 Apr 2021 17:14:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852499; 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=fBpwqYsKGF9Ojt8HsQiK1Tv269dPokUT1WXpImitSb4=; b=NrF2KA8HHxcXDj2XW7ba2ubwFpMDVUJX/cmzmQ24btCytiSyS6oUFxhbpYg0XO+AGCV17y XMAp26/BQX3aDq/PGQEjFmfLijND60zIVzSBTgHmj5m6OLMSRgxcaF8kmskYpeBiqLU/AA UjjjEO+wZb776+cGrvyScHSDnutexOc= X-MC-Unique: f4EIyvV1OE6_TSFOK0-RkA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 07/21] tests: introduce virfirewallmock Date: Mon, 19 Apr 2021 19:14:10 +0200 Message-Id: <6754d49101604b16176b2cce45745082e13d7a1a.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" This will allow us to run tests using firewall on hosts where the mocked binaries are not available/installed instead of skipping these tests. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- src/util/virfile.h | 3 ++- tests/meson.build | 1 + tests/virfirewallmock.c | 34 ++++++++++++++++++++++++++++++++++ 3 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 tests/virfirewallmock.c diff --git a/src/util/virfile.h b/src/util/virfile.h index a02779f0ec..b9f7b1766f 100644 --- a/src/util/virfile.h +++ b/src/util/virfile.h @@ -184,7 +184,8 @@ int virFileResolveAllLinks(const char *linkpath, int virFileIsLink(const char *linkpath) ATTRIBUTE_NONNULL(1) G_GNUC_WARN_UNUSED_RESULT; =20 -char *virFindFileInPath(const char *file); +char *virFindFileInPath(const char *file) + G_GNUC_NO_INLINE; =20 char *virFileFindResource(const char *filename, const char *builddir, diff --git a/tests/meson.build b/tests/meson.build index 3f66861332..05c3e90195 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -60,6 +60,7 @@ mock_libs =3D [ { 'name': 'shunload', 'sources': [ 'shunloadhelper.c' ] }, { 'name': 'vircgroupmock' }, { 'name': 'virfilecachemock' }, + { 'name': 'virfirewallmock' }, { 'name': 'virgdbusmock' }, { 'name': 'virhostcpumock' }, { 'name': 'virhostdevmock' }, diff --git a/tests/virfirewallmock.c b/tests/virfirewallmock.c new file mode 100644 index 0000000000..6b096701c9 --- /dev/null +++ b/tests/virfirewallmock.c @@ -0,0 +1,34 @@ +/* + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library. If not, see + * . + */ + +#include + +#include "internal.h" +#include "virfile.h" + +char * +virFindFileInPath(const char *file) +{ + if (file && + (g_strrstr(file, "ebtables") || + g_strrstr(file, "iptables") || + g_strrstr(file, "ip6tables"))) { + return g_strdup(file); + } + + /* We should not need any other binaries so return NULL. */ + return NULL; +} --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852582; cv=none; d=zohomail.com; s=zohoarc; b=eF/OOJH5h4YSq3vbTH5nkNEA8Z3vNgu1GvMKWKFw84GvmQgbCkMi6SJRD17bYGbKr2LAXEgoB4fFD3aCmWtR5bYdN5gN3LKe1dKF8qYuksOjmHT2EdP6MTn4GelbmbWof06GVBEXgoc4hmKntdFA+gLaIjTOd4hMs0RwiiRT19g= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852582; 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=IPoNNhEP/15r6R+H7A8loHF6wtj/hNd1taoFlSQtMDo=; b=klKWj3BwXMiNN+tbsvwS177nuh0gOIBM2VPQqEUUrUQ/uEsWMhVNSVy1E3eLSBEKO2kTh6mQJpS2RdOCwaR3ZPUc/svRizirqnaxJB2mbaQDiIJJHOIFcTVKopdN5Gaj7iZnhzEOXXL6tvhGUSkTXqiltJfvMhk/D/fhUlj7gH4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1618852582155385.28951587794506; Mon, 19 Apr 2021 10:16:22 -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-224-TfNcKHNvNGehvEHhKWv9uA-1; Mon, 19 Apr 2021 13:14:57 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 5BC9C107ACF8; Mon, 19 Apr 2021 17:14:50 +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 35C5810013D7; Mon, 19 Apr 2021 17:14:50 +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 01BE91806D20; Mon, 19 Apr 2021 17:14:50 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEd8b021864 for ; Mon, 19 Apr 2021 13:14:39 -0400 Received: by smtp.corp.redhat.com (Postfix) id 058E55D742; Mon, 19 Apr 2021 17:14:39 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 77F5D5D72E for ; Mon, 19 Apr 2021 17:14:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852579; 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=IPoNNhEP/15r6R+H7A8loHF6wtj/hNd1taoFlSQtMDo=; b=RxF19CfSxDDLj/hk+erQPvETy4CZTnYaY7TCf0b5ce8u4mC2c2CkXgHFjKbcRly2QBjcNn Duw8LFSHRIMpsQk07WBW/mka9xQVTLueNZLWT2WBhvptDQM++rcLjPBFYC1Azdt9A97Wvd 7eKZ+rq0qXlpk4UYAv5hzdIyO23AsOQ= X-MC-Unique: TfNcKHNvNGehvEHhKWv9uA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 08/21] tests: use virfirewallmock instead of hasNetfilterTools Date: Mon, 19 Apr 2021 19:14:11 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Instead of checking for specific error that the binaries are not available mock the virFindFileInPath function. This way we don't have to skip these tests on host where the binaries are missing. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- tests/networkxml2firewalltest.c | 16 ++-------------- tests/nwfilterebiptablestest.c | 15 +-------------- tests/nwfilterxml2firewalltest.c | 14 +------------- tests/virfirewalltest.c | 15 ++------------- 4 files changed, 6 insertions(+), 54 deletions(-) diff --git a/tests/networkxml2firewalltest.c b/tests/networkxml2firewalltes= t.c index 80ba510d14..91336a0c55 100644 --- a/tests/networkxml2firewalltest.c +++ b/tests/networkxml2firewalltest.c @@ -152,14 +152,6 @@ testCompareXMLToIPTablesHelper(const void *data) return result; } =20 -static bool -hasNetfilterTools(void) -{ - return virFileIsExecutable(IPTABLES_PATH) && - virFileIsExecutable(IP6TABLES_PATH) && - virFileIsExecutable(EBTABLES_PATH); -} - =20 static int mymain(void) @@ -179,11 +171,6 @@ mymain(void) } while (0) =20 if (virFirewallSetBackend(VIR_FIREWALL_BACKEND_DIRECT) < 0) { - if (!hasNetfilterTools()) { - fprintf(stderr, "iptables/ip6tables/ebtables tools not present= "); - return EXIT_AM_SKIP; - } - return EXIT_FAILURE; } =20 @@ -203,7 +190,8 @@ mymain(void) return ret =3D=3D 0 ? EXIT_SUCCESS : EXIT_FAILURE; } =20 -VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virgdbus")) +VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virgdbus"), + VIR_TEST_MOCK("virfirewall")) =20 #else /* ! defined (__linux__) */ =20 diff --git a/tests/nwfilterebiptablestest.c b/tests/nwfilterebiptablestest.c index 5f504cbe64..65b63959fb 100644 --- a/tests/nwfilterebiptablestest.c +++ b/tests/nwfilterebiptablestest.c @@ -482,14 +482,6 @@ testNWFilterEBIPTablesApplyDropAllRules(const void *op= aque G_GNUC_UNUSED) return ret; } =20 -static bool -hasNetfilterTools(void) -{ - return virFileIsExecutable(IPTABLES_PATH) && - virFileIsExecutable(IP6TABLES_PATH) && - virFileIsExecutable(EBTABLES_PATH); -} - =20 static int mymain(void) @@ -497,11 +489,6 @@ mymain(void) int ret =3D 0; =20 if (virFirewallSetBackend(VIR_FIREWALL_BACKEND_DIRECT) < 0) { - if (!hasNetfilterTools()) { - fprintf(stderr, "iptables/ip6tables/ebtables tools not present= "); - return EXIT_AM_SKIP; - } - return EXIT_FAILURE; } =20 @@ -543,4 +530,4 @@ mymain(void) return ret =3D=3D 0 ? EXIT_SUCCESS : EXIT_FAILURE; } =20 -VIR_TEST_MAIN(mymain) +VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virfirewall")) diff --git a/tests/nwfilterxml2firewalltest.c b/tests/nwfilterxml2firewallt= est.c index 560372b802..6709cc15fd 100644 --- a/tests/nwfilterxml2firewalltest.c +++ b/tests/nwfilterxml2firewalltest.c @@ -431,14 +431,6 @@ testCompareXMLToIPTablesHelper(const void *data) return result; } =20 -static bool -hasNetfilterTools(void) -{ - return virFileIsExecutable(IPTABLES_PATH) && - virFileIsExecutable(IP6TABLES_PATH) && - virFileIsExecutable(EBTABLES_PATH); -} - =20 static int mymain(void) @@ -456,10 +448,6 @@ mymain(void) } while (0) =20 if (virFirewallSetBackend(VIR_FIREWALL_BACKEND_DIRECT) < 0) { - if (!hasNetfilterTools()) { - fprintf(stderr, "iptables/ip6tables/ebtables tools not present= "); - return EXIT_AM_SKIP; - } return EXIT_FAILURE; } =20 @@ -506,7 +494,7 @@ mymain(void) return ret =3D=3D 0 ? EXIT_SUCCESS : EXIT_FAILURE; } =20 -VIR_TEST_MAIN(mymain) +VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virfirewall")) =20 #else /* ! defined (__linux__) */ =20 diff --git a/tests/virfirewalltest.c b/tests/virfirewalltest.c index 8e65fa8524..ac039f3bbf 100644 --- a/tests/virfirewalltest.c +++ b/tests/virfirewalltest.c @@ -1034,24 +1034,12 @@ testFirewallQuery(const void *opaque G_GNUC_UNUSED) return ret; } =20 -static bool -hasNetfilterTools(void) -{ - return virFileIsExecutable(IPTABLES_PATH) && - virFileIsExecutable(IP6TABLES_PATH) && - virFileIsExecutable(EBTABLES_PATH); -} =20 static int mymain(void) { int ret =3D 0; =20 - if (!hasNetfilterTools()) { - fprintf(stderr, "iptables/ip6tables/ebtables tools not present"); - return EXIT_AM_SKIP; - } - # define RUN_TEST_DIRECT(name, method) \ do { \ struct testFirewallData data; \ @@ -1100,7 +1088,8 @@ mymain(void) return ret =3D=3D 0 ? EXIT_SUCCESS : EXIT_FAILURE; } =20 -VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virgdbus")) +VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virgdbus"), + VIR_TEST_MOCK("virfirewall")) =20 #else /* ! defined (__linux__) */ =20 --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852503; cv=none; d=zohomail.com; s=zohoarc; b=c1lgHuD2HywsoC8aCeDgZSE/VU7N9LdiJXvaCi010aAPEoAW3ZPIG0bgxKAzIe0YDCG3ZpnqK1q5vf+nHl5Q56cqxSwykT17eUIwDP+WwKQ150B39tdZEq7Q2lTzcQOJj/tMzWWk1eoTUuPtL477g92gGfj1eIweVdS+7XM+F14= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852503; 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=QF4/ZN357WGLdf8c6scs139VHEACCykfTzhifz9vgqc=; b=DE6q0MhePYkRMgkXAqf2geZ9SWqLm/RQ714ubRPDT0njQCw8eneKiftXhmcZcggaEXyJOqYvoD08RLCxEAQPQh5yNTqXuJF1G2lQfTL/jh3UBLcKkcBc20CoYHYhwv6GPLCMKcVizH+8+a/PAxOxVZzB2W/9izoTsnnPXeCAyAI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852503800426.6518551111443; Mon, 19 Apr 2021 10:15:03 -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-15-OxnpVZSaNhqsap0fRSzc0g-1; Mon, 19 Apr 2021 13:14:58 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 90E4C180486D; Mon, 19 Apr 2021 17:14:52 +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 6750E1000358; Mon, 19 Apr 2021 17:14:52 +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 2FDC944A67; Mon, 19 Apr 2021 17:14:52 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEdj5021875 for ; Mon, 19 Apr 2021 13:14:39 -0400 Received: by smtp.corp.redhat.com (Postfix) id D8A965D742; Mon, 19 Apr 2021 17:14:39 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 57EEC5D72E for ; Mon, 19 Apr 2021 17:14:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852502; 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=QF4/ZN357WGLdf8c6scs139VHEACCykfTzhifz9vgqc=; b=Z2GeECriNIQe9naz5rdSoS9e4K/lkVnEseCz1ZmGEDQ/ELgI6xAY0ZMShjYd9Ot60VyuVn 7UMnJTjkcbDM0HESmZsNp5+d30zY/dwYBQnZ315ktNN4DTDA6YvQ1Ut7OYH4oQozw+gRHN p8opja+LDRk2bb2BnuHaYMshta7eMsQ= X-MC-Unique: OxnpVZSaNhqsap0fRSzc0g-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 09/21] virnetdev: move virNetDevSetRootQDisc to virnetdevbandwidth Date: Mon, 19 Apr 2021 19:14:12 +0200 Message-Id: <727b58869631d57f1332ea96db0bd94f3069be7c.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" The function in question uses "tc" binary so virnetdevbandwidth feels like better place for it. Signed-off-by: Pavel Hrdina --- src/libvirt_private.syms | 2 +- src/qemu/qemu_domain.c | 3 ++- src/util/virnetdev.c | 46 -------------------------------- src/util/virnetdev.h | 4 --- src/util/virnetdevbandwidth.c | 50 +++++++++++++++++++++++++++++++++++ src/util/virnetdevbandwidth.h | 4 +++ tests/qemuxml2argvmock.c | 5 ++-- 7 files changed, 60 insertions(+), 54 deletions(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index 34e22d37d6..abd3dc4bd1 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -2714,7 +2714,6 @@ virNetDevSetOnline; virNetDevSetPromiscuous; virNetDevSetRcvAllMulti; virNetDevSetRcvMulti; -virNetDevSetRootQDisc; virNetDevSetupControl; virNetDevSysfsFile; virNetDevValidateConfig; @@ -2728,6 +2727,7 @@ virNetDevBandwidthEqual; virNetDevBandwidthFree; virNetDevBandwidthPlug; virNetDevBandwidthSet; +virNetDevBandwidthSetRootQDisc; virNetDevBandwidthUnplug; virNetDevBandwidthUpdateFilter; virNetDevBandwidthUpdateRate; diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index 2c8ea39840..6e3e3555c7 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -50,6 +50,7 @@ #include "domain_event.h" #include "domain_validate.h" #include "virtime.h" +#include "virnetdevbandwidth.h" #include "virnetdevopenvswitch.h" #include "virstoragefile.h" #include "storage_source.h" @@ -11571,7 +11572,7 @@ qemuDomainInterfaceSetDefaultQDisc(virQEMUDriver *d= river, actualType =3D=3D VIR_DOMAIN_NET_TYPE_NETWORK || actualType =3D=3D VIR_DOMAIN_NET_TYPE_BRIDGE || actualType =3D=3D VIR_DOMAIN_NET_TYPE_DIRECT) { - if (virNetDevSetRootQDisc(net->ifname, "noqueue") < 0) + if (virNetDevBandwidthSetRootQDisc(net->ifname, "noqueue") < 0) return -1; } =20 diff --git a/src/util/virnetdev.c b/src/util/virnetdev.c index 86abdc2e5b..1870f3f875 100644 --- a/src/util/virnetdev.c +++ b/src/util/virnetdev.c @@ -3507,52 +3507,6 @@ virNetDevRunEthernetScript(const char *ifname, const= char *script) } =20 =20 -/** - * virNetDevSetRootQDisc: - * @ifname: the interface name - * @qdisc: queueing discipline to set - * - * For given interface @ifname set its root queueing discipline - * to @qdisc. This can be used to replace the default qdisc - * (usually pfifo_fast or whatever is set in - * /proc/sys/net/core/default_qdisc) with different qdisc. - * - * Returns: 0 on success, - * -1 if failed to exec tc (with error reported) - * -2 if tc failed (with no error reported) - */ -int -virNetDevSetRootQDisc(const char *ifname, - const char *qdisc) -{ - g_autoptr(virCommand) cmd =3D NULL; - g_autofree char *outbuf =3D NULL; - g_autofree char *errbuf =3D NULL; - int status; - - /* Ideally, we would have a netlink implementation and just - * call it here. But honestly, I tried and failed miserably. - * Fallback to spawning tc. */ - cmd =3D virCommandNewArgList(TC, "qdisc", "add", "dev", ifname, - "root", "handle", "0:", qdisc, - NULL); - - virCommandAddEnvString(cmd, "LC_ALL=3DC"); - virCommandSetOutputBuffer(cmd, &outbuf); - virCommandSetErrorBuffer(cmd, &errbuf); - - if (virCommandRun(cmd, &status) < 0) - return -1; - - if (status !=3D 0) { - VIR_DEBUG("Setting qdisc failed: output=3D'%s' err=3D'%s'", outbuf= , errbuf); - return -2; - } - - return 0; -} - - /** * virNetDevReserveName: * @name: name of an existing network device diff --git a/src/util/virnetdev.h b/src/util/virnetdev.h index 1f03d88293..b694f4ac35 100644 --- a/src/util/virnetdev.h +++ b/src/util/virnetdev.h @@ -333,10 +333,6 @@ int virNetDevSysfsFile(char **pf_sysfs_device_link, int virNetDevRunEthernetScript(const char *ifname, const char *script) G_GNUC_NO_INLINE; =20 -int virNetDevSetRootQDisc(const char *ifname, - const char *qdisc) - G_GNUC_NO_INLINE; - int virNetDevVFInterfaceStats(virPCIDeviceAddress *vfAddr, virDomainInterfaceStatsPtr stats) ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2); diff --git a/src/util/virnetdevbandwidth.c b/src/util/virnetdevbandwidth.c index 0fc802b174..75fc5607ad 100644 --- a/src/util/virnetdevbandwidth.c +++ b/src/util/virnetdevbandwidth.c @@ -23,11 +23,14 @@ #include "vircommand.h" #include "viralloc.h" #include "virerror.h" +#include "virlog.h" #include "virstring.h" #include "virutil.h" =20 #define VIR_FROM_THIS VIR_FROM_NONE =20 +VIR_LOG_INIT("util.netdevbandwidth"); + void virNetDevBandwidthFree(virNetDevBandwidth *def) { @@ -749,3 +752,50 @@ virNetDevBandwidthUpdateFilter(const char *ifname, VIR_FREE(class_id); return ret; } + + + +/** + * virNetDevBandwidthSetRootQDisc: + * @ifname: the interface name + * @qdisc: queueing discipline to set + * + * For given interface @ifname set its root queueing discipline + * to @qdisc. This can be used to replace the default qdisc + * (usually pfifo_fast or whatever is set in + * /proc/sys/net/core/default_qdisc) with different qdisc. + * + * Returns: 0 on success, + * -1 if failed to exec tc (with error reported) + * -2 if tc failed (with no error reported) + */ +int +virNetDevBandwidthSetRootQDisc(const char *ifname, + const char *qdisc) +{ + g_autoptr(virCommand) cmd =3D NULL; + g_autofree char *outbuf =3D NULL; + g_autofree char *errbuf =3D NULL; + int status; + + /* Ideally, we would have a netlink implementation and just + * call it here. But honestly, I tried and failed miserably. + * Fallback to spawning tc. */ + cmd =3D virCommandNewArgList(TC, "qdisc", "add", "dev", ifname, + "root", "handle", "0:", qdisc, + NULL); + + virCommandAddEnvString(cmd, "LC_ALL=3DC"); + virCommandSetOutputBuffer(cmd, &outbuf); + virCommandSetErrorBuffer(cmd, &errbuf); + + if (virCommandRun(cmd, &status) < 0) + return -1; + + if (status !=3D 0) { + VIR_DEBUG("Setting qdisc failed: output=3D'%s' err=3D'%s'", outbuf= , errbuf); + return -2; + } + + return 0; +} diff --git a/src/util/virnetdevbandwidth.h b/src/util/virnetdevbandwidth.h index 35e26b66f7..3d520721f6 100644 --- a/src/util/virnetdevbandwidth.h +++ b/src/util/virnetdevbandwidth.h @@ -74,3 +74,7 @@ int virNetDevBandwidthUpdateFilter(const char *ifname, unsigned int id) ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) G_GNUC_WARN_UNUSED_RESULT; + +int virNetDevBandwidthSetRootQDisc(const char *ifname, + const char *qdisc) + G_GNUC_NO_INLINE; diff --git a/tests/qemuxml2argvmock.c b/tests/qemuxml2argvmock.c index 9d812bfc2e..77a0814c08 100644 --- a/tests/qemuxml2argvmock.c +++ b/tests/qemuxml2argvmock.c @@ -25,6 +25,7 @@ #include "virmock.h" #include "virlog.h" #include "virnetdev.h" +#include "virnetdevbandwidth.h" #include "virnetdevip.h" #include "virnetdevtap.h" #include "virnetdevopenvswitch.h" @@ -277,8 +278,8 @@ qemuBuildTPMOpenBackendFDs(const char *tpmdev G_GNUC_UN= USED, =20 =20 int -virNetDevSetRootQDisc(const char *ifname G_GNUC_UNUSED, - const char *qdisc G_GNUC_UNUSED) +virNetDevBandwidthSetRootQDisc(const char *ifname G_GNUC_UNUSED, + const char *qdisc G_GNUC_UNUSED) { return 0; } --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852510; cv=none; d=zohomail.com; s=zohoarc; b=OqkuG9eMbaQYu5HzzNCRJDaOYLdB9hFzpDLAMV4fv/aLKxOKdbNvK1D3V0YFcSbTIEQf+1LNd+yGRQsSkfuEqkf/V63MchihrSdwsZTdNnFcYwHKROAzHugxIh8VnWI465Xf7o0H0yDR3Li+IMQdy/AUnqe7J04SPQME/AVclhs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852510; 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=CvY1NnKZD8VFSOZmyZhz/IWnWSALndoatX63JpQLE4M=; b=Vc3jMW8jPJhMd/dKH7sBzIgBnxtKwV+9gKOyz/Rgp++ksgjXCfiD6lAQe/Lr6urlD7o7tPWQw/xDBlJTnHvfYHAjchqzmfgMVMjdpQn5Rv2dPFoF8gE/X2rXced9xCGK5G/sWJiKyh+q2hLVHC/uChBoROd3BQQ51Vkg+ZZHv8I= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 16188525104801.9530430295096721; Mon, 19 Apr 2021 10:15:10 -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-159-sMXayfNNPTy8_u9tnEwPGg-1; Mon, 19 Apr 2021 13:15:01 -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 74E008030CA; Mon, 19 Apr 2021 17:14:55 +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 56FC5614ED; Mon, 19 Apr 2021 17:14:55 +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 0F5D71806D28; Mon, 19 Apr 2021 17:14:55 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEeY9021883 for ; Mon, 19 Apr 2021 13:14:40 -0400 Received: by smtp.corp.redhat.com (Postfix) id B56005D742; Mon, 19 Apr 2021 17:14:40 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 35D1C5D72E for ; Mon, 19 Apr 2021 17:14:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852507; 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=CvY1NnKZD8VFSOZmyZhz/IWnWSALndoatX63JpQLE4M=; b=Z4w7KfQ6ImaS6glQb49z0B/dcCG6N6poGGORT+WgBD36V5jxSGXe2gQgbk0xJaVmpNoAOI 9KMzbhdFOZKpuDrF+/eTvveIDvl8vCMfuOOHrqu/6CzmEpkeDwV2ilsrtF9EX0jwhdbBoD VnldTnkwQjrnIWmpinbbd4tx9/Jdwks= X-MC-Unique: sMXayfNNPTy8_u9tnEwPGg-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 10/21] tests: testutilsqemu: move virFindFileInPath into domaincapsmock Date: Mon, 19 Apr 2021 19:14:13 +0200 Message-Id: <0b5713255780314fdcf040ae4e151744be78a474.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Having the function on mock library reflect more closely what we usually do in tests. Signed-off-by: Pavel Hrdina --- tests/domaincapsmock.c | 16 ++++++++++++++++ tests/testutilsqemu.c | 15 --------------- 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/tests/domaincapsmock.c b/tests/domaincapsmock.c index d81a898dc0..73690f0b9e 100644 --- a/tests/domaincapsmock.c +++ b/tests/domaincapsmock.c @@ -16,6 +16,7 @@ =20 #include =20 +#include "virfile.h" #include "virhostcpu.h" #ifdef WITH_LIBXL # include "libxl/libxl_capabilities.h" @@ -40,3 +41,18 @@ virHostCPUGetMicrocodeVersion(virArch hostArch G_GNUC_UN= USED) { return 0; } + +char * +virFindFileInPath(const char *file) +{ + if (g_str_has_prefix(file, "qemu-system") || + g_str_equal(file, "qemu-kvm")) { + return g_strdup_printf("/usr/bin/%s", file); + } + + /* Nothing in tests should be relying on real files + * in host OS, so we return NULL to try to force + * an error in such a case + */ + return NULL; +} diff --git a/tests/testutilsqemu.c b/tests/testutilsqemu.c index 7451929807..0a2af5036e 100644 --- a/tests/testutilsqemu.c +++ b/tests/testutilsqemu.c @@ -117,21 +117,6 @@ static const char *qemu_default_ram_id[VIR_ARCH_LAST] = =3D { [VIR_ARCH_SPARC] =3D "sun4m.ram", }; =20 -char * -virFindFileInPath(const char *file) -{ - if (g_str_has_prefix(file, "qemu-system") || - g_str_equal(file, "qemu-kvm")) { - return g_strdup_printf("/usr/bin/%s", file); - } - - /* Nothing in tests should be relying on real files - * in host OS, so we return NULL to try to force - * an error in such a case - */ - return NULL; -} - =20 virCapsHostNUMA * virCapabilitiesHostNUMANewHost(void) --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852504; cv=none; d=zohomail.com; s=zohoarc; b=aoFF38CiXdTHdO+sS9btys2bXZ8IW1yP3YlEdlIG9zrpy7/iQ1rBkz/LihiuXiKMlSSJHqbjIYF7VKA6oPtN11kAjyMZnYle4LlfJ7GWSxrZTN4J5cC5aYHZpTbePKAR8JSEbaKwkQCogulbIIeHNEJG58dK8djXKpMWuM3gMp8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852504; 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=6yCWVP/Bl06wJ2KUE0PowaJR0UKED4OFZDcfE8oLalo=; b=g285tjonGU9eJZ7wv5xP9hGQ+OfgHE+YJG3f46wxILW/ThE47sTy2ymqOJ9F6HmKf+7l4jYE36Pt07cy0RCvIooJKkrSyS46LaeGRsQIFTUHz4GA/iRPLHGGCIG4DbG1q+lU0ItCMhWwcCg+icEijaUvpw0s+ygQk9aBqEXiidI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852504006476.50731621136435; Mon, 19 Apr 2021 10:15:04 -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-435-VmUOXi3DMDGB2EhvS3K7vQ-1; Mon, 19 Apr 2021 13:14:59 -0400 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 2151C83DD29; Mon, 19 Apr 2021 17:14:53 +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 03C0360636; Mon, 19 Apr 2021 17:14:53 +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 C59B01806D25; Mon, 19 Apr 2021 17:14:52 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEfne021888 for ; Mon, 19 Apr 2021 13:14:41 -0400 Received: by smtp.corp.redhat.com (Postfix) id 9307A5D72E; Mon, 19 Apr 2021 17:14:41 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1437E5D742 for ; Mon, 19 Apr 2021 17:14:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852502; 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=6yCWVP/Bl06wJ2KUE0PowaJR0UKED4OFZDcfE8oLalo=; b=XNgaMjzi5O1J+Tz69pKfr2RLXWGKPzbNEXkT61d6Ln4i3DPAMS7BnABaHl5UZnu1xy6dMl BBrFPLmcBo6PEkBD/2gUES83v4slj3ZoTODvKPQLqhELJ3DI6vPkF9iyODxzl7/0b+5NZg kevcSHJwYv34JRHRmFUMOjDq7t9ynP4= X-MC-Unique: VmUOXi3DMDGB2EhvS3K7vQ-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 11/21] meson: don't check collie as program for sheepdog Date: Mon, 19 Apr 2021 19:14:14 +0200 Message-Id: <77f1abe3513023873bafd68fc41ddc7a559359dd.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.11 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Upstream sheepdog changed collie to dog back in 2013 in version 0.7.0. Looking into repology that version is no longer used by any distribution supported by libvirt. Signed-off-by: Pavel Hrdina --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index cd88e26f9a..837955de37 100644 --- a/meson.build +++ b/meson.build @@ -1927,7 +1927,7 @@ if conf.has('WITH_LIBVIRTD') endif =20 if not get_option('storage_sheepdog').disabled() - sheepdogcli_prog =3D find_program(['collie', 'dog'], required: get_opt= ion('storage_sheepdog'), dirs: libvirt_sbin_path) + sheepdogcli_prog =3D find_program('dog', required: get_option('storage= _sheepdog'), dirs: libvirt_sbin_path) =20 if sheepdogcli_prog.found() use_storage =3D true --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852511; cv=none; d=zohomail.com; s=zohoarc; b=agMxIxrtlHFjIoI+u6DRBfj0QqVkr8JQvK3J29BlADNX6qV0J3NMlqrGmdVBlP9PLd5XMH1GHD0TnMtffI07ajUkap2c9h+pVqu/SK503895YvSMIZbGd+gI8RZO2mSXXrLaeh9N8vUKeVE9j4gvGpBeXiGWMnkqje3TVXKBPdc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852511; 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=5bE842mutvOgWEy8bR5bJ5mQtqDVndR2Yczw1us7oSk=; b=QRI76E1YqQvUJbjLdatJePECOK4B5juzWIHHwrUFR1lCSfbFI0M3nwi6GVby/uo5O2OaD5DlcEITb/c4kMZmi09fVAP40ueUlBAkxNd2jFExh80jOxK3yCQ7SCkXmbHOws9xhP7O3IJoiJKPJzUmW3wsfeXN0LwJ2iXbD014uZI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1618852510909428.5595181116473; Mon, 19 Apr 2021 10:15:10 -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-160-wSHDklCNOAaOqjuTw8il7w-1; Mon, 19 Apr 2021 13:15:03 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 964A518397AA; Mon, 19 Apr 2021 17:14:58 +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 719E15C1D0; Mon, 19 Apr 2021 17:14:58 +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 39C2C44A6D; Mon, 19 Apr 2021 17:14:58 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEoW6021929 for ; Mon, 19 Apr 2021 13:14:50 -0400 Received: by smtp.corp.redhat.com (Postfix) id 960305D742; Mon, 19 Apr 2021 17:14:50 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id DC81F5D755 for ; Mon, 19 Apr 2021 17:14:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852507; 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=5bE842mutvOgWEy8bR5bJ5mQtqDVndR2Yczw1us7oSk=; b=LPJmxnl4Lz3L4EMRRuDZ3dmH7mJyPI7hPbJiwuADZ/8vK6/I0bHIOJvaX3AEdr4za3Or1k x7xIRzPL2EHygEtGRn2KcG9y260CPw07j9Jf2wA7BksA9kGCDXhWddEojseteu0oce17rp yvMLmgLQJB9smnTyu8OZVOuNLJtPbeY= X-MC-Unique: wSHDklCNOAaOqjuTw8il7w-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 12/21] bhyvexml2argvtest: use virCommandToStringFull to strip command path Date: Mon, 19 Apr 2021 19:14:15 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Currently the tests would fail if the bhyve commands are installed in different path then /usr/bin. Strip the command path to not depend on the host environment. Signed-off-by: Pavel Hrdina Reviewed-by: Daniel P. Berrang=C3=A9 --- tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.ldargs | 2 +- .../bhyvexml2argv-addr-isa-controller-on-slot-1.args | 2 +- .../bhyvexml2argv-addr-isa-controller-on-slot-1.ldargs | 2 +- .../bhyvexml2argv-addr-isa-controller-on-slot-31.args | 2 +- .../bhyvexml2argv-addr-isa-controller-on-slot-31.ldargs | 2 +- .../bhyvexml2argv-addr-more-than-32-sata-disks.args | 2 +- .../bhyvexml2argv-addr-more-than-32-sata-disks.ldargs | 2 +- .../bhyvexml2argv-addr-multiple-sata-disks.args | 2 +- .../bhyvexml2argv-addr-multiple-sata-disks.ldargs | 2 +- .../bhyvexml2argv-addr-multiple-virtio-disks.args | 2 +- .../bhyvexml2argv-addr-multiple-virtio-disks.ldargs | 2 +- .../bhyvexml2argv-addr-no32devs-multiple-sata-disks.args | 2 +- .../bhyvexml2argv-addr-no32devs-multiple-sata-disks.ldargs | 2 +- .../bhyvexml2argv-addr-no32devs-single-sata-disk.args | 2 +- .../bhyvexml2argv-addr-no32devs-single-sata-disk.ldargs | 2 +- .../bhyvexml2argv-addr-non-isa-controller-on-slot-1.args | 2 +- .../bhyvexml2argv-addr-single-sata-disk.args | 2 +- .../bhyvexml2argv-addr-single-sata-disk.ldargs | 2 +- .../bhyvexml2argv-addr-single-virtio-disk.args | 2 +- .../bhyvexml2argv-addr-single-virtio-disk.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-base.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-base.ldargs | 2 +- .../bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.args | 2 +- .../bhyvexml2argv-bhyveload-bootorder.ldargs | 2 +- .../bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.args | 2 +- .../bhyvexml2argv-bhyveload-bootorder1.ldargs | 2 +- .../bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.args | 2 +- .../bhyvexml2argv-bhyveload-bootorder3.ldargs | 2 +- .../bhyvexml2argv-bhyveload-explicitargs.args | 2 +- .../bhyvexml2argv-bhyveload-explicitargs.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-commandline.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-commandline.ldargs | 2 +- .../bhyvexml2argv-console-master-slave-not-specified.args | 2 +- .../bhyvexml2argv-console-master-slave-not-specified.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-console.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-console.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-firmware-efi.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.args | 2 +- .../bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-localtime.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-localtime.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-msrs.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-msrs.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.args | 2 +- .../bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-serial.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-serial.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-sound.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-sound.ldargs | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-uefi.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc-autoport.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc-password.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc-resolution.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-io.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-off.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-on.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-vnc.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-wired.args | 2 +- tests/bhyvexml2argvdata/bhyvexml2argv-wired.ldargs | 2 +- tests/bhyvexml2argvtest.c | 4 ++-- 89 files changed, 90 insertions(+), 90 deletions(-) diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.args b/tests/bh= yvexml2argvdata/bhyvexml2argv-acpiapic.args index 001e44147e..146e3c6eee 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -A \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.ldargs b/tests/= bhyvexml2argvdata/bhyvexml2argv-acpiapic.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-acpiapic.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-s= lot-1.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-s= lot-1.args index 498455275a..735a084ac7 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-1.a= rgs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-1.a= rgs @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-s= lot-1.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on= -slot-1.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-1.l= dargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-1.l= dargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-s= lot-31.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-= slot-31.args index 70c44932c8..0846afafd0 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-31.= args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-31.= args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-s= lot-31.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-o= n-slot-31.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-31.= ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-isa-controller-on-slot-31.= ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-d= isks.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-di= sks.args index bd987c86aa..51434ed1df 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-disks.ar= gs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-disks.ar= gs @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-d= isks.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-= disks.ldargs index ec3f482ca8..4257ffccee 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-disks.ld= args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-more-than-32-sata-disks.ld= args @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd1.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks= .args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks.args index 0bd1957e96..976d800f47 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks= .ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks.ld= args index ec3f482ca8..4257ffccee 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-sata-disks.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd1.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-dis= ks.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-disks.= args index 73b1e2ad57..47b9ca094f 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-disks.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-disks.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-dis= ks.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-disk= s.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-disks.ldar= gs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-multiple-virtio-disks.ldar= gs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multiple-s= ata-disks.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multip= le-sata-disks.args index 821cc58287..2bb2689c79 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multiple-sata-dis= ks.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multiple-sata-dis= ks.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multiple-s= ata-disks.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-mult= iple-sata-disks.ldargs index ec3f482ca8..4257ffccee 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multiple-sata-dis= ks.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-multiple-sata-dis= ks.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd1.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sat= a-disk.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sa= ta-disk.args index 9923c4cd85..153a1d5035 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sata-disk.= args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sata-disk.= args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sat= a-disk.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-= sata-disk.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sata-disk.= ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-no32devs-single-sata-disk.= ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-non-isa-controller-= on-slot-1.args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-non-isa-control= ler-on-slot-1.args index 12859f7d56..8517c0d06a 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-non-isa-controller-on-slot= -1.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-non-isa-controller-on-slot= -1.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.ar= gs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.args index edcb45a0ae..507e0be668 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.ld= args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-sata-disk.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.= args b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.args index 3ee9614733..9c00e02000 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.= ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.ldar= gs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-addr-single-virtio-disk.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-base.args b/tests/bhyvex= ml2argvdata/bhyvexml2argv-base.args index edcb45a0ae..507e0be668 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-base.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-base.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-base.ldargs b/tests/bhyv= exml2argvdata/bhyvexml2argv-base.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-base.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-base.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.args= b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.args index f790f746a9..a6df2a673e 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.ldar= gs b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.ldargs index b31d65cd06..25cfbc4cc3 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/cdrom.iso \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.arg= s b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.args index e621edbf0e..f10304cc9f 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.lda= rgs b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder1.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.arg= s b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.args index eedc36d35e..96e05c6c9c 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.lda= rgs b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.ldargs index b31d65cd06..25cfbc4cc3 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-bootorder3.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/cdrom.iso \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.a= rgs b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.args index 1c5aa009e8..514ec78c82 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.l= dargs b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.ldargs index 73871acad0..265475b7dc 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-bhyveload-explicitargs.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -X \ -Y \ -Z diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-commandline.args b/tests= /bhyvexml2argvdata/bhyvexml2argv-commandline.args index 153639c370..cfbc57bd8c 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-commandline.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-commandline.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-commandline.ldargs b/tes= ts/bhyvexml2argvdata/bhyvexml2argv-commandline.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-commandline.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-commandline.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slave-not= -specified.args b/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slav= e-not-specified.args index 4d7cb11999..5d0c5c2987 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slave-not-specif= ied.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slave-not-specif= ied.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slave-not= -specified.ldargs b/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-sl= ave-not-specified.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slave-not-specif= ied.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-console-master-slave-not-specif= ied.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-console.args b/tests/bhy= vexml2argvdata/bhyvexml2argv-console.args index 8c6cb78c9f..712dee9a2b 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-console.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-console.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-console.ldargs b/tests/b= hyvexml2argvdata/bhyvexml2argv-console.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-console.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-console.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.args b/tests= /bhyvexml2argvdata/bhyvexml2argv-cputopology.args index 2c88b650b5..d7a232fcb1 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c cpus=3D2,sockets=3D1,cores=3D2,threads=3D1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.ldargs b/tes= ts/bhyvexml2argvdata/bhyvexml2argv-cputopology.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-cputopology.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.args b/tes= ts/bhyvexml2argvdata/bhyvexml2argv-custom-loader.args index aca701c3bf..a8570b3ca2 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.ldargs b/t= ests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.ldargs index 359ad90a2c..ca4bbaa987 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-custom-loader.ldargs @@ -1,4 +1,4 @@ -/fizz_buzz_bazz \ +fizz_buzz_bazz \ -X \ -Y \ -Z diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.args b/t= ests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.args index 8f336d7ef2..f54ebbc8b3 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.ldargs b= /tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.ldargs index 85990fc60b..627a07bdfd 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom-grub.ldargs @@ -1,4 +1,4 @@ -/usr/local/sbin/grub-bhyve \ +grub-bhyve \ --root cd \ --device-map '' \ --memory 214 \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.args b/tests/= bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.args index fd36515efc..ba6ddeffbe 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.ldargs b/test= s/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.ldargs index b31d65cd06..25cfbc4cc3 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-disk-cdrom.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/cdrom.iso \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.args b/tests= /bhyvexml2argvdata/bhyvexml2argv-disk-virtio.args index 3ee9614733..9c00e02000 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.ldargs b/tes= ts/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-disk-virtio.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-firmware-efi.args b/test= s/bhyvexml2argvdata/bhyvexml2argv-firmware-efi.args index b343469d19..c87dc7d779 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-firmware-efi.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-firmware-efi.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.args b/te= sts/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.args index de986b4eb6..c321d4d76d 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.ldargs b/= tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p-readonly.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.args b/tests/bhyve= xml2argvdata/bhyvexml2argv-fs-9p.args index 8943ae211f..0f02d5be4e 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.ldargs b/tests/bhy= vexml2argvdata/bhyvexml2argv-fs-9p.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-fs-9p.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.args b/te= sts/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.args index 1c400e1a7c..9ed28162ac 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.ldargs b/= tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.ldargs index 9a50cf6537..56e2f27cfc 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder.ldargs @@ -1,4 +1,4 @@ -/usr/local/sbin/grub-bhyve \ +grub-bhyve \ --root hd0,msdos1 \ --device-map '' \ --memory 214 \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.args b/t= ests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.args index a09338d004..7ed87b2578 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.ldargs b= /tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.ldargs index 9a50cf6537..56e2f27cfc 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-grub-bootorder2.ldargs @@ -1,4 +1,4 @@ -/usr/local/sbin/grub-bhyve \ +grub-bhyve \ --root hd0,msdos1 \ --device-map '' \ --memory 214 \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.args b/tes= ts/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.args index 91c06e3e3a..5a6ae06256 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.ldargs b/t= ests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.ldargs index 9a50cf6537..56e2f27cfc 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-grub-defaults.ldargs @@ -1,4 +1,4 @@ -/usr/local/sbin/grub-bhyve \ +grub-bhyve \ --root hd0,msdos1 \ --device-map '' \ --memory 214 \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.args b= /tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.args index dfe1334edd..cb64d19aff 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.ldargs= b/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-input-xhci-tablet.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.args b/te= sts/bhyvexml2argvdata/bhyvexml2argv-isa-controller.args index 498455275a..735a084ac7 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.ldargs b/= tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-isa-controller.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-localtime.args b/tests/b= hyvexml2argvdata/bhyvexml2argv-localtime.args index e4f66080b9..c06ffceba1 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-localtime.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-localtime.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -H \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-localtime.ldargs b/tests= /bhyvexml2argvdata/bhyvexml2argv-localtime.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-localtime.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-localtime.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.args b/tests/bhy= vexml2argvdata/bhyvexml2argv-macaddr.args index c17f216cb6..1c737b66e7 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.ldargs b/tests/b= hyvexml2argvdata/bhyvexml2argv-macaddr.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-macaddr.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-msrs.args b/tests/bhyvex= ml2argvdata/bhyvexml2argv-msrs.args index 4b0e28ba41..60e5a60db2 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-msrs.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-msrs.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -w \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-msrs.ldargs b/tests/bhyv= exml2argvdata/bhyvexml2argv-msrs.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-msrs.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-msrs.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.args b/tests/b= hyvexml2argvdata/bhyvexml2argv-net-e1000.args index f6f45bdf43..370929a232 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.ldargs b/tests= /bhyvexml2argvdata/bhyvexml2argv-net-e1000.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-net-e1000.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.args = b/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.args index 050452cfa2..f9ec58793d 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.ldarg= s b/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.ldargs index 9a50cf6537..56e2f27cfc 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub-nocons.ldargs @@ -1,4 +1,4 @@ -/usr/local/sbin/grub-bhyve \ +grub-bhyve \ --root hd0,msdos1 \ --device-map '' \ --memory 214 \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.args b/tests= /bhyvexml2argvdata/bhyvexml2argv-serial-grub.args index f51fa0834c..330f791b85 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.ldargs b/tes= ts/bhyvexml2argvdata/bhyvexml2argv-serial-grub.ldargs index 10f8d92e6c..c9d59cb0b8 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-serial-grub.ldargs @@ -1,4 +1,4 @@ -/usr/local/sbin/grub-bhyve \ +grub-bhyve \ --root hd0,msdos1 \ --device-map '' \ --memory 214 \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-serial.args b/tests/bhyv= exml2argvdata/bhyvexml2argv-serial.args index df12646a88..06ba1ae513 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-serial.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-serial.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-serial.ldargs b/tests/bh= yvexml2argvdata/bhyvexml2argv-serial.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-serial.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-serial.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-sound.args b/tests/bhyve= xml2argvdata/bhyvexml2argv-sound.args index 8a99690ae5..cb61b89ee5 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-sound.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-sound.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-sound.ldargs b/tests/bhy= vexml2argvdata/bhyvexml2argv-sound.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-sound.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-sound.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-uefi.args b/tests/bhyvex= ml2argvdata/bhyvexml2argv-uefi.args index 22a21065db..479712967d 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-uefi.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-uefi.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-autoport.args b/test= s/bhyvexml2argvdata/bhyvexml2argv-vnc-autoport.args index 8b692c1877..3991f9fc16 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-autoport.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-autoport.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-password.args b/test= s/bhyvexml2argvdata/bhyvexml2argv-vnc-password.args index 682b03b2e0..dfd3b0a285 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-password.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-password.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-resolution.args b/te= sts/bhyvexml2argvdata/bhyvexml2argv-vnc-resolution.args index 4b4d62a68c..52cae37f76 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-resolution.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-resolution.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-io.args b/te= sts/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-io.args index 960b2dfe5e..80e2bd7223 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-io.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-io.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-off.args b/t= ests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-off.args index 0639161ad0..1975fdc4d7 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-off.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-off.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-on.args b/te= sts/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-on.args index caa9b0e9a6..e62dfff239 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-on.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc-vgaconf-on.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc.args b/tests/bhyvexm= l2argvdata/bhyvexml2argv-vnc.args index 0301aa666e..049e65227d 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-vnc.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-vnc.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -u \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-wired.args b/tests/bhyve= xml2argvdata/bhyvexml2argv-wired.args index f2c415ece5..b6b0a18529 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-wired.args +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-wired.args @@ -1,4 +1,4 @@ -/usr/sbin/bhyve \ +bhyve \ -c 1 \ -m 214 \ -S \ diff --git a/tests/bhyvexml2argvdata/bhyvexml2argv-wired.ldargs b/tests/bhy= vexml2argvdata/bhyvexml2argv-wired.ldargs index 91f9658137..5905f4b3e6 100644 --- a/tests/bhyvexml2argvdata/bhyvexml2argv-wired.ldargs +++ b/tests/bhyvexml2argvdata/bhyvexml2argv-wired.ldargs @@ -1,4 +1,4 @@ -/usr/sbin/bhyveload \ +bhyveload \ -m 214 \ -d /tmp/freebsd.img \ bhyve diff --git a/tests/bhyvexml2argvtest.c b/tests/bhyvexml2argvtest.c index c4fe4ef17a..cdaa32f65c 100644 --- a/tests/bhyvexml2argvtest.c +++ b/tests/bhyvexml2argvtest.c @@ -86,13 +86,13 @@ static int testCompareXMLToArgvFiles(const char *xml, goto out; } =20 - if (!(actualargv =3D virCommandToString(cmd, true))) + if (!(actualargv =3D virCommandToStringFull(cmd, true, true))) goto out; =20 if (actualdm !=3D NULL) virTrimSpaces(actualdm, NULL); =20 - if (!(actualld =3D virCommandToString(ldcmd, true))) + if (!(actualld =3D virCommandToStringFull(ldcmd, true, true))) goto out; =20 if (virTestCompareToFileFull(actualargv, cmdline, false) < 0) --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852515; cv=none; d=zohomail.com; s=zohoarc; b=cfdlHb5USVuEvuO7UfpO+nXQ1PhxP0T0jdM71kbo2bWIOKZmlNyctEbGug2GVL6UZ5g5VJRi5uugiV/L8qX6WH6XkN9oFpMKUjcnDcYgv8lCxX2y7frWbXnVcn9Hp7QlBZWfQN9wNmGCSfSS+S0LFc0RxaOxefEWki2urMbPVd0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852515; 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=JuDct75JWq8ySL5huIgWoxRQdKmy6fSOiJRCRmjiSc0=; b=OtdRH8SN+6T4CqC+41nHOVyUWxndx1rEchdn8exzyOwS3dRQ8VCda3POYCgmOr/fLbBGberMjtRFF4x2Wb6ZZJjSC+KiUyYXGTLCKcvRv3H46LvGRqqkWuEblIN2cyUf3p2v0YOqH+v/FczC7QgUlA/wYZHFcdliZ4VcqGxzqTs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 16188525153781011.4563680490841; Mon, 19 Apr 2021 10:15:15 -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-412-RoXki2F7N5edytnr2A-8Sw-1; Mon, 19 Apr 2021 13:15:10 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id F380818397AB; Mon, 19 Apr 2021 17:15:01 +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 CDE405C1D0; Mon, 19 Apr 2021 17:15:01 +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 8E47C1806D19; Mon, 19 Apr 2021 17:15:01 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEpip021934 for ; Mon, 19 Apr 2021 13:14:51 -0400 Received: by smtp.corp.redhat.com (Postfix) id 73AED5D743; Mon, 19 Apr 2021 17:14:51 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id E85055D742 for ; Mon, 19 Apr 2021 17:14:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852512; 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=JuDct75JWq8ySL5huIgWoxRQdKmy6fSOiJRCRmjiSc0=; b=MGW3MT7Sx5ey3pbBuYw4LbYAUIIPjK5bbizlKqRbwAjHojES1LCeDxh6ntX4bADmAZVern 3BpAvIfT4izOVh7vRvRKhsaNR8oZnr8gy2CteZvbOiBpYBVXJuoOih0IgBAd+PUzSJ9SL1 JL3n6k06iez6oSdACnWh5oJO0Hlnd38= X-MC-Unique: RoXki2F7N5edytnr2A-8Sw-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 13/21] storage: use virFindFileInPath to validate presence of mkfs Date: Mon, 19 Apr 2021 19:14:16 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Future patch will remove MKFS define as we will no longer check it during compilation. Signed-off-by: Pavel Hrdina --- src/storage/storage_backend_fs.c | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/src/storage/storage_backend_fs.c b/src/storage/storage_backend= _fs.c index bb93d64bbe..b0f8070c6c 100644 --- a/src/storage/storage_backend_fs.c +++ b/src/storage/storage_backend_fs.c @@ -397,13 +397,20 @@ virStorageBackendFileSystemCheck(virStoragePoolObj *p= ool, return 0; } =20 -/* some platforms don't support mkfs */ -#ifdef MKFS static int virStorageBackendExecuteMKFS(const char *device, const char *format) { g_autoptr(virCommand) cmd =3D NULL; + g_autofree char *mkfs =3D virFindFileInPath(MKFS); + + if (!mkfs) { + virReportError(VIR_ERR_INTERNAL_ERROR, + _("mkfs is not supported on this platform: " + "Failed to make filesystem of type '%s' on device= '%s'"), + format, device); + return -1; + } =20 cmd =3D virCommandNewArgList(MKFS, "-t", format, NULL); =20 @@ -426,19 +433,6 @@ virStorageBackendExecuteMKFS(const char *device, =20 return 0; } -#else /* #ifdef MKFS */ -static int -virStorageBackendExecuteMKFS(const char *device G_GNUC_UNUSED, - const char *format G_GNUC_UNUSED) -{ - virReportError(VIR_ERR_INTERNAL_ERROR, - _("mkfs is not supported on this platform: " - "Failed to make filesystem of " - "type '%s' on device '%s'"), - format, device); - return -1; -} -#endif /* #ifdef MKFS */ =20 static int virStorageBackendMakeFileSystem(virStoragePoolObj *pool, --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852505; cv=none; d=zohomail.com; s=zohoarc; b=O55h7r1S8qO8LYmCGzO0cv1KAzuRizBYbArwrW2SxdGuQTpmnj/yaTVm72uoRMNEVWOMRryObzBBjxc9IRZ974fGS2VdWEWTYmEgZd71Q4fl3W56rO4j2F0EYG7fnBVjkuvuo+NX1inZOFg02jOyARrWAsK2F/b19//M8gRtux4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852505; 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=MOFXWg7LlPzGUAuVTB8HiI4DRhSSoXSWpELw+3oLrpU=; b=O3PyZYG2DdIMQnJIIYuHBHKpVr1eLJXKdk1m342koO39MqCxiPaN8SQo3TjtEV6Jv2wt7s3/+MZO0Z5npBx+JXoTvLOLDB02YLRBcRggtf4VrKrjW9y+FheQX8N8MnMsR6R/ML2Ho2W3iTXeqYmwikFQY8BzqN6hoVG9RJ+R+5c= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852505868801.9043567033962; Mon, 19 Apr 2021 10:15:05 -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-169-ZpFD3-_FMyKdSOwXwlQLGQ-1; Mon, 19 Apr 2021 13:15:01 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 1D36783DD2D; Mon, 19 Apr 2021 17:14:55 +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 E26275C257; Mon, 19 Apr 2021 17:14:54 +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 8F4C544A6A; Mon, 19 Apr 2021 17:14:54 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEqQ7021942 for ; Mon, 19 Apr 2021 13:14:52 -0400 Received: by smtp.corp.redhat.com (Postfix) id 513D25D755; Mon, 19 Apr 2021 17:14:52 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id C5E185D742 for ; Mon, 19 Apr 2021 17:14:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852504; 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=MOFXWg7LlPzGUAuVTB8HiI4DRhSSoXSWpELw+3oLrpU=; b=MxEtb/bQvJHMcOxgyNqh1FWMW6AbesG77MxFJetTaTi5GWEFN6Z7jC71b4iAXGRwXWIe5n zBTCY2xtI+rOrP+cmQ2DRJNP/fhjAjU3KmcDeqKAzJINbbtVoDrtxdCRZ67MQn1uJwFoIF HqTc6IFvzX8DGWZRAjaEqfBoyzX2fvs= X-MC-Unique: ZpFD3-_FMyKdSOwXwlQLGQ-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 14/21] virfile: introduce virFindFileInPathFull() Date: Mon, 19 Apr 2021 19:14:17 +0200 Message-Id: <908e02ce81c98b5e170d4aaf9895d215cb701f0a.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Extend virFindFileInPath to search in custom extra paths as well. Some binaries that libvirt needs are not usually in $PATH so we need to have a way to look for these as well. Signed-off-by: Pavel Hrdina --- src/libvirt_private.syms | 2 +- src/util/virfile.c | 16 ++++++++++++++-- src/util/virfile.h | 5 ++++- tests/domaincapsmock.c | 3 ++- tests/virfirewallmock.c | 3 ++- 5 files changed, 23 insertions(+), 6 deletions(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index abd3dc4bd1..717686ddee 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -2254,7 +2254,7 @@ virFileWrapperFdClose; virFileWrapperFdFree; virFileWrapperFdNew; virFileWriteStr; -virFindFileInPath; +virFindFileInPathFull; =20 =20 # util/virfilecache.h diff --git a/src/util/virfile.c b/src/util/virfile.c index 03a7725dd3..7922fda2e5 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -1654,13 +1654,15 @@ virFileIsLink(const char *linkpath) } =20 /* - * Finds a requested executable file in the PATH env. e.g.: + * Finds a requested executable file in the paths provided by @extra_paths + * argument or in PATH env. e.g.: * "qemu-img" will return "/usr/bin/qemu-img" * * You must free the result */ char * -virFindFileInPath(const char *file) +virFindFileInPathFull(const char *file, + const GStrv extra_paths) { const char *origpath =3D NULL; g_auto(GStrv) paths =3D NULL; @@ -1692,6 +1694,16 @@ virFindFileInPath(const char *file) return abspath; } =20 + /* First search in paths provided by caller. + */ + if (extra_paths) { + for (pathiter =3D extra_paths; *pathiter; pathiter++) { + g_autofree char *fullpath =3D g_strdup_printf("%s/%s", *pathit= er, file); + if (virFileIsExecutable(fullpath)) + return g_steal_pointer(&fullpath); + } + } + /* copy PATH env so we can tweak it */ origpath =3D getenv("PATH"); if (!origpath) diff --git a/src/util/virfile.h b/src/util/virfile.h index b9f7b1766f..eee27c2efc 100644 --- a/src/util/virfile.h +++ b/src/util/virfile.h @@ -184,9 +184,12 @@ int virFileResolveAllLinks(const char *linkpath, int virFileIsLink(const char *linkpath) ATTRIBUTE_NONNULL(1) G_GNUC_WARN_UNUSED_RESULT; =20 -char *virFindFileInPath(const char *file) +char *virFindFileInPathFull(const char *file, + const GStrv extra_paths) G_GNUC_NO_INLINE; =20 +#define virFindFileInPath(file) virFindFileInPathFull(file, NULL) + char *virFileFindResource(const char *filename, const char *builddir, const char *installdir) diff --git a/tests/domaincapsmock.c b/tests/domaincapsmock.c index 73690f0b9e..4bef2b72d0 100644 --- a/tests/domaincapsmock.c +++ b/tests/domaincapsmock.c @@ -43,7 +43,8 @@ virHostCPUGetMicrocodeVersion(virArch hostArch G_GNUC_UNU= SED) } =20 char * -virFindFileInPath(const char *file) +virFindFileInPathFull(const char *file, + const GStrv extra_args G_GNUC_UNUSED) { if (g_str_has_prefix(file, "qemu-system") || g_str_equal(file, "qemu-kvm")) { diff --git a/tests/virfirewallmock.c b/tests/virfirewallmock.c index 6b096701c9..a047e56bd9 100644 --- a/tests/virfirewallmock.c +++ b/tests/virfirewallmock.c @@ -20,7 +20,8 @@ #include "virfile.h" =20 char * -virFindFileInPath(const char *file) +virFindFileInPathFull(const char *file, + const GStrv extra_args G_GNUC_UNUSED) { if (file && (g_strrstr(file, "ebtables") || --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852519; cv=none; d=zohomail.com; s=zohoarc; b=CzV9+0BLsvZf4lnxh9nqbSz6OUAZmw1hdwlXfZddDExwSIm38RobNYNB/gH/tSKtl17frp130BLN71bscezI5WsjSPzmRDPFa3i+rhv73msN3Aw29dJsRVSt+876yZBv8Va8M6BMYuulQpkAH0ly+JpnixLx/ZWC4U/oSx7x37k= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852519; 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=CYcwflTvjDhLci/ii+KVsnfoDf8FkiSF1zEB1E1t+x8=; b=nzbxaFr67WADlRFrmvGqz7VRqofkny94Z9/VaLLlGw1sL+vwrjq1rsGtA4a3VABaYJTccrOM3oCIBlhH2cClnoP+38PFiSyg2e1PTYebDLOyTU+p4+OU6x2/9VFA8UJWaP7TG8fQ5944fxCk80QK7VD6VziDRv6yB3uDps/hB9o= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852519035352.86121399552314; Mon, 19 Apr 2021 10:15:19 -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-53-oWNqQIF7Pna6-nkNftSExg-1; Mon, 19 Apr 2021 13:15:14 -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 2E0F6107ACE4; Mon, 19 Apr 2021 17:15:05 +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 0C348614ED; Mon, 19 Apr 2021 17:15:05 +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 AD5C055343; Mon, 19 Apr 2021 17:15:04 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHErAZ021954 for ; Mon, 19 Apr 2021 13:14:53 -0400 Received: by smtp.corp.redhat.com (Postfix) id 2EB295D742; Mon, 19 Apr 2021 17:14:53 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id A3F5B5D74B for ; Mon, 19 Apr 2021 17:14:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852517; 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=CYcwflTvjDhLci/ii+KVsnfoDf8FkiSF1zEB1E1t+x8=; b=G5u3VEblsWAgKL2AOvHJrneEsTosPPwJ2hUhUW7luKn42ELwUZISt5TUR0cfQZ0A6OYiCO fJ6I7rDSxJzOar67fhtqN0MxAbEf524eVUDPghjbbNakqb0LwWQK9zSTWkElufWG0lS/hk LF98mHYIUrVb56m8/eFzVs+Ai1ReYh4= X-MC-Unique: oWNqQIF7Pna6-nkNftSExg-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 15/21] qemu_conf: use virFindFileInPathFull for runtime binaries Date: Mon, 19 Apr 2021 19:14:18 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Following patches will stop detecting the full path during compilation so we will need to do it here. Signed-off-by: Pavel Hrdina --- src/qemu/qemu_conf.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c index 916a3d36ee..437b3ce2be 100644 --- a/src/qemu/qemu_conf.c +++ b/src/qemu/qemu_conf.c @@ -109,6 +109,12 @@ virQEMUDriverConfig *virQEMUDriverConfigNew(bool privi= leged, const char *root) { g_autoptr(virQEMUDriverConfig) cfg =3D NULL; + const char *qemu_extra_paths[] =3D { + "/usr/libexec", + "/usr/lib/qemu", + "/usr/lib", + NULL, + }; =20 if (virQEMUConfigInitialize() < 0) return NULL; @@ -267,10 +273,14 @@ virQEMUDriverConfig *virQEMUDriverConfigNew(bool priv= ileged, return NULL; } =20 - cfg->bridgeHelperName =3D g_strdup(QEMU_BRIDGE_HELPER); - cfg->prHelperName =3D g_strdup(QEMU_PR_HELPER); - cfg->slirpHelperName =3D g_strdup(QEMU_SLIRP_HELPER); - cfg->dbusDaemonName =3D g_strdup(QEMU_DBUS_DAEMON); + cfg->bridgeHelperName =3D virFindFileInPathFull(QEMU_BRIDGE_HELPER, + (GStrv) qemu_extra_paths= ); + cfg->prHelperName =3D virFindFileInPathFull(QEMU_PR_HELPER, + (GStrv) qemu_extra_paths); + cfg->slirpHelperName =3D virFindFileInPathFull(QEMU_SLIRP_HELPER, + (GStrv) qemu_extra_paths); + cfg->dbusDaemonName =3D virFindFileInPathFull(QEMU_DBUS_DAEMON, + (GStrv) qemu_extra_paths); =20 cfg->securityDefaultConfined =3D true; cfg->securityRequireConfined =3D false; --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852571; cv=none; d=zohomail.com; s=zohoarc; b=ZUMPdwk60bSR0gBhGk8abQ7ovGosl/d6GvntoRWQlIQpHn4/r0v/3UYIlDatZCFigY0X+mMSPZZZtOKgFHcSINzjzGtMWT+SoZ7jqWQDEakLwQPi6WMznqqj5oFWDSRy/lMEUHhmiqk8ljF82Hj04LPrfRfDAjeRbvOShLJG4WM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852571; 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=v0IIwN8CQTzkcuNlJivClT2zpKhxZLWTx4HP3ynqkxE=; b=OJMolBr7dFHCMkEL2c06Kx5nfDXorGtZDl0Xe6Iwce4pT+va0TvZPOWoT00SoLr13zfW9h2jQHZpt25gx9lXTHU6RaAXhFuZuSPajAM4Jbmz14Y1lONbbydEbsUz3wKNuYC5AQUUuwIme7XfVxA6TOrEKPCD1ohiObQv/j5zuSs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852571239425.983129306799; Mon, 19 Apr 2021 10:16:11 -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-601-y8RMnFesMVeHn6WxX8MrQA-1; Mon, 19 Apr 2021 13:15:18 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C859118397A4; Mon, 19 Apr 2021 17:15:08 +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 A0FE75C3DF; Mon, 19 Apr 2021 17:15:08 +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 613411806D1D; Mon, 19 Apr 2021 17:15:08 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEsP7021985 for ; Mon, 19 Apr 2021 13:14:54 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0E5DD5D743; Mon, 19 Apr 2021 17:14:54 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 821575D742 for ; Mon, 19 Apr 2021 17:14:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852569; 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=v0IIwN8CQTzkcuNlJivClT2zpKhxZLWTx4HP3ynqkxE=; b=LvqL45Grt1sVFmH670oqx6fh3dep+uc1KnBrHFPat+KX9knJ7xo+4y37ipRXEueaZsF/8c i/T6CbY6hW52HMffb0SeUB0ijnD3JuU5GgHwLOo69GvXjIogl1i7nZiDBhuSViez5ix5+o cJigUNU+9tEJ1isBfi6bgsU/4pfAFaI= X-MC-Unique: y8RMnFesMVeHn6WxX8MrQA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 16/21] meson: drop check for runtime binary dependencies Date: Mon, 19 Apr 2021 19:14:19 +0200 Message-Id: <9deaca98b0aa3c06b7bc9a83342c6fb90bd9cd22.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" These binaries are used only during runtime so technically there is no need to check for them while compiling libvirt. Usually the location is the same while compiling and running but it may not be true. In addition they are not strictly required to compile the code so this way developers don't have to install it or create fake binaries in order to compile the code. Signed-off-by: Pavel Hrdina --- meson.build | 63 ---------------------------- src/network/bridge_driver.c | 2 + src/node_device/node_device_driver.c | 2 + src/qemu/qemu_conf.c | 5 +++ src/storage/storage_util.c | 2 + src/util/virdnsmasq.c | 1 + src/util/virfirewall.h | 4 ++ src/util/virkmod.h | 3 ++ src/util/virnetdevbandwidth.h | 2 + src/util/virnetdevip.c | 2 + src/util/virnetdevmidonet.c | 2 + src/util/virnetdevopenvswitch.c | 2 + src/util/virsysinfo.c | 1 + src/util/virutil.c | 2 + 14 files changed, 30 insertions(+), 63 deletions(-) diff --git a/meson.build b/meson.build index 837955de37..fc8fc4f252 100644 --- a/meson.build +++ b/meson.build @@ -926,24 +926,9 @@ endforeach =20 optional_programs =3D [ 'augparse', - 'dmidecode', - 'dnsmasq', - 'ebtables', 'flake8', - 'ip', - 'ip6tables', - 'iptables', 'iscsiadm', - 'mdevctl', - 'mm-ctl', - 'modprobe', - 'ovs-vsctl', 'pdwtags', - 'radvd', - 'rmmod', - 'scrub', - 'tc', - 'udevadm', ] =20 foreach name : optional_programs @@ -1706,54 +1691,6 @@ if not get_option('driver_qemu').disabled() endif conf.set_quoted('QEMU_USER', qemu_user) conf.set_quoted('QEMU_GROUP', qemu_group) - - qemu_bridge_prog =3D find_program( - 'qemu-bridge-helper', - dirs: [ '/usr/libexec', '/usr/lib/qemu', '/usr/lib' ], - required: false - ) - if qemu_bridge_prog.found() - qemu_bridge_path =3D qemu_bridge_prog.path() - else - qemu_bridge_path =3D '/usr/libexec/qemu-bridge-helper' - endif - conf.set_quoted('QEMU_BRIDGE_HELPER', qemu_bridge_path) - - qemu_pr_prog =3D find_program( - 'qemu-pr-helper', - dirs: [ '/usr/bin', '/usr/libexec' ], - required: false - ) - if qemu_pr_prog.found() - qemu_pr_path =3D qemu_pr_prog.path() - else - qemu_pr_path =3D '/usr/bin/qemu-pr-helper' - endif - conf.set_quoted('QEMU_PR_HELPER', qemu_pr_path) - - qemu_slirp_prog =3D find_program( - 'slirp-helper', - dirs: [ '/usr/bin', '/usr/libexec' ], - required: false - ) - if qemu_slirp_prog.found() - qemu_slirp_path =3D qemu_slirp_prog.path() - else - qemu_slirp_path =3D '/usr/bin/slirp-helper' - endif - conf.set_quoted('QEMU_SLIRP_HELPER', qemu_slirp_path) - - qemu_dbus_daemon_prog =3D find_program( - 'dbus-daemon', - dirs: [ '/usr/bin', '/usr/libexec' ], - required: false - ) - if qemu_dbus_daemon_prog.found() - qemu_dbus_daemon_path =3D qemu_dbus_daemon_prog.path() - else - qemu_dbus_daemon_path =3D '/usr/bin/dbus-daemon' - endif - conf.set_quoted('QEMU_DBUS_DAEMON', qemu_dbus_daemon_path) endif endif =20 diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index ee3f9dab0a..8e1a42b119 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -74,6 +74,8 @@ #define VIR_FROM_THIS VIR_FROM_NETWORK #define MAX_BRIDGE_ID 256 =20 +#define RADVD "radvd" + static virMutex bridgeNameValidateMutex =3D VIR_MUTEX_INITIALIZER; =20 /** diff --git a/src/node_device/node_device_driver.c b/src/node_device/node_de= vice_driver.c index b0cc63ed42..bf70083f2a 100644 --- a/src/node_device/node_device_driver.c +++ b/src/node_device/node_device_driver.c @@ -48,6 +48,8 @@ =20 VIR_LOG_INIT("node_device.node_device_driver"); =20 +#define MDEVCTL "mdevctl" + virNodeDeviceDriverState *driver; =20 =20 diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c index 437b3ce2be..d228504d8c 100644 --- a/src/qemu/qemu_conf.c +++ b/src/qemu/qemu_conf.c @@ -55,6 +55,11 @@ =20 VIR_LOG_INIT("qemu.qemu_conf"); =20 +#define QEMU_BRIDGE_HELPER "qemu-bridge-helper" +#define QEMU_PR_HELPER "qemu-pr-helper" +#define QEMU_SLIRP_HELPER "slirp-helper" +#define QEMU_DBUS_DAEMON "dbus-daemon" + /* These are only defaults, they can be changed now in qemu.conf and * explicitly specified port is checked against these two (makes * sense to limit the values). diff --git a/src/storage/storage_util.c b/src/storage/storage_util.c index 7efadc2197..c225f2ab6b 100644 --- a/src/storage/storage_util.c +++ b/src/storage/storage_util.c @@ -84,6 +84,8 @@ VIR_LOG_INIT("storage.storage_util"); # define S_IRWXUGO (S_IRWXU | S_IRWXG | S_IRWXO) #endif =20 +#define SCRUB "scrub" + /* virStorageBackendNamespaceInit: * @poolType: virStoragePoolType * @xmlns: Storage Pool specific namespace callback methods diff --git a/src/util/virdnsmasq.c b/src/util/virdnsmasq.c index f2f606913f..b666c2f9d3 100644 --- a/src/util/virdnsmasq.c +++ b/src/util/virdnsmasq.c @@ -48,6 +48,7 @@ VIR_LOG_INIT("util.dnsmasq"); =20 #define DNSMASQ_HOSTSFILE_SUFFIX "hostsfile" #define DNSMASQ_ADDNHOSTSFILE_SUFFIX "addnhosts" +#define DNSMASQ "dnsmasq" =20 static void dhcphostFreeContent(dnsmasqDhcpHost *host) diff --git a/src/util/virfirewall.h b/src/util/virfirewall.h index 169d99fe2b..a3954c5ed0 100644 --- a/src/util/virfirewall.h +++ b/src/util/virfirewall.h @@ -22,6 +22,10 @@ =20 #include "internal.h" =20 +#define EBTABLES_PATH "ebtables" +#define IPTABLES_PATH "iptables" +#define IP6TABLES_PATH "ip6tables" + typedef struct _virFirewall virFirewall; =20 typedef struct _virFirewallRule virFirewallRule; diff --git a/src/util/virkmod.h b/src/util/virkmod.h index bb043d4876..58311909eb 100644 --- a/src/util/virkmod.h +++ b/src/util/virkmod.h @@ -23,6 +23,9 @@ =20 #include "internal.h" =20 +#define MODPROBE "modprobe" +#define RMMOD "rmmod" + char *virKModLoad(const char *) ATTRIBUTE_NONNULL(1); char *virKModUnload(const char *) diff --git a/src/util/virnetdevbandwidth.h b/src/util/virnetdevbandwidth.h index 3d520721f6..6c91bd0f33 100644 --- a/src/util/virnetdevbandwidth.h +++ b/src/util/virnetdevbandwidth.h @@ -21,6 +21,8 @@ #include "internal.h" #include "virmacaddr.h" =20 +#define TC "tc" + typedef struct _virNetDevBandwidthRate virNetDevBandwidthRate; struct _virNetDevBandwidthRate { unsigned long long average; /* kbytes/s */ diff --git a/src/util/virnetdevip.c b/src/util/virnetdevip.c index 0ce8f5b536..f4cf6ac39f 100644 --- a/src/util/virnetdevip.c +++ b/src/util/virnetdevip.c @@ -50,6 +50,8 @@ =20 #define VIR_FROM_THIS VIR_FROM_NONE =20 +#define IP_PATH "ip" + VIR_LOG_INIT("util.netdevip"); =20 #if defined(WITH_LIBNL) diff --git a/src/util/virnetdevmidonet.c b/src/util/virnetdevmidonet.c index 9061f1516f..735607e5df 100644 --- a/src/util/virnetdevmidonet.c +++ b/src/util/virnetdevmidonet.c @@ -26,6 +26,8 @@ =20 #define VIR_FROM_THIS VIR_FROM_NONE =20 +#define MM_CTL "mm-ctl" + /** * virNetDevMidonetBindPort: * @ifname: the network interface name diff --git a/src/util/virnetdevopenvswitch.c b/src/util/virnetdevopenvswitc= h.c index 21ee4bdd42..a05128dbca 100644 --- a/src/util/virnetdevopenvswitch.c +++ b/src/util/virnetdevopenvswitch.c @@ -35,6 +35,8 @@ =20 VIR_LOG_INIT("util.netdevopenvswitch"); =20 +#define OVS_VSCTL "ovs-vsctl" + /* * Set openvswitch default timeout */ diff --git a/src/util/virsysinfo.c b/src/util/virsysinfo.c index af9e03c5ac..8bbda9ea69 100644 --- a/src/util/virsysinfo.c +++ b/src/util/virsysinfo.c @@ -53,6 +53,7 @@ static const char *sysinfoCpuinfo =3D "/proc/cpuinfo"; #define SYSINFO sysinfoSysinfo #define CPUINFO sysinfoCpuinfo #define CPUINFO_FILE_LEN (1024*1024) /* 1MB limit for /proc/cpuinfo fil= e */ +#define DMIDECODE "dmidecode" =20 =20 void diff --git a/src/util/virutil.c b/src/util/virutil.c index 3f49a469e5..b7a9808f6a 100644 --- a/src/util/virutil.c +++ b/src/util/virutil.c @@ -57,6 +57,8 @@ #include "virutil.h" #include "virsocket.h" =20 +#define UDEVADM "udevadm" + G_STATIC_ASSERT(sizeof(gid_t) <=3D sizeof(unsigned int) && sizeof(uid_t) <=3D sizeof(unsigned int)); =20 --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852569; cv=none; d=zohomail.com; s=zohoarc; b=fUnEuUWUzoYcRuH2yisklGPIvqH4fIDeSKfjVbQTNAVjzNpaDTaZ4vk/hM74OxartSPfz7K08Jew2C/QpPWDIaBD8e3sh5+uNG2/vjACIo7UVkvJa0o8vckoDiKY4gv7GvBbPQl9mrApAKZtMmAy1Nu1Slu7/3iFoE+gm6tIqqw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852569; 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=wctmCLvw95IFdCZq93ByJOjiTKI6jJz+dHXCFppFvLo=; b=aXS1XzsG31HrV4TZqYKF4LKKG0OtWsWg3grOUhYVsJheo4RnzVcQidN2Wh9I9ZtlqpW9k8QNGKTDuNik2VVLPHr4xvYVnFuFwuKC7Ff37YrzYZunF3xL87rTgfflCfNfcolsjxNJIwN8r0DrIKRvSXXTTvh2vMf+5oDDNsL85rg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1618852569249337.29596489089465; Mon, 19 Apr 2021 10:16:09 -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-457-R_kW6ETeOtm5tK7r-cfPwA-1; Mon, 19 Apr 2021 13:15:05 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 08688107ACF5; Mon, 19 Apr 2021 17:14:59 +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 D91E660BF1; Mon, 19 Apr 2021 17:14:58 +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 A49EB44A74; Mon, 19 Apr 2021 17:14:58 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEs4O021998 for ; Mon, 19 Apr 2021 13:14:54 -0400 Received: by smtp.corp.redhat.com (Postfix) id E1C695D755; Mon, 19 Apr 2021 17:14:54 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 609135D742 for ; Mon, 19 Apr 2021 17:14:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852566; 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=wctmCLvw95IFdCZq93ByJOjiTKI6jJz+dHXCFppFvLo=; b=Ix5UcEALtmNItzMwvxQ06eCrMYzfgYcVTNN2T8lhPtvotzbnSJqPzrCIs+tqKMCtSrzurG l5f5Khcj9UD6ud798ligIcBRJ7aZduxejrZksY4sN5HtILgc2/eI+kj6XgkNe+Pd36xUl4 GvZAdf/Tz/3FJ1F+Sy6RQ2IIU++9Fg4= X-MC-Unique: R_kW6ETeOtm5tK7r-cfPwA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 17/21] meson: move iscsiadm check into storage_iscsi condition Date: Mon, 19 Apr 2021 19:14:20 +0200 Message-Id: <596d8e8e537eb9dc6484f5e55f137e0e048a308b.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" This requires to define the binary name in code because we compile src/util/viriscsi.c unconditionally. Signed-off-by: Pavel Hrdina --- meson.build | 22 ++++++++++++++++------ src/util/viriscsi.h | 2 ++ 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/meson.build b/meson.build index fc8fc4f252..8c71e803bf 100644 --- a/meson.build +++ b/meson.build @@ -927,7 +927,6 @@ endforeach optional_programs =3D [ 'augparse', 'flake8', - 'iscsiadm', 'pdwtags', ] =20 @@ -1802,11 +1801,22 @@ if conf.has('WITH_LIBVIRTD') error('Need glusterfs (libgfapi) for gluster storage driver') endif =20 - if not get_option('storage_iscsi').disabled() and iscsiadm_prog.found() - use_storage =3D true - conf.set('WITH_STORAGE_ISCSI', 1) - elif get_option('storage_iscsi').enabled() - error('We need iscsiadm for iSCSI storage driver') + if not get_option('storage_iscsi').disabled() + iscsi_enable =3D true + iscsiadm_prog =3D find_program('iscsiadm', required: false, dirs: libv= irt_sbin_path) + + if not iscsiadm_prog.found() + if get_option('storage_iscsi').enabled() + error('We need iscsiadm for iSCSI storage driver') + else + iscsi_enable =3D false + endif + endif + + if iscsi_enable + use_storage =3D true + conf.set('WITH_STORAGE_ISCSI', 1) + endif endif =20 if not get_option('storage_iscsi_direct').disabled() and libiscsi_dep.fo= und() diff --git a/src/util/viriscsi.h b/src/util/viriscsi.h index 6d17d139eb..fa7ff280c2 100644 --- a/src/util/viriscsi.h +++ b/src/util/viriscsi.h @@ -23,6 +23,8 @@ =20 #include "internal.h" =20 +#define ISCSIADM "iscsiadm" + char * virISCSIGetSession(const char *devpath, bool probe) --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) client-ip=63.128.21.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 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=1618852511; cv=none; d=zohomail.com; s=zohoarc; b=WfPfNdTUl49sjrPsS4/Y5CVMuvCcn0A3JdXDAJMtxBG40VRBQ12gbYVDIcPPDuk6KsfoO1t1PGqyVbAsNX8TTzbRBWN/mveRMhxIfsBtIohQPjjeZxvlRQGGD6GLQYqJFibK2MQEHX1KSxGPfkciyMFQFDf6rtW4bySN3VuFcxc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852511; 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=e/OoVwWHaGtv25LNCO929thdz35ryOLnkpug8uO8eWc=; b=HkpeEiuTvD7/Z79ltR9Lf7pR9BMMcMboUy7+QkI+27wu37f2RY43iapYCzqPIdDraLkWYfLYmFzJY+QlbvFhy8ZbRCXOZxiVpZeyd7WCX+wAhhEpqTWawEelJ4V2YuuC9V1KfDIZ42jpXDnkVenTyQcy3E7Fr5l7LXfhLIRkl6M= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.zohomail.com with SMTPS id 1618852511754251.67624377120228; Mon, 19 Apr 2021 10:15:11 -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-574-CyNX8p0ZNCmUpJT4bU9aAw-1; Mon, 19 Apr 2021 13:15:07 -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 0D4BC6D58B; Mon, 19 Apr 2021 17:15:02 +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 E13C7614FD; Mon, 19 Apr 2021 17:15:01 +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 A42011806D2B; Mon, 19 Apr 2021 17:15:01 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEtFO022016 for ; Mon, 19 Apr 2021 13:14:55 -0400 Received: by smtp.corp.redhat.com (Postfix) id BF3375D742; Mon, 19 Apr 2021 17:14:55 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3EFE85D743 for ; Mon, 19 Apr 2021 17:14:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852510; 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=e/OoVwWHaGtv25LNCO929thdz35ryOLnkpug8uO8eWc=; b=fG4j1S8YQXqDmsx4kKc0kbKDY8XZB5iziXTPHxbol9og7YfSoG0WeZfONvlInaak1gGJgd ysFY8RxClPf905WWOihI3aOUc1ZQl3pVLBs8DAzsp2qAcYAVkmDsP/IOH7TxcS1ppTiUNa 3SwYZ7YLW90En6Ce8o/097wvcPWWoxI= X-MC-Unique: CyNX8p0ZNCmUpJT4bU9aAw-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 18/21] meson: stop setting runtime binaries defines during compilation Date: Mon, 19 Apr 2021 19:14:21 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Technically the location of these binaries may be different when compiling libvirt or running it. This will allow users to change $PATH to use different binaries as well. Signed-off-by: Pavel Hrdina --- meson.build | 41 ++++---------------------- src/bhyve/bhyve_command.c | 4 +++ src/locking/lock_driver_lockd.c | 12 ++------ src/storage/storage_backend_logical.c | 13 ++++++++ src/storage/storage_backend_sheepdog.c | 2 ++ src/storage/storage_backend_zfs.c | 3 ++ src/storage/storage_util.h | 6 ++++ src/util/virnuma.c | 1 + 8 files changed, 36 insertions(+), 46 deletions(-) diff --git a/meson.build b/meson.build index 8c71e803bf..5d8eb7f95c 100644 --- a/meson.build +++ b/meson.build @@ -1074,9 +1074,7 @@ libparted_version =3D '1.8.0' libparted_dep =3D dependency('libparted', version: '>=3D' + libparted_vers= ion, required: false) if libparted_dep.found() parted_prog =3D find_program('parted', required: false, dirs: libvirt_sb= in_path) - if parted_prog.found() - conf.set_quoted('PARTED', parted_prog.path()) - else + if not parted_prog.found() libparted_dep =3D dependency('', required: false) endif endif @@ -1488,9 +1486,6 @@ if not get_option('driver_bhyve').disabled() and host= _machine.system() =3D=3D 'freeb =20 if bhyve_prog.found() and bhyvectl_prog.found() and bhyveload_prog.found= () conf.set('WITH_BHYVE', 1) - conf.set_quoted('BHYVE', bhyve_prog.path()) - conf.set_quoted('BHYVECTL', bhyvectl_prog.path()) - conf.set_quoted('BHYVELOAD', bhyveload_prog.path()) endif elif get_option('driver_bhyve').enabled() error('The bhyve driver cannot be enabled') @@ -1779,18 +1774,7 @@ if conf.has('WITH_LIBVIRTD') =20 if fs_enable use_storage =3D true - conf.set('WITH_STORAGE_FS', 1) - conf.set_quoted('MOUNT', mount_prog.path()) - conf.set_quoted('UMOUNT', umount_prog.path()) - conf.set_quoted('MKFS', mkfs_prog.path()) - - showmount_prog =3D find_program('showmount', required: false, dirs: = libvirt_sbin_path) - showmount_path =3D '' - if showmount_prog.found() - showmount_path =3D showmount_prog.path() - endif - conf.set_quoted('SHOWMOUNT', showmount_path) endif endif =20 @@ -1835,11 +1819,8 @@ if conf.has('WITH_LIBVIRTD') 'pvs', 'vgs', 'lvs', ] foreach name : lvm_progs - set_variable( - '@0@_prog'.format(name), - find_program(name, required: get_option('storage_lvm'), dirs: libv= irt_sbin_path) - ) - if not get_variable('@0@_prog'.format(name)).found() + lvm_prog =3D find_program(name, required: get_option('storage_lvm'),= dirs: libvirt_sbin_path) + if not lvm_prog.found() lvm_enable =3D false endif endforeach @@ -1847,10 +1828,6 @@ if conf.has('WITH_LIBVIRTD') if lvm_enable use_storage =3D true conf.set('WITH_STORAGE_LVM', 1) - - foreach name : lvm_progs - conf.set_quoted(name.to_upper(), get_variable('@0@_prog'.format(na= me)).path()) - endforeach endif endif =20 @@ -1879,7 +1856,6 @@ if conf.has('WITH_LIBVIRTD') if sheepdogcli_prog.found() use_storage =3D true conf.set('WITH_STORAGE_SHEEPDOG', 1) - conf.set_quoted('SHEEPDOGCLI', sheepdogcli_prog.path()) endif endif =20 @@ -1902,11 +1878,8 @@ if conf.has('WITH_LIBVIRTD') if not get_option('storage_zfs').disabled() zfs_enable =3D true foreach name : ['zfs', 'zpool'] - set_variable( - '@0@_prog'.format(name), - find_program(name, required: get_option('storage_zfs'), dirs: libv= irt_sbin_path) - ) - if not get_variable('@0@_prog'.format(name)).found() + zfs_prog =3D find_program(name, required: get_option('storage_zfs'),= dirs: libvirt_sbin_path) + if not zfs_prog.found() zfs_enable =3D false endif endforeach @@ -1914,9 +1887,6 @@ if conf.has('WITH_LIBVIRTD') if zfs_enable use_storage =3D true conf.set('WITH_STORAGE_ZFS', 1) - foreach name : ['zfs', 'zpool'] - conf.set_quoted(name.to_upper(), get_variable('@0@_prog'.format(na= me)).path()) - endforeach endif endif endif @@ -2030,7 +2000,6 @@ if not get_option('numad').disabled() and numactl_dep= .found() numad_prog =3D find_program('numad', required: get_option('numad'), dirs= : libvirt_sbin_path) if numad_prog.found() conf.set('WITH_NUMAD', 1) - conf.set_quoted('NUMAD', numad_prog.path()) endif elif get_option('numad').enabled() error('You must have numactl enabled for numad support.') diff --git a/src/bhyve/bhyve_command.c b/src/bhyve/bhyve_command.c index f8e0ce5123..061138c8ec 100644 --- a/src/bhyve/bhyve_command.c +++ b/src/bhyve/bhyve_command.c @@ -37,6 +37,10 @@ =20 #define VIR_FROM_THIS VIR_FROM_BHYVE =20 +#define BHYVE "bhyve" +#define BHYVECTL "bhyvectl" +#define BHYVELOAD "bhyveload" + VIR_LOG_INIT("bhyve.bhyve_command"); =20 static int diff --git a/src/locking/lock_driver_lockd.c b/src/locking/lock_driver_lock= d.c index 823b918db3..ea787bf87d 100644 --- a/src/locking/lock_driver_lockd.c +++ b/src/locking/lock_driver_lockd.c @@ -454,7 +454,8 @@ static int virLockManagerLockDaemonNew(virLockManager *= lock, } =20 =20 -#ifdef LVS +#define LVS "lvs" + static int virLockManagerGetLVMKey(const char *path, char **key) @@ -508,15 +509,6 @@ virLockManagerGetLVMKey(const char *path, =20 return ret; } -#else -static int -virLockManagerGetLVMKey(const char *path, - char **key G_GNUC_UNUSED) -{ - virReportSystemError(ENOSYS, _("Unable to get LVM key for %s"), path); - return -1; -} -#endif =20 =20 static int virLockManagerLockDaemonAddResource(virLockManager *lock, diff --git a/src/storage/storage_backend_logical.c b/src/storage/storage_ba= ckend_logical.c index ed8e47d880..4bbb585d07 100644 --- a/src/storage/storage_backend_logical.c +++ b/src/storage/storage_backend_logical.c @@ -40,6 +40,19 @@ =20 VIR_LOG_INIT("storage.storage_backend_logical"); =20 +#define PVCREATE "pvcreate" +#define PVREMOVE "pvremove" +#define PVS "pvs" +#define VGCREATE "vgcreate" +#define VGREMOVE "vgremove" +#define VGCHANGE "vgchange" +#define VGSCAN "vgscan" +#define VGS "vgs" +#define LVCREATE "lvcreate" +#define LVREMOVE "lvremove" +#define LVCHANGE "lvchange" +#define LVS "lvs" + =20 static int virStorageBackendLogicalSetActive(virStoragePoolObj *pool, diff --git a/src/storage/storage_backend_sheepdog.c b/src/storage/storage_b= ackend_sheepdog.c index 6490dfae52..beb6445e1e 100644 --- a/src/storage/storage_backend_sheepdog.c +++ b/src/storage/storage_backend_sheepdog.c @@ -35,6 +35,8 @@ =20 #define VIR_FROM_THIS VIR_FROM_STORAGE =20 +#define SHEEPDOGCLI "dog" + static int virStorageBackendSheepdogRefreshVol(virStoragePoolObj *pool, virStorageVolDef *vol); =20 diff --git a/src/storage/storage_backend_zfs.c b/src/storage/storage_backen= d_zfs.c index 6fabeade11..2a5d74357d 100644 --- a/src/storage/storage_backend_zfs.c +++ b/src/storage/storage_backend_zfs.c @@ -33,6 +33,9 @@ =20 VIR_LOG_INIT("storage.storage_backend_zfs"); =20 +#define ZFS "zfs" +#define ZPOOL "zpool" + /* * Some common flags of zfs and zpool commands we use: * -H -- don't print headers and separate fields by tab diff --git a/src/storage/storage_util.h b/src/storage/storage_util.h index aa3c25e9fc..487345ff22 100644 --- a/src/storage/storage_util.h +++ b/src/storage/storage_util.h @@ -25,6 +25,12 @@ #include "storage_driver.h" #include "storage_backend.h" =20 +#define PARTED "parted" +#define MOUNT "mount" +#define UMOUNT "umount" +#define MKFS "mkfs" +#define SHOWMOUNT "showmount" + /* Storage Pool Namespace options to share w/ storage_backend_fs.c and * the virStorageBackendFileSystemMountCmd method */ typedef struct _virStoragePoolFSMountOptionsDef virStoragePoolFSMountOptio= nsDef; diff --git a/src/util/virnuma.c b/src/util/virnuma.c index 31f65d8902..d3cdc3ba53 100644 --- a/src/util/virnuma.c +++ b/src/util/virnuma.c @@ -52,6 +52,7 @@ =20 VIR_LOG_INIT("util.numa"); =20 +#define NUMAD "numad" =20 #if WITH_NUMAD char * --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852519; cv=none; d=zohomail.com; s=zohoarc; b=IHIqleaI75aWkhqaMMMxNIbR4Ha9TK6skohItlXpCBcEtOfiy7Fn3PU5cRTMGzEuTmyzickq3LgqUalceav/o9vNl6FJhCJvqEz/y7m0eiOKZiSUnU7tIIowxhrZeJrdbPrBPb3wEP/LZ8bngKAvBubHuu4EoiDabN+O93i0Tbo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852519; 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=EACQbbUR1t6T6sCTKa9vHT/uu7nS3zAqfi1e5Q0EJVk=; b=ONYpXb5JO1CSd8Z9JiBYwW8HkEZOURm+/xF/ZiKrPngWXQ4W/+bQzEWrFr4pBveEOOs1GcmSxS4EmSXsZ+mS8vGZ07kEGpg0mpO8mNs2sB/c0bLkod8DLfocwgUOiQOTSIsP7b5y94uQPhqIK0MwvNbzozB+2VtnzAnkKNdyeI0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 161885251910548.73673657000688; Mon, 19 Apr 2021 10:15:19 -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-73-_TE_r2y0OkWMQHdGGVK3rA-1; Mon, 19 Apr 2021 13:15:14 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 6137618397AD; Mon, 19 Apr 2021 17:15:05 +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 3CBC860BF1; Mon, 19 Apr 2021 17:15:05 +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 E82C155344; Mon, 19 Apr 2021 17:15:04 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEue1022060 for ; Mon, 19 Apr 2021 13:14:56 -0400 Received: by smtp.corp.redhat.com (Postfix) id A227A5D743; Mon, 19 Apr 2021 17:14:56 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2116F5D742 for ; Mon, 19 Apr 2021 17:14:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852517; 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=EACQbbUR1t6T6sCTKa9vHT/uu7nS3zAqfi1e5Q0EJVk=; b=bD6ML6w5YBAh5hEsg927wuM0FAbVdNH6TE2+4XtNLdgtgHr/PsQaD/D3WaAn+13x66bWdR hfHr168ZVvyd9tXtVqTZiqyerg5H0DEM0BG08DWBUT1mgQJKjBdBrNONCWXRVH145Zojwz fNJRwvhZkLF3VQaLRsVYGzq3Ki3S7iU= X-MC-Unique: _TE_r2y0OkWMQHdGGVK3rA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 19/21] meson: use runtime binaries to only resolve features with "auto" value Date: Mon, 19 Apr 2021 19:14:22 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" This way meson will try to do the right thing by default but we will allow users to change this behavior by using -Dname=3Denabled. This comes with two benefits compared to the previous behavior: - no need to install the binaries if developers would like to check that the code compiles correctly - package maintainers can drop some build dependencies Signed-off-by: Pavel Hrdina --- meson.build | 102 ++++++++++++++++++++++++++++++++-------------------- 1 file changed, 63 insertions(+), 39 deletions(-) diff --git a/meson.build b/meson.build index 5d8eb7f95c..a7d402cd31 100644 --- a/meson.build +++ b/meson.build @@ -1072,12 +1072,6 @@ endif =20 libparted_version =3D '1.8.0' libparted_dep =3D dependency('libparted', version: '>=3D' + libparted_vers= ion, required: false) -if libparted_dep.found() - parted_prog =3D find_program('parted', required: false, dirs: libvirt_sb= in_path) - if not parted_prog.found() - libparted_dep =3D dependency('', required: false) - endif -endif =20 libpcap_version =3D '1.5.0' if not get_option('libpcap').disabled() @@ -1480,11 +1474,17 @@ if not get_option('driver_libvirtd').disabled() endif =20 if not get_option('driver_bhyve').disabled() and host_machine.system() =3D= =3D 'freebsd' - bhyve_prog =3D find_program('bhyve', required: get_option('driver_bhyve'= )) - bhyvectl_prog =3D find_program('bhyvectl', required: get_option('driver_= bhyve')) - bhyveload_prog =3D find_program('bhyveload', required: get_option('drive= r_bhyve')) + bhyve_enable =3D true =20 - if bhyve_prog.found() and bhyvectl_prog.found() and bhyveload_prog.found= () + if get_option('driver_bhyve').auto() + bhyve_prog =3D find_program('bhyve', required: false) + bhyvectl_prog =3D find_program('bhyvectl', required: false) + bhyveload_prog =3D find_program('bhyveload', required: false) + + bhyve_enable =3D bhyve_prog.found() and bhyvectl_prog.found() and bhyv= eload_prog.found() + endif + + if bhyve_enable conf.set('WITH_BHYVE', 1) endif elif get_option('driver_bhyve').enabled() @@ -1740,8 +1740,17 @@ if conf.has('WITH_LIBVIRTD') endif =20 if not get_option('storage_disk').disabled() and devmapper_dep.found() a= nd libparted_dep.found() - use_storage =3D true - conf.set('WITH_STORAGE_DISK', 1) + disk_enable =3D true + + if get_option('storage_disk').auto() + parted_prog =3D find_program('parted', required: false, dirs: libvir= t_sbin_path) + disk_enable =3D parted_prog.found() + endif + + if disk_enable + use_storage =3D true + conf.set('WITH_STORAGE_DISK', 1) + endif elif get_option('storage_disk').enabled() error('You must install libparted and libdevmapper to compile libvirt = with disk storage driver') endif @@ -1762,10 +1771,10 @@ if conf.has('WITH_LIBVIRTD') endif endif =20 - if fs_enable - mount_prog =3D find_program('mount', required: get_option('storage_f= s'), dirs: libvirt_sbin_path) - umount_prog =3D find_program('umount', required: get_option('storage= _fs'), dirs: libvirt_sbin_path) - mkfs_prog =3D find_program('mkfs', required: get_option('storage_fs'= ), dirs: libvirt_sbin_path) + if fs_enable and get_option('storage_fs').auto() + mount_prog =3D find_program('mount', required: false, dirs: libvirt_= sbin_path) + umount_prog =3D find_program('umount', required: false, dirs: libvir= t_sbin_path) + mkfs_prog =3D find_program('mkfs', required: false, dirs: libvirt_sb= in_path) =20 if not mount_prog.found() or not umount_prog.found() or not mkfs_pro= g.found() fs_enable =3D false @@ -1787,14 +1796,11 @@ if conf.has('WITH_LIBVIRTD') =20 if not get_option('storage_iscsi').disabled() iscsi_enable =3D true - iscsiadm_prog =3D find_program('iscsiadm', required: false, dirs: libv= irt_sbin_path) =20 - if not iscsiadm_prog.found() - if get_option('storage_iscsi').enabled() - error('We need iscsiadm for iSCSI storage driver') - else - iscsi_enable =3D false - endif + if get_option('storage_iscsi').auto() + iscsiadm_prog =3D find_program('iscsiadm', required: false, dirs: li= bvirt_sbin_path) + + iscsi_enable =3D iscsiadm_prog.found() endif =20 if iscsi_enable @@ -1818,12 +1824,15 @@ if conf.has('WITH_LIBVIRTD') 'lvchange', 'vgchange', 'vgscan', 'pvs', 'vgs', 'lvs', ] - foreach name : lvm_progs - lvm_prog =3D find_program(name, required: get_option('storage_lvm'),= dirs: libvirt_sbin_path) - if not lvm_prog.found() - lvm_enable =3D false - endif - endforeach + + if get_option('storage_lvm').auto() + foreach name : lvm_progs + lvm_prog =3D find_program(name, required: false, dirs: libvirt_sbi= n_path) + if not lvm_prog.found() + lvm_enable =3D false + endif + endforeach + endif =20 if lvm_enable use_storage =3D true @@ -1851,9 +1860,15 @@ if conf.has('WITH_LIBVIRTD') endif =20 if not get_option('storage_sheepdog').disabled() - sheepdogcli_prog =3D find_program('dog', required: get_option('storage= _sheepdog'), dirs: libvirt_sbin_path) + sheepdog_enable =3D true =20 - if sheepdogcli_prog.found() + if get_option('storage_sheepdog').auto() + sheepdogcli_prog =3D find_program('dog', required: false, dirs: libv= irt_sbin_path) + + sheepdog_enable =3D sheepdogcli_prog.found() + endif + + if sheepdog_enable use_storage =3D true conf.set('WITH_STORAGE_SHEEPDOG', 1) endif @@ -1877,12 +1892,15 @@ if conf.has('WITH_LIBVIRTD') =20 if not get_option('storage_zfs').disabled() zfs_enable =3D true - foreach name : ['zfs', 'zpool'] - zfs_prog =3D find_program(name, required: get_option('storage_zfs'),= dirs: libvirt_sbin_path) - if not zfs_prog.found() - zfs_enable =3D false - endif - endforeach + + if get_option('storage_zfs').auto() + foreach name : ['zfs', 'zpool'] + zfs_prog =3D find_program(name, required: false, dirs: libvirt_sbi= n_path) + if not zfs_prog.found() + zfs_enable =3D false + endif + endforeach + endif =20 if zfs_enable use_storage =3D true @@ -1997,8 +2015,14 @@ if not get_option('nss').disabled() endif =20 if not get_option('numad').disabled() and numactl_dep.found() - numad_prog =3D find_program('numad', required: get_option('numad'), dirs= : libvirt_sbin_path) - if numad_prog.found() + numad_enable =3D true + + if get_option('numad').auto() + numad_prog =3D find_program('numad', required: false, dirs: libvirt_sb= in_path) + numad_enable =3D numad_prog.found() + endif + + if numad_enable conf.set('WITH_NUMAD', 1) endif elif get_option('numad').enabled() --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1618852565; cv=none; d=zohomail.com; s=zohoarc; b=kYUJOu2RlXvMrrYW3ymLt1u7uKGFOFMwL+AIQfcy0eNR6ctcOHaYJ7FBjeZqDBQ8WRlkRBgKNtjZmHrX0cHm5lJKH7K8UKthdC5NAyWs7/9bgLoVKqL8L8iTCAIxj01uA16PIOFzHWnmpJUODCpqb2Maq7z1ICIuI4gLf866Txw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852565; 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=QB16Y4WOh/VdBPwSf4e5Y8Rb4X6ezCaB2U0itBwnLcI=; b=Og/Fawqq31Nftbf7YVzG3M4+UafH7W6RRl4ElAHnsKM0rhQ7hfTNcjvyQcbRBivxhl5sszwBZGcD1xPSoJUGelbE4mGUUnd/6mPhZoqjk0wJAEv0r78CEgpGJ5euptrkbxUej1cOuSx3vU/9Quigce2Uu/WWWajXHFI+npCq+Z0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1618852565182403.4429759823704; Mon, 19 Apr 2021 10:16:05 -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-564-kHo0uPJnMpCq8P2az_3d_w-1; Mon, 19 Apr 2021 13:15:14 -0400 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EC3C483DD21; Mon, 19 Apr 2021 17:15:08 +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 CDE7450A8B; Mon, 19 Apr 2021 17:15:08 +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 95BB31806D20; Mon, 19 Apr 2021 17:15:08 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEvJ3022068 for ; Mon, 19 Apr 2021 13:14:57 -0400 Received: by smtp.corp.redhat.com (Postfix) id 890FD5D743; Mon, 19 Apr 2021 17:14:57 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id 09BAD5D742 for ; Mon, 19 Apr 2021 17:14:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852563; 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=QB16Y4WOh/VdBPwSf4e5Y8Rb4X6ezCaB2U0itBwnLcI=; b=AomHHw6RwzDSScYd+Tvb0CHvl7V1XYutcixLMRoiKbNKC+Y3aw0Wq+ydOXFqTNjbPA2H5L HfIrRMlzNS/Wl3ND6mrcotpotDoiOKEmOGcEiUoGFjWPezgpUBnq7oSnjqibxP4gBlVqZt 11FBGz8oBDHbUua86EoNRPmlRzISz8w= X-MC-Unique: kHo0uPJnMpCq8P2az_3d_w-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 20/21] meson: optional_programs should be used only for building libvirt Date: Mon, 19 Apr 2021 19:14:23 +0200 Message-Id: <6a9cffcc0fdfc198e24bfbd81b556a332fd170d0.1618851847.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.11 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" Drop code that creates defines with program paths and update the comment to reflect current usage of optional_programs. Signed-off-by: Pavel Hrdina --- meson.build | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/meson.build b/meson.build index a7d402cd31..d93f2ff469 100644 --- a/meson.build +++ b/meson.build @@ -922,7 +922,7 @@ foreach item : required_programs_groups endforeach =20 =20 -# optional programs +# optional programs used while building libvirt =20 optional_programs =3D [ 'augparse', @@ -933,14 +933,6 @@ optional_programs =3D [ foreach name : optional_programs prog =3D find_program(name, required: false, dirs: libvirt_sbin_path) varname =3D name.underscorify() - if prog.found() - prog_path =3D prog.path() - else - prog_path =3D name - endif - - conf.set_quoted(varname.to_upper(), prog_path) - conf.set_quoted('@0@_PATH'.format(varname.to_upper()), prog_path) set_variable('@0@_prog'.format(varname), prog) endforeach =20 --=20 2.30.2 From nobody Sat Feb 7 10:11:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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=1618852571; cv=none; d=zohomail.com; s=zohoarc; b=j3zVMAgpfh5p8kv7Kd82CXqesWSQwGETnay3/v5WKrtASOLnndJIpBzAtcFSUfUghhFgeldqRNfZM3HbpcKgE0QTo/6R/WAgz34IpNQpEmanVIs7HJzrZA+xAYMYtPrqSRw7L7+uCtxmwA+u2T3xQyVYvuNOyyJFlI+f5D2UK3s= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618852571; 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=opEwkQjOb1X/aN/IaPRaxPtnzimeR9WNLetP6VUOPgk=; b=DFvlqfEC6uJb2Ikz0QcYHROBycEDMFIb5nlpqwaloNJslnRlD9jEBFMjp4gNwSExoaPF41DEC5jJaE65IwmJ51XvZxDSR67qquJ0UGAl+BX8MTn6I60Q6TyqKcjVjlSn/96ywfv3778H6mOZKSnOl/ZG4u3YqfYy3sV93J8TmA0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1618852571975586.2474934698199; Mon, 19 Apr 2021 10:16:11 -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-348-PZqGg2HqNbWZ8K6WbvDu4Q-1; Mon, 19 Apr 2021 13:15:19 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id B6C9D1006C9A; Mon, 19 Apr 2021 17:15:11 +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 93B665C5E1; Mon, 19 Apr 2021 17:15:11 +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 56A505534E; Mon, 19 Apr 2021 17:15:11 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 13JHEwBJ022077 for ; Mon, 19 Apr 2021 13:14:58 -0400 Received: by smtp.corp.redhat.com (Postfix) id 715655D756; Mon, 19 Apr 2021 17:14:58 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.195.130]) by smtp.corp.redhat.com (Postfix) with ESMTP id DC1595D743 for ; Mon, 19 Apr 2021 17:14:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1618852570; 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=opEwkQjOb1X/aN/IaPRaxPtnzimeR9WNLetP6VUOPgk=; b=e9XCWlqmjVcQ/2PHFQYFrEQ6I42blgeMOAT5ghn8pIQs3Ev0IpxbSBn4i3pdLCkeYVbVgu SKbvsYshnTp6S+y231HVFxBQyUbkTX53zG1rjeE7AR+tN3SztIXOeuh/sip5MsdN7daDgT yVGuiypkreB/FIqrgEVCmvPqd4HQg20= X-MC-Unique: PZqGg2HqNbWZ8K6WbvDu4Q-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH v2 21/21] libvirt.spec: drop no longer required build dependencies Date: Mon, 19 Apr 2021 19:14:24 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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" These are no longer required to build libvirt as they are used during compilation only by meson to detect if some "auto" features should be enabled or not but in spec file we explicitly enable/disable all libvirt features. Signed-off-by: Pavel Hrdina --- libvirt.spec.in | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/libvirt.spec.in b/libvirt.spec.in index f9af330186..7c661b6a82 100644 --- a/libvirt.spec.in +++ b/libvirt.spec.in @@ -299,10 +299,6 @@ BuildRequires: sanlock-devel >=3D 2.4 BuildRequires: libpcap-devel >=3D 1.5.0 BuildRequires: libnl3-devel BuildRequires: libselinux-devel -BuildRequires: dnsmasq >=3D 2.41 -BuildRequires: iptables -BuildRequires: radvd -BuildRequires: ebtables BuildRequires: module-init-tools BuildRequires: cyrus-sasl-devel BuildRequires: polkit >=3D 0.112 @@ -311,13 +307,7 @@ BuildRequires: util-linux %if %{with_qemu} # For managing ACLs BuildRequires: libacl-devel -# From QEMU RPMs -BuildRequires: /usr/bin/qemu-img %endif -# For LVM drivers -BuildRequires: lvm2 -# For pool type=3Discsi -BuildRequires: iscsi-initiator-utils %if %{with_storage_iscsi_direct} # For pool type=3Discsi-direct BuildRequires: libiscsi-devel @@ -341,15 +331,6 @@ BuildRequires: librbd1-devel BuildRequires: glusterfs-api-devel >=3D 3.4.1 BuildRequires: glusterfs-devel >=3D 3.4.1 %endif -%if %{with_storage_sheepdog} -BuildRequires: sheepdog -%endif -%if %{with_storage_zfs} -# Support any conforming implementation of zfs. On stock Fedora -# this is zfs-fuse, but could be zfsonlinux upstream RPMs -BuildRequires: /sbin/zfs -BuildRequires: /sbin/zpool -%endif %if %{with_numactl} # For QEMU/LXC numa info BuildRequires: numactl-devel @@ -374,21 +355,9 @@ BuildRequires: audit-libs-devel # we need /usr/sbin/dtrace BuildRequires: systemtap-sdt-devel =20 -# For mount/umount in FS driver -BuildRequires: util-linux -# For showmount in FS driver (netfs discovery) -BuildRequires: nfs-utils - # Fedora build root suckage BuildRequires: gawk =20 -# For storage wiping with different algorithms -BuildRequires: scrub - -%if %{with_numad} -BuildRequires: numad -%endif - %if %{with_wireshark} BuildRequires: wireshark-devel %endif --=20 2.30.2