From patchwork Fri Jan 28 00:56:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Will Cohen X-Patchwork-Id: 12727754 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E698FC433F5 for ; Fri, 28 Jan 2022 01:01:16 +0000 (UTC) Received: from localhost ([::1]:57472 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nDFdb-0006bp-MY for qemu-devel@archiver.kernel.org; Thu, 27 Jan 2022 20:01:15 -0500 Received: from eggs.gnu.org ([209.51.188.92]:45558) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nDFZO-0003Zh-HO for qemu-devel@nongnu.org; Thu, 27 Jan 2022 19:56:54 -0500 Received: from [2607:f8b0:4864:20::f31] (port=33549 helo=mail-qv1-xf31.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nDFZK-0005OA-QO for qemu-devel@nongnu.org; Thu, 27 Jan 2022 19:56:53 -0500 Received: by mail-qv1-xf31.google.com with SMTP id t7so4498459qvj.0 for ; Thu, 27 Jan 2022 16:56:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=vZzu/37AUOxsP6nKwgFuXoXcH4tiFyEGy9E9ksw3YzU=; b=J3bSYydkQXlUp6c37K0XG4yuQ5H6mFA2pqMVzaXbGgkLU2TPnbkTz8l/XOamxp+vWI 31/tz3hNBOaFLuVWyEn1dhx13ne5+5U6V4T2rRFfe8QaaLL7q7RY9znkbMQLUj7yEIV1 HU9k2gVO7LaSo2rrfijvPbsg6qMwoNScIBYBpS7QpDjM/P12ZaTggLX8VJ5TpeQ7U4IA ZK56eDJl+5Ru+NQFds+i4VkcYCLqV/W3Dg+p2rKs70iu0B7vyTljV1C+Z1PvteMbcOit Uo0edJZ7WPaZh8/bIzceJfrphXDPXyTuogpdVafrmruucNEQ6ZBauNQqBrrykZr/tHG9 nrcw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=vZzu/37AUOxsP6nKwgFuXoXcH4tiFyEGy9E9ksw3YzU=; b=auBIb1buYttGyz3iRR0WNQYGx6HtLsFGMvI43+6q7Jz3v7/RnjUXkZy3F4rMAscWFM 7HCJ9c8nyVxw1HdiY0TO5+L02Mchp/4fcfrVnq8dcjkQUGr/yxVDDruDiTLA9Gyaj+a4 AMEM+eyACaMov0iBlBDiSKj8IJJRVTgsTGaiQKFitfg/mG+4suIyu97dv02SbijMPHN3 z5ApAU6PaDY4cxHkB15XlREh07qpS3TEryMtESAv4aqzKn6/fRaQxGIVWuFsfs804Z52 2edWoLxU95z5JZiPUs8DJ29iEH7yq52p67IjnE1rb4RXYXmOQBlv6QLAsBzdgRNQ4MaZ 1YmQ== X-Gm-Message-State: AOAM532pCxjTfhvvdWtVOalTmO8HX/5fO2HW28pcGv3ATruFSjguliJZ xaPZx5rsP0WKvsU6DUcLmesx0uli2m+gbQ== X-Google-Smtp-Source: ABdhPJyHsYTkFeqHNJ9hdTmUzCOaWdxAfFQNDhP8Z5DpPo/2Tj4+PsQbzjxvr6tYo3pRrJHz5ab4CQ== X-Received: by 2002:a05:6214:e68:: with SMTP id jz8mr5712760qvb.124.1643331396555; Thu, 27 Jan 2022 16:56:36 -0800 (PST) Received: from localhost.localdomain (209-6-248-219.s2265.c3-0.wrx-ubr1.sbo-wrx.ma.cable.rcncustomer.com. [209.6.248.219]) by smtp.gmail.com with ESMTPSA id d8sm2182003qtd.70.2022.01.27.16.56.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 27 Jan 2022 16:56:36 -0800 (PST) From: Will Cohen To: qemu-devel@nongnu.org Subject: [PATCH v3 10/11] 9p: darwin: meson: Allow VirtFS on Darwin Date: Thu, 27 Jan 2022 19:56:10 -0500 Message-Id: <20220128005611.87185-11-wwcohen@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220128005611.87185-1-wwcohen@gmail.com> References: <20220128005611.87185-1-wwcohen@gmail.com> MIME-Version: 1.0 X-Host-Lookup-Failed: Reverse DNS lookup failed for 2607:f8b0:4864:20::f31 (failed) Received-SPF: pass client-ip=2607:f8b0:4864:20::f31; envelope-from=wwcohen@gmail.com; helo=mail-qv1-xf31.google.com X-Spam_score_int: -12 X-Spam_score: -1.3 X-Spam_bar: - X-Spam_report: (-1.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, PDS_HP_HELO_NORDNS=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Laurent Vivier , Thomas Huth , Christian Schoenebeck , Greg Kurz , hi@alyssa.is, Michael Roitzsch , Will Cohen , Paolo Bonzini , Keno Fischer Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" From: Keno Fischer Signed-off-by: Keno Fischer [Michael Roitzsch: - Rebase for NixOS] Signed-off-by: Michael Roitzsch [Will Cohen: - Rebase to master] Signed-off-by: Will Cohen Reviewed-by: Paolo Bonzini --- fsdev/meson.build | 1 + meson.build | 12 ++++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/fsdev/meson.build b/fsdev/meson.build index adf57cc43e..b632b66348 100644 --- a/fsdev/meson.build +++ b/fsdev/meson.build @@ -7,6 +7,7 @@ fsdev_ss.add(when: ['CONFIG_FSDEV_9P'], if_true: files( 'qemu-fsdev.c', ), if_false: files('qemu-fsdev-dummy.c')) softmmu_ss.add_all(when: 'CONFIG_LINUX', if_true: fsdev_ss) +softmmu_ss.add_all(when: 'CONFIG_DARWIN', if_true: fsdev_ss) if have_virtfs_proxy_helper executable('virtfs-proxy-helper', diff --git a/meson.build b/meson.build index e0cfafe8d9..726c618982 100644 --- a/meson.build +++ b/meson.build @@ -1420,17 +1420,21 @@ if not get_option('dbus_display').disabled() endif endif -have_virtfs = (targetos == 'linux' and +if targetos == 'darwin' + have_virtfs = have_system +else + have_virtfs = (targetos == 'linux' and have_system and libattr.found() and libcap_ng.found()) +endif -have_virtfs_proxy_helper = have_virtfs and have_tools +have_virtfs_proxy_helper = targetos == 'linux' and have_virtfs and have_tools if get_option('virtfs').enabled() if not have_virtfs - if targetos != 'linux' - error('virtio-9p (virtfs) requires Linux') + if targetos != 'linux' and targetos != 'darwin' + error('virtio-9p (virtfs) requires Linux or Darwin') elif not libcap_ng.found() or not libattr.found() error('virtio-9p (virtfs) requires libcap-ng-devel and libattr-devel') elif not have_system