From nobody Sun Feb 8 10:03:45 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 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=1594893873; cv=none; d=zohomail.com; s=zohoarc; b=k5lK/H22A1uATaJ39SVYGwnhxaJzhGQ8pGDvZwnRgah7CgipHJ4MzBG5qu1fEDnnPZeNeDLZNzMnSxGaKkRccCrGPeSQR5Pfh4F7fWCF7UuLmGZh67BYTE31Bol/kwJljEqbODNAX8cpoKONJTwu1mLMg7X3PSXwtk++zkT1Py4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1594893873; 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=6vPtvT9pj0P4PtG4mEUaDS8KE1K75rvgCXcqrjuOQqI=; b=e4bkEO0MeTB2mPwnbZdbS9VpV1I6TdHt6ZqJqJLCgsOrXNB1j/M+TR/Lm+uRFGYJDjpCSlk3MgL/O+Vs2g5axev48ksjhWA43Gsu6RglzT8+oiilUqKkuJ09jxoaC0M+6mkMJfJonX38hNNi7kmnck6CJGiti7Jm/FzGdORpp4o= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1594893873866947.4200998379503; Thu, 16 Jul 2020 03:04: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-257-eAOewXciNPGRYrZA-tM3MA-1; Thu, 16 Jul 2020 06:03:28 -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 8A25F100AA24; Thu, 16 Jul 2020 10:03:18 +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 6350674F64; Thu, 16 Jul 2020 10:03:18 +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 30CE3180531C; Thu, 16 Jul 2020 10:03:18 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 06GA3Axh017006 for ; Thu, 16 Jul 2020 06:03:10 -0400 Received: by smtp.corp.redhat.com (Postfix) id 08A3F2E024; Thu, 16 Jul 2020 10:03:10 +0000 (UTC) Received: from antique-work.redhat.com (unknown [10.40.194.85]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7686B2DE9E for ; Thu, 16 Jul 2020 10:03:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594893872; 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=6vPtvT9pj0P4PtG4mEUaDS8KE1K75rvgCXcqrjuOQqI=; b=cT46Zw2/AKHAgCjQX90P2js8rh76LsdxavdGunpLoFUsRqAp+a8X9YPia6H4qYArdFsOB/ ch/LlVL4J4Xw0ZSyZte74PymCE8YMtgQZEA+rk72kKoGvx9tPrZYY2lVHMi9eIFMDCUly7 kqTzsD0m8diP7BxAucxekNn6Ux+mmqo= X-MC-Unique: eAOewXciNPGRYrZA-tM3MA-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH 110/351] meson: add storage vstorage build option Date: Thu, 16 Jul 2020 11:55:46 +0200 Message-Id: <2cc14d0fca81cfa2dfb1862973397e9433f86e98.1594891445.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Pavel Hrdina --- configure.ac | 4 -- m4/virt-storage-vstorage.m4 | 73 ------------------------------------- meson.build | 24 ++++++++++++ meson_options.txt | 1 + 4 files changed, 25 insertions(+), 77 deletions(-) delete mode 100644 m4/virt-storage-vstorage.m4 diff --git a/configure.ac b/configure.ac index ba15aa9bb2b..6416986c303 100644 --- a/configure.ac +++ b/configure.ac @@ -135,15 +135,12 @@ dnl Storage driver checks dnl =20 LIBVIRT_STORAGE_ARG_ZFS -LIBVIRT_STORAGE_ARG_VSTORAGE =20 if test "$with_libvirtd" =3D "no"; then with_storage_zfs=3Dno - with_storage_vstorage=3Dno fi =20 LIBVIRT_STORAGE_CHECK_ZFS -LIBVIRT_STORAGE_CHECK_VSTORAGE =20 dnl Python3 < 3.7 treats the C locale as 7-bit only. dnl We must force env vars so it treats it as UTF-8 @@ -202,7 +199,6 @@ AC_MSG_NOTICE([]) AC_MSG_NOTICE([Storage Drivers]) AC_MSG_NOTICE([]) LIBVIRT_STORAGE_RESULT_ZFS -LIBVIRT_STORAGE_RESULT_VSTORAGE AC_MSG_NOTICE([]) AC_MSG_NOTICE([Driver Loadable Modules]) AC_MSG_NOTICE([]) diff --git a/m4/virt-storage-vstorage.m4 b/m4/virt-storage-vstorage.m4 deleted file mode 100644 index e3b3bb40f0c..00000000000 --- a/m4/virt-storage-vstorage.m4 +++ /dev/null @@ -1,73 +0,0 @@ -dnl The storage vstorage check -dnl -dnl Copyright (C) 2016 Parallels IP Holdings GmbH, Inc. -dnl -dnl This library is free software; you can redistribute it and/or -dnl modify it under the terms of the GNU Lesser General Public -dnl License as published by the Free Software Foundation; either -dnl version 2.1 of the License, or (at your option) any later version. -dnl -dnl This library is distributed in the hope that it will be useful, -dnl but WITHOUT ANY WARRANTY; without even the implied warranty of -dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -dnl Lesser General Public License for more details. -dnl -dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library. If not, see -dnl . -dnl - - -AC_DEFUN([LIBVIRT_STORAGE_ARG_VSTORAGE], [ - LIBVIRT_ARG_WITH_FEATURE([STORAGE_VSTORAGE], - [Virtuozzo Storage backend for the storage driv= er], - [check]) -]) - -AC_DEFUN([LIBVIRT_STORAGE_CHECK_VSTORAGE], [ - if test "$with_storage_vstorage" =3D "yes" || - test "$with_storage_vstorage" =3D "check"; then - AC_PATH_PROG([VSTORAGE], [vstorage], [], [$LIBVIRT_SBIN_PATH]) - AC_PATH_PROG([VSTORAGE_MOUNT], [vstorage-mount], [], [$LIBVIRT_SBIN_PA= TH]) - AC_PATH_PROG([UMOUNT], [umount], [], [$LIBVIRT_SBIN_PATH]) - - if test "$with_storage_vstorage" =3D "yes"; then - if test -z "$VSTORAGE" || test -z "$VSTORAGE_MOUNT"; then - AC_MSG_ERROR([We need vstorage and vstorage-mount tool for Vstorag= e storage driver]); - fi - if test -z "$UMOUNT" ; then - AC_MSG_ERROR([We need umount for Vstorage storage driver]); - fi - else - if test -z "$VSTORAGE" ; then - with_storage_vstorage=3Dno - fi - if test -z "$VSTORAGE_MOUNT" ; then - with_storage_vstorage=3Dno - fi - if test -z "$UMOUNT" ; then - with_storage_vstorage=3Dno - fi - - if test "$with_storage_vstorage" =3D "check" ; then - with_storage_vstorage=3Dyes - fi - fi - - if test "$with_storage_vstorage" =3D "yes" ; then - AC_DEFINE_UNQUOTED([WITH_STORAGE_VSTORAGE], 1, - [whether Vstorage backend for storage driver is e= nabled]) - AC_DEFINE_UNQUOTED([VSTORAGE], ["$VSTORAGE"], - [Location or name of the vstorage client tool]) - AC_DEFINE_UNQUOTED([VSTORAGE_MOUNT], ["$VSTORAGE_MOUNT"], - [Location or name of the vstorage mount tool]) - AC_DEFINE_UNQUOTED([UMOUNT], ["$UMOUNT"], - [Location or name of the umount programm]) - fi - fi - AM_CONDITIONAL([WITH_STORAGE_VSTORAGE], [test "$with_storage_vstorage" = =3D "yes"]) -]) - -AC_DEFUN([LIBVIRT_STORAGE_RESULT_VSTORAGE], [ - LIBVIRT_RESULT([Virtuozzo storage], [$with_storage_vstorage]) -]) diff --git a/meson.build b/meson.build index fcd4bc5e5da..83f7710f93c 100644 --- a/meson.build +++ b/meson.build @@ -1998,6 +1998,29 @@ if conf.has('WITH_LIBVIRTD') conf.set_quoted('SHEEPDOGCLI', sheepdogcli_prog.path()) endif endif + + if not get_option('storage_vstorage').disabled() + vstorage_enable =3D true + + foreach name : ['vstorage', 'vstorage-mount', 'umount'] + set_variable( + '@0@_prog'.format(name.underscorify()), + find_program(name, required: get_option('storage_vstorage'), dirs:= libvirt_sbin_path) + ) + if not get_variable('@0@_prog'.format(name.underscorify())).found() + vstorage_enable =3D false + endif + endforeach + + if vstorage_enable + use_storage =3D true + conf.set('WITH_STORAGE_VSTORAGE', 1) + foreach name : ['vstorage', 'vstorage-mount', 'umount'] + path =3D get_variable('@0@_prog'.format(name.underscorify())).path= () + conf.set_quoted(name.to_upper(), path) + endforeach + endif + endif endif =20 if use_storage @@ -2055,6 +2078,7 @@ storagedriver_summary =3D { 'RBD': conf.has('WITH_STORAGE_RBD'), 'Sheepdog': conf.has('WITH_STORAGE_SHEEPDOG'), 'Gluster': conf.has('WITH_STORAGE_GLUSTER'), + 'Virtuozzo storage': conf.has('WITH_STORAGE_VSTORAGE'), } summary(storagedriver_summary, section: 'Storage Drivers', bool_yn: true) =20 diff --git a/meson_options.txt b/meson_options.txt index eec89eacfb3..4d8cac9254a 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -85,3 +85,4 @@ option('storage_mpath', type: 'feature', value: 'auto', d= escription: 'mpath back option('storage_rbd', type: 'feature', value: 'auto', description: 'RADOS = Block Device backend for the storage driver') option('storage_scsi', type: 'feature', value: 'auto', description: 'SCSI = backend for the storage driver') option('storage_sheepdog', type: 'feature', value: 'auto', description: 'S= heepdog backend for the storage driver') +option('storage_vstorage', type: 'feature', value: 'auto', description: 'V= irtuozzo storage backend for the storage driver') --=20 2.26.2