From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151507; cv=none; d=zohomail.com; s=zohoarc; b=gtYXRDMT3YKcBemoUAfrZ4P/iCcZb2ptWHm7DZZf9YOkOTlgPrfA5NspTd4zCWTTlIKJe3pcqY4z13BsEk/F97kawMoNJnicfi7k0Huq+Nb/HEFQo2NOocJNm5HzYK5PelUO2esJfnTyBg3U/ICwqcLdb68YXNAjrxUQV7aA0zI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151507; h=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=4B4UDVuWyPphMAFqZApEmUz2lUeY3/nAYqP7YZ5Zp90=; b=dxRM+nBb0ib003eQDY2EP7drhHSHWboJ/lecKHUHH2Dw0n2ZXZGTXbQiCoNvJ58sWCJeOEhMmJiLH3PYcrut1gLtaW6M23HLwyYDjJztpvT7MPQj/1qMVB47l8F/4RtCCcukudMulW0n9brpWmHeFoOxHowq7Uj51+Xg9YswZHQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 162315150726317.777533177017517; Tue, 8 Jun 2021 04:25:07 -0700 (PDT) Received: from localhost ([::1]:34300 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZr0-0000b7-1h for importer2@patchew.org; Tue, 08 Jun 2021 07:25:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43440) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZp6-0006Of-1s for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:08 -0400 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:45789) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp3-0007w1-TO for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:07 -0400 Received: by mail-wm1-x334.google.com with SMTP id v206-20020a1cded70000b02901a586d3fa23so1593748wmg.4 for ; Tue, 08 Jun 2021 04:23:04 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=4B4UDVuWyPphMAFqZApEmUz2lUeY3/nAYqP7YZ5Zp90=; b=Esioscn3SozQQh9SkUYwcrlq/QNbaVslIy3Y+Nmnhly74pb5uJP77j2KK+s9/RR/Qn tletnWiobiWxth0WMCuQ24E18i2WVvw6ZVYa24FJ3iFa8wsCBp5dqjjqFmxu6wWey12O TM6q01g8W5E0GkBYtheygALni3djwRKOYdUBNACL/MLZIxJYfUJrjCvXrs+J4Vea6LSE xefHiVNZ0D+2czBxAwEXbfCxZd5WtfJ+a2+LZj/YhTsE7If1G3ydOvL7ox+yTeKWWpIY Cz/MOwsfGlpTMp9cXGSfKTa6fjnWZamWlA+6HKKc82CPtV+fRwEjaHU7igxAMiBHs/Al wT/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=4B4UDVuWyPphMAFqZApEmUz2lUeY3/nAYqP7YZ5Zp90=; b=ETXntyR1tQ1p3+SEmjX+H36c0buLQzEni8lNWt4v0rSx6Qf0XVOic39EQiLSqzHo9c ThRwLKWZGZfOBtGr04SG2MghHKOHs0Xfaf2lZ0IU8ZeOcnPZQ0+jOWhihELnhygz38LO hwse/yPfhOUY9C6X01S83ABalWGDO4SQRtoejxLrAzYp0s53rzv87qK5tbOMUAp6XOa7 xpyBNvgfnSyaS7OwOoBXp3RixH53evPFR+uVwLl4KDh7Idurh6ZFd30QNwedK4JGrgmU ypBDq1QChZaYrsAX1xvAEGzg+JUYDM7A6gVBLGJYfWr6rc8yZee9rhwn5wE2pWI9iYFM G5YA== X-Gm-Message-State: AOAM5320PgR1aLnfBHUir1C7pBSVSUuL/uhHGDoBQopEg4plmbgV5FKX u3ZsMBlxgInrrzODVTNpM6FlsRYY9WzIzA== X-Google-Smtp-Source: ABdhPJw7oMryLeX2IqS3uifHCdmLNiFmVyvKu70swK2FxWjizIKE1b5xztGoMcHGxi5txlPjWmvYaw== X-Received: by 2002:a05:600c:4a09:: with SMTP id c9mr3640391wmp.162.1623151383969; Tue, 08 Jun 2021 04:23:03 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 01/26] meson: drop unused CONFIG_GCRYPT_HMAC Date: Tue, 8 Jun 2021 13:22:36 +0200 Message-Id: <20210608112301.402434-2-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x334.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" CONFIG_GCRYPT_HMAC has been removed now that all supported distros have it. Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 Reviewed-by: Richard Henderson --- meson.build | 1 - 1 file changed, 1 deletion(-) diff --git a/meson.build b/meson.build index 7e3902b5c8..43e9c4590e 100644 --- a/meson.build +++ b/meson.build @@ -2677,7 +2677,6 @@ summary_info +=3D {'GNUTLS support': config_host.h= as_key('CONFIG_GNUTLS')} # TODO: add back version summary_info +=3D {'libgcrypt': config_host.has_key('CONFIG_GCRYPT= ')} if config_host.has_key('CONFIG_GCRYPT') - summary_info +=3D {' hmac': config_host.has_key('CONFIG_GCR= YPT_HMAC')} summary_info +=3D {' XTS': not config_host.has_key('CONFIG= _QEMU_PRIVATE_XTS')} endif # TODO: add back version --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151694; cv=none; d=zohomail.com; s=zohoarc; b=AWpErPc922WoxL0QnfwgOSPZfF+B0+56ZIqnejThuTOrzIoNhCfKoI0fj5ot3zmT4exZgNtAF0pvIgZQ+7Eu7uNfP/07uvvY7qcm20m90AtkgPLrgFw2AE6rZBAujwsdXssrAARIVgP+WtIE97p6EAlzEecI4iGmKQZY4u/ko0A= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151694; h=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=01Gg1F/bxBALFY9w4TKfEUQZREi5Et2k+0kmsX/kvio=; b=LEuPPOcbTrvd1jGIvGcc7ybmxoY+84auy8IUk4ur/h9AvoYE/htgt01Yy+kFWttaQz0szdWuiPN2EowtShVhMYnHOUXBhLSFCAA+0l7yX0hNOvsqD/INyiTeNU7n3+WtUJlf4UxqgOZIVKEgL3uGMkK4rwqr45W89XQ4gEqKzi8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151694707395.3668140171618; Tue, 8 Jun 2021 04:28:14 -0700 (PDT) Received: from localhost ([::1]:42698 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZtw-0006Dg-Pb for importer2@patchew.org; Tue, 08 Jun 2021 07:28:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43456) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZp7-0006Ou-6R for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:09 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:37838) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp5-0007wB-N9 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:09 -0400 Received: by mail-wr1-x429.google.com with SMTP id i94so16113966wri.4 for ; Tue, 08 Jun 2021 04:23:05 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=01Gg1F/bxBALFY9w4TKfEUQZREi5Et2k+0kmsX/kvio=; b=YXjRUoeUYfn94Ojjx4N3Pn6ovI/rmOe7dVTSAqoiLakDiOXRcxHRxyfEXkzRTimsXR JGhyPKZYnoKZEaLBOOYyycPkeINagipvLoBxb7XF1j7myq3zX9WGJEIdIwQ9giP0mrRY 9QhKZaK246hEAdWcoizzHpjIWVxq3Q3wOEGBrueSvNPypGd0Kq7GL5IYBHLs3cyuvnkq Yg7DPyR4nL5osyzGK9uz/lzhBYdcj1ngtFI/IIuzUwHST+YW1IKBdbqU/eTMGdaDEe8O tsKhgvbdS5bh5KEOaqyaj64t5vPDIAZqZU4ZvEgP213yIRIkY5CUzRkJbzTUvCKQ0g6G DUpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=01Gg1F/bxBALFY9w4TKfEUQZREi5Et2k+0kmsX/kvio=; b=SvHWJXGK6TKbPjmAbhxXaUQqTep4XDPWLLc03rWnueyiZHe+6RxSFwCIQQdtB+gRGL we2qsSGC87DaG3wCQWX70x2aEAo2HNP2m0xnO8a8UrdqgI9vdcZyX3bNt+feGtPW/UCU 7CjQwkT6darWmWmjqLGL4IbQFSmaPX4SAYFX3lwJDGo2o7qq4sRG/JUuhYsAUBrVYwj+ UIH/JcxpRX6rVdb5F99kgznQ86JE349QBoZQgPPeKhhvsVn3sUEAcHNdNcIapb/dyrc3 iGlbvOAzstBf0gmWUdJQMQwnIMsk9uJcRNn1GJlTu95MZczbfC9dLq2w/mRu6FpRA1ne mmMw== X-Gm-Message-State: AOAM533Nw/OmtcgMg+vflWljK/s6BS2To8FTvnrTXRK4IvnjFwa8nZep vS0zlryGXCWtTzFJrymIyDi3t7mogwDBWw== X-Google-Smtp-Source: ABdhPJwlIDV3qXXXcC/BK8uLPhuoj8sZwRYt7rrd4Mc/xvW4h+ZgHDmUukRHn1TnZP+wKoJ1gu4vGw== X-Received: by 2002:adf:c54b:: with SMTP id s11mr22399214wrf.349.1623151384676; Tue, 08 Jun 2021 04:23:04 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 02/26] configure: drop unused variables for xts Date: Tue, 8 Jun 2021 13:22:37 +0200 Message-Id: <20210608112301.402434-3-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x429.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" All XTS configuration uses qemu_private_xts. Drop other variables as they have only ever been used to generate the summary (which has since been moved to meson.build). Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 Reviewed-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- configure | 4 ---- 1 file changed, 4 deletions(-) diff --git a/configure b/configure index 8dcb9965b2..44c413e9b8 100755 --- a/configure +++ b/configure @@ -406,9 +406,7 @@ gtk=3D"auto" tls_priority=3D"NORMAL" gnutls=3D"$default_feature" nettle=3D"$default_feature" -nettle_xts=3D"no" gcrypt=3D"$default_feature" -gcrypt_xts=3D"no" qemu_private_xts=3D"yes" auth_pam=3D"$default_feature" vte=3D"$default_feature" @@ -2897,7 +2895,6 @@ int main(void) { } EOF if compile_prog "$nettle_cflags" "$nettle_libs" ; then - nettle_xts=3Dyes qemu_private_xts=3Dno fi fi @@ -2938,7 +2935,6 @@ int main(void) { } EOF if compile_prog "$gcrypt_cflags" "$gcrypt_libs" ; then - gcrypt_xts=3Dyes qemu_private_xts=3Dno fi elif test "$gcrypt" =3D "yes"; then --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151517; cv=none; d=zohomail.com; s=zohoarc; b=UPl0oj3rsAjRcI23SXKgwbIYa79ETdog3GC73MYA8vuvmXZo/hzJY7s7I8QU0Og4/rEB51v0f1t7lQ98i8n4dBcjAk6fGrastPDyxHajRiUhKF151eAR+QA9+hhwYLNDzEhssQLYpQgVHzjKBChmFE5OrmQQkiagon5UM+RIon8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151517; h=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=sCOhPBhifj1LhShqnVZ8abbpPO12ArNNNi5QZfCe5ks=; b=nUXWT7wLLGcSIkt7oGFuj8O7xugXsVfX3ODZTkhf31Q+WIFZJAqHkWwj8NaPBT0L/eTv8NRi47+2MVkv62vrGTfdbJooFs7sb85QCwKQIxj4+kXC+LLpypy0C8gwBT6izikN2vK5QwzggGlzqiqkGGzvNKhCwzT3buGf6CFvtVk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151517558557.1829925569773; Tue, 8 Jun 2021 04:25:17 -0700 (PDT) Received: from localhost ([::1]:34792 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZrA-0000vP-AQ for importer2@patchew.org; Tue, 08 Jun 2021 07:25:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43474) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZp7-0006Po-Vb for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:09 -0400 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]:41670) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp5-0007wI-O3 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:09 -0400 Received: by mail-wr1-x42c.google.com with SMTP id o3so2770901wri.8 for ; Tue, 08 Jun 2021 04:23:06 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=sCOhPBhifj1LhShqnVZ8abbpPO12ArNNNi5QZfCe5ks=; b=X7SUEQVhw4i46CLZu8WhFny4w1sKnHAtzPOPk7q3YsvdFXFdIOpPA8y3y5omXsR0Ch zyUt/J0SJHfMa9jl+WSw7V1mkm3n6ezzmEi3Cp9bbGiQRRHYcKYWFDoUQsiDeLdm9Pur Ks5JgEFlR5hoANv7qMdzq8Tzv8ws094CevlKy6iOE+UEIWZ1BaAoO6FJMQwbqi+Qc2EI JXnv+GpCvtnCX9F9jYuk+r9d8xaGbiZyZyHndm6HjrvlDkSR51w7/jj852/PN3RXy/cV 6eDCAJNrH4pLb8oHKF5M9nBEKZBFEhXzHZJxDFrzhNK2emazsTSrP6K/YDnhj7RdKiwU rGBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=sCOhPBhifj1LhShqnVZ8abbpPO12ArNNNi5QZfCe5ks=; b=Kg+fOJqDWaz+tnmNUyxjj3CcpQPK8VAior5+KdYzNoW0z9AbmBkFG7MNPMlE5y9XR+ 5GcmGk6I9qsDtJD7bXEJc0gSM0OLGDr0OO/hnV9K7XBty30TO/WR0dWUxK30bbGOX9nA e10WMKIqcGVdDrS1yTp2SpKksEevwZeuzKo16cbosSvvSDo1+oXROgwYVcyAfmurEwun DueL0PFQly1lBqDgR/y9zONI6VLVZCilSv2wn1IcQ6E7paZ40+JEAFueGGe0M/uOivYU guJoi1vh5uepkwpvm1OQ2JjA4j3cYPeop3vQT6TqZZVAtTRuUY4rWHKM6cUlf/Kb9Z18 ujoQ== X-Gm-Message-State: AOAM532LLOAobmsIIlDXRJvLqqzT9ZtvrVBywB5W4viHHaLwL59uNg4c 7ib1cZqbGgKXbTgdxh60Ga0sG1iFM+GNXg== X-Google-Smtp-Source: ABdhPJxpFQ/ag1vAQQDS9DLE08Hbi0P+vFkql7Sc+nIvHC7Q62kQjcr5gYXbjvtWWk1FJVDP5VrWDA== X-Received: by 2002:adf:b648:: with SMTP id i8mr15699191wre.425.1623151385498; Tue, 08 Jun 2021 04:23:05 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 03/26] configure, meson: convert crypto detection to meson Date: Tue, 8 Jun 2021 13:22:38 +0200 Message-Id: <20210608112301.402434-4-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42c; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x42c.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 Reviewed-by: Richard Henderson --- configure | 188 +++-------------------------------------- crypto/meson.build | 41 +++------ meson.build | 81 +++++++++++++----- meson_options.txt | 6 ++ tests/unit/meson.build | 6 +- 5 files changed, 90 insertions(+), 232 deletions(-) diff --git a/configure b/configure index 44c413e9b8..74c8ea8cf1 100755 --- a/configure +++ b/configure @@ -404,10 +404,9 @@ seccomp=3D"auto" glusterfs=3D"auto" gtk=3D"auto" tls_priority=3D"NORMAL" -gnutls=3D"$default_feature" -nettle=3D"$default_feature" -gcrypt=3D"$default_feature" -qemu_private_xts=3D"yes" +gnutls=3D"auto" +nettle=3D"auto" +gcrypt=3D"auto" auth_pam=3D"$default_feature" vte=3D"$default_feature" virglrenderer=3D"$default_feature" @@ -1372,17 +1371,17 @@ for opt do ;; --tls-priority=3D*) tls_priority=3D"$optarg" ;; - --disable-gnutls) gnutls=3D"no" + --disable-gnutls) gnutls=3D"disabled" ;; - --enable-gnutls) gnutls=3D"yes" + --enable-gnutls) gnutls=3D"enabled" ;; - --disable-nettle) nettle=3D"no" + --disable-nettle) nettle=3D"disabled" ;; - --enable-nettle) nettle=3D"yes" + --enable-nettle) nettle=3D"enabled" ;; - --disable-gcrypt) gcrypt=3D"no" + --disable-gcrypt) gcrypt=3D"disabled" ;; - --enable-gcrypt) gcrypt=3D"yes" + --enable-gcrypt) gcrypt=3D"enabled" ;; --disable-auth-pam) auth_pam=3D"no" ;; @@ -2800,156 +2799,6 @@ EOF fi fi =20 -########################################## -# GNUTLS probe - -if test "$gnutls" !=3D "no"; then - pass=3D"no" - if $pkg_config --exists "gnutls >=3D 3.5.18"; then - gnutls_cflags=3D$($pkg_config --cflags gnutls) - gnutls_libs=3D$($pkg_config --libs gnutls) - # Packaging for the static libraries is not always correct. - # At least ubuntu 18.04 ships only shared libraries. - write_c_skeleton - if compile_prog "" "$gnutls_libs" ; then - pass=3D"yes" - fi - fi - if test "$pass" =3D "no" && test "$gnutls" =3D "yes"; then - feature_not_found "gnutls" "Install gnutls devel >=3D 3.1.18" - else - gnutls=3D"$pass" - fi -fi - - -# If user didn't give a --disable/enable-gcrypt flag, -# then mark as disabled if user requested nettle -# explicitly -if test -z "$gcrypt" -then - if test "$nettle" =3D "yes" - then - gcrypt=3D"no" - fi -fi - -# If user didn't give a --disable/enable-nettle flag, -# then mark as disabled if user requested gcrypt -# explicitly -if test -z "$nettle" -then - if test "$gcrypt" =3D "yes" - then - nettle=3D"no" - fi -fi - -has_libgcrypt() { - if ! has "libgcrypt-config" - then - return 1 - fi - - if test -n "$cross_prefix" - then - host=3D$(libgcrypt-config --host) - if test "$host-" !=3D $cross_prefix - then - return 1 - fi - fi - - maj=3D`libgcrypt-config --version | awk -F . '{print $1}'` - min=3D`libgcrypt-config --version | awk -F . '{print $2}'` - - if test $maj !=3D 1 || test $min -lt 8 - then - return 1 - fi - - return 0 -} - - -if test "$nettle" !=3D "no"; then - pass=3D"no" - if $pkg_config --exists "nettle >=3D 3.4"; then - nettle_cflags=3D$($pkg_config --cflags nettle) - nettle_libs=3D$($pkg_config --libs nettle) - # Link test to make sure the given libraries work (e.g for static). - write_c_skeleton - if compile_prog "" "$nettle_libs" ; then - if test -z "$gcrypt"; then - gcrypt=3D"no" - fi - pass=3D"yes" - fi - fi - if test "$pass" =3D "yes" - then - cat > $TMPC << EOF -#include -int main(void) { - return 0; -} -EOF - if compile_prog "$nettle_cflags" "$nettle_libs" ; then - qemu_private_xts=3Dno - fi - fi - if test "$pass" =3D "no" && test "$nettle" =3D "yes"; then - feature_not_found "nettle" "Install nettle devel >=3D 2.7.1" - else - nettle=3D"$pass" - fi -fi - -if test "$gcrypt" !=3D "no"; then - pass=3D"no" - if has_libgcrypt; then - gcrypt_cflags=3D$(libgcrypt-config --cflags) - gcrypt_libs=3D$(libgcrypt-config --libs) - # Debian has removed -lgpg-error from libgcrypt-config - # as it "spreads unnecessary dependencies" which in - # turn breaks static builds... - if test "$static" =3D "yes" - then - gcrypt_libs=3D"$gcrypt_libs -lgpg-error" - fi - - # Link test to make sure the given libraries work (e.g for static). - write_c_skeleton - if compile_prog "" "$gcrypt_libs" ; then - pass=3D"yes" - fi - fi - if test "$pass" =3D "yes"; then - gcrypt=3D"yes" - cat > $TMPC << EOF -#include -int main(void) { - gcry_cipher_hd_t handle; - gcry_cipher_open(&handle, GCRY_CIPHER_AES, GCRY_CIPHER_MODE_XTS, 0); - return 0; -} -EOF - if compile_prog "$gcrypt_cflags" "$gcrypt_libs" ; then - qemu_private_xts=3Dno - fi - elif test "$gcrypt" =3D "yes"; then - feature_not_found "gcrypt" "Install gcrypt devel >=3D 1.5.0" - else - gcrypt=3D"no" - fi -fi - - -if test "$gcrypt" =3D "yes" && test "$nettle" =3D "yes" -then - error_exit "Only one of gcrypt & nettle can be enabled" -fi - ########################################## # libtasn1 - only for the TLS creds/session test suite =20 @@ -5703,24 +5552,6 @@ if test "$gdbus_codegen" !=3D "" ; then echo "GDBUS_CODEGEN=3D$gdbus_codegen" >> $config_host_mak fi echo "CONFIG_TLS_PRIORITY=3D\"$tls_priority\"" >> $config_host_mak -if test "$gnutls" =3D "yes" ; then - echo "CONFIG_GNUTLS=3Dy" >> $config_host_mak - echo "GNUTLS_CFLAGS=3D$gnutls_cflags" >> $config_host_mak - echo "GNUTLS_LIBS=3D$gnutls_libs" >> $config_host_mak -fi -if test "$gcrypt" =3D "yes" ; then - echo "CONFIG_GCRYPT=3Dy" >> $config_host_mak - echo "GCRYPT_CFLAGS=3D$gcrypt_cflags" >> $config_host_mak - echo "GCRYPT_LIBS=3D$gcrypt_libs" >> $config_host_mak -fi -if test "$nettle" =3D "yes" ; then - echo "CONFIG_NETTLE=3Dy" >> $config_host_mak - echo "NETTLE_CFLAGS=3D$nettle_cflags" >> $config_host_mak - echo "NETTLE_LIBS=3D$nettle_libs" >> $config_host_mak -fi -if test "$qemu_private_xts" =3D "yes" ; then - echo "CONFIG_QEMU_PRIVATE_XTS=3Dy" >> $config_host_mak -fi if test "$tasn1" =3D "yes" ; then echo "CONFIG_TASN1=3Dy" >> $config_host_mak fi @@ -6438,6 +6269,7 @@ if test "$skip_meson" =3D no; then -Dcurl=3D$curl -Dglusterfs=3D$glusterfs -Dbzip2=3D$bzip2 -Dlibiscs= i=3D$libiscsi \ -Dlibnfs=3D$libnfs -Diconv=3D$iconv -Dcurses=3D$curses -Dlibudev= =3D$libudev\ -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ + -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ -Dattr=3D$attr -Ddefault_devices=3D$default_devices \ -Ddocs=3D$docs -Dsphinx_build=3D$sphinx_build -Dinstall_blobs=3D$b= lobs \ diff --git a/crypto/meson.build b/crypto/meson.build index af7e80c6f6..7cbf1a6ba7 100644 --- a/crypto/meson.build +++ b/crypto/meson.build @@ -22,48 +22,31 @@ crypto_ss.add(files( 'tlssession.c', )) =20 -if 'CONFIG_NETTLE' in config_host - crypto_ss.add(files('hash-nettle.c', 'hmac-nettle.c', 'pbkdf-nettle.c')) -elif 'CONFIG_GCRYPT' in config_host - crypto_ss.add(files('hash-gcrypt.c', 'pbkdf-gcrypt.c')) - crypto_ss.add(files('hmac-gcrypt.c')) +if nettle.found() + crypto_ss.add(nettle, files('hash-nettle.c', 'hmac-nettle.c', 'pbkdf-net= tle.c')) +elif gcrypt.found() + crypto_ss.add(gcrypt, files('hash-gcrypt.c', 'hmac-gcrypt.c', 'pbkdf-gcr= ypt.c')) else crypto_ss.add(files('hash-glib.c', 'hmac-glib.c', 'pbkdf-stub.c')) endif +if xts =3D=3D 'private' + crypto_ss.add(files('xts.c')) +endif =20 crypto_ss.add(when: 'CONFIG_SECRET_KEYRING', if_true: files('secret_keyrin= g.c')) -crypto_ss.add(when: 'CONFIG_QEMU_PRIVATE_XTS', if_true: files('xts.c')) crypto_ss.add(when: 'CONFIG_AF_ALG', if_true: files('afalg.c', 'cipher-afa= lg.c', 'hash-afalg.c')) -crypto_ss.add(when: 'CONFIG_GNUTLS', if_true: files('tls-cipher-suites.c')) - -if 'CONFIG_NETTLE' in config_host - crypto_ss.add(nettle) -elif 'CONFIG_GCRYPT' in config_host - crypto_ss.add(gcrypt) -endif - -if 'CONFIG_GNUTLS' in config_host - crypto_ss.add(gnutls) -endif - +crypto_ss.add(when: gnutls, if_true: files('tls-cipher-suites.c')) =20 util_ss.add(files('aes.c')) util_ss.add(files('init.c')) =20 -if 'CONFIG_GCRYPT' in config_host - util_ss.add(files('random-gcrypt.c')) -elif 'CONFIG_GNUTLS' in config_host - util_ss.add(files('random-gnutls.c')) +if gcrypt.found() + util_ss.add(gcrypt, files('random-gcrypt.c')) +elif gnutls.found() + util_ss.add(gnutls, files('random-gnutls.c')) elif 'CONFIG_RNG_NONE' in config_host util_ss.add(files('random-none.c')) else util_ss.add(files('random-platform.c')) endif =20 -if 'CONFIG_GCRYPT' in config_host - util_ss.add(gcrypt) -endif - -if 'CONFIG_GNUTLS' in config_host - util_ss.add(gnutls) -endif diff --git a/meson.build b/meson.build index 43e9c4590e..b374fa92cd 100644 --- a/meson.build +++ b/meson.build @@ -320,21 +320,6 @@ urcubp =3D not_found if 'CONFIG_TRACE_UST' in config_host urcubp =3D declare_dependency(link_args: config_host['URCU_BP_LIBS'].spl= it()) endif -gcrypt =3D not_found -if 'CONFIG_GCRYPT' in config_host - gcrypt =3D declare_dependency(compile_args: config_host['GCRYPT_CFLAGS']= .split(), - link_args: config_host['GCRYPT_LIBS'].split(= )) -endif -nettle =3D not_found -if 'CONFIG_NETTLE' in config_host - nettle =3D declare_dependency(compile_args: config_host['NETTLE_CFLAGS']= .split(), - link_args: config_host['NETTLE_LIBS'].split(= )) -endif -gnutls =3D not_found -if 'CONFIG_GNUTLS' in config_host - gnutls =3D declare_dependency(compile_args: config_host['GNUTLS_CFLAGS']= .split(), - link_args: config_host['GNUTLS_LIBS'].split(= )) -endif pixman =3D not_found if have_system or have_tools pixman =3D dependency('pixman-1', required: have_system, version:'>=3D0.= 21.8', @@ -829,6 +814,54 @@ if 'CONFIG_OPENGL' in config_host link_args: config_host['OPENGL_LIBS'].split(= )) endif =20 +gnutls =3D not_found +if not get_option('gnutls').auto() or have_system + gnutls =3D dependency('gnutls', version: '>=3D3.5.18', + method: 'pkg-config', + required: get_option('gnutls'), + kwargs: static_kwargs) +endif + +# Nettle has priority over gcrypt +gcrypt =3D not_found +nettle =3D not_found +xts =3D 'private' +if get_option('nettle').enabled() and get_option('gcrypt').enabled() + error('Only one of gcrypt & nettle can be enabled') +elif (not get_option('nettle').auto() or have_system) and not get_option('= gcrypt').enabled() + nettle =3D dependency('nettle', version: '>=3D3.4', + method: 'pkg-config', + required: get_option('nettle'), + kwargs: static_kwargs) + if cc.has_header('nettle/xts.h', dependencies: nettle) + xts =3D 'nettle' + endif +endif +if (not get_option('gcrypt').auto() or have_system) and not nettle.found() + gcrypt =3D dependency('libgcrypt', version: '>=3D1.5', + method: 'config-tool', + required: get_option('gcrypt'), + kwargs: static_kwargs) + if cc.compiles(''' + #include + int main(void) { + gcry_cipher_hd_t handle; + gcry_cipher_open(&handle, GCRY_CIPHER_AES, GCRY_CIPHER_MODE_XTS, 0); + return 0; + } + ''', dependencies: gcrypt) + xts =3D 'gcrypt' + endif + # Debian has removed -lgpg-error from libgcrypt-config + # as it "spreads unnecessary dependencies" which in + # turn breaks static builds... + if gcrypt.found() and enable_static + gcrypt =3D declare_dependency(dependencies: [ + gcrypt, + cc.find_library('gpg-error', required: true, kwargs: static_kwargs)]) + endif +endif + gtk =3D not_found gtkx11 =3D not_found if not get_option('gtk').auto() or (have_system and not cocoa.found()) @@ -1168,6 +1201,10 @@ config_host_data.set('CONFIG_VIRTFS', have_virtfs) config_host_data.set('CONFIG_XKBCOMMON', xkbcommon.found()) config_host_data.set('CONFIG_KEYUTILS', keyutils.found()) config_host_data.set('CONFIG_GETTID', has_gettid) +config_host_data.set('CONFIG_GNUTLS', gnutls.found()) +config_host_data.set('CONFIG_GCRYPT', gcrypt.found()) +config_host_data.set('CONFIG_NETTLE', nettle.found()) +config_host_data.set('CONFIG_QEMU_PRIVATE_XTS', xts =3D=3D 'private') config_host_data.set('CONFIG_MALLOC_TRIM', has_malloc_trim) config_host_data.set('CONFIG_STATX', has_statx) config_host_data.set('CONFIG_ZSTD', zstd.found()) @@ -2673,16 +2710,16 @@ summary(summary_info, bool_yn: true, section: 'Bloc= k layer support') # Crypto summary_info =3D {} summary_info +=3D {'TLS priority': config_host['CONFIG_TLS_PRIORITY']} -summary_info +=3D {'GNUTLS support': config_host.has_key('CONFIG_GNUTLS= ')} +summary_info +=3D {'GNUTLS support': gnutls.found()} # TODO: add back version -summary_info +=3D {'libgcrypt': config_host.has_key('CONFIG_GCRYPT= ')} -if config_host.has_key('CONFIG_GCRYPT') - summary_info +=3D {' XTS': not config_host.has_key('CONFIG= _QEMU_PRIVATE_XTS')} +summary_info +=3D {'libgcrypt': gcrypt.found()} +if gcrypt.found() + summary_info +=3D {' XTS': xts !=3D 'private'} endif # TODO: add back version -summary_info +=3D {'nettle': config_host.has_key('CONFIG_NETTLE= ')} -if config_host.has_key('CONFIG_NETTLE') - summary_info +=3D {' XTS': not config_host.has_key('CONFIG= _QEMU_PRIVATE_XTS')} +summary_info +=3D {'nettle': nettle.found()} +if nettle.found() + summary_info +=3D {' XTS': xts !=3D 'private'} endif summary_info +=3D {'crypto afalg': config_host.has_key('CONFIG_AF_ALG= ')} summary_info +=3D {'rng-none': config_host.has_key('CONFIG_RNG_NO= NE')} diff --git a/meson_options.txt b/meson_options.txt index 3d304cac96..343ffffb7c 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -76,6 +76,12 @@ option('iconv', type : 'feature', value : 'auto', description: 'Font glyph conversion support') option('curses', type : 'feature', value : 'auto', description: 'curses UI') +option('gnutls', type : 'feature', value : 'auto', + description: 'GNUTLS cryptography support') +option('nettle', type : 'feature', value : 'auto', + description: 'nettle cryptography support') +option('gcrypt', type : 'feature', value : 'auto', + description: 'libgcrypt cryptography support') option('libudev', type : 'feature', value : 'auto', description: 'Use libudev to enumerate host devices') option('lzfse', type : 'feature', value : 'auto', diff --git a/tests/unit/meson.build b/tests/unit/meson.build index b3bc2109da..fcf6ed2ef5 100644 --- a/tests/unit/meson.build +++ b/tests/unit/meson.build @@ -83,7 +83,7 @@ if have_block 'test-crypto-afsplit': [io], 'test-crypto-block': [io], } - if 'CONFIG_GNUTLS' in config_host and \ + if gnutls.found() and \ 'CONFIG_TASN1' in config_host and \ 'CONFIG_POSIX' in config_host tests +=3D { @@ -97,7 +97,7 @@ if have_block if 'CONFIG_AUTH_PAM' in config_host tests +=3D {'test-authz-pam': [authz]} endif - if 'CONFIG_QEMU_PRIVATE_XTS' in config_host + if xts =3D=3D 'private' tests +=3D {'test-crypto-xts': [crypto, io]} endif if 'CONFIG_POSIX' in config_host @@ -106,7 +106,7 @@ if have_block if 'CONFIG_REPLICATION' in config_host tests +=3D {'test-replication': [testblock]} endif - if 'CONFIG_NETTLE' in config_host or 'CONFIG_GCRYPT' in config_host + if nettle.found() or gcrypt.found() tests +=3D {'test-crypto-pbkdf': [io]} endif if 'CONFIG_EPOLL_CREATE1' in config_host --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151695; cv=none; d=zohomail.com; s=zohoarc; b=GMpyX7r/TlIejamUYv/J+NRoCRGOtlU4EuoBZc8U4Wt9K10ojwxIj3qXC7kxuYm5vMGIBnLtS8Pl7CRWTdWvDMtGp5IBwVaY/69CShh0PQydtUhIuWHBDfsZ2uxl7tLU6LvsH+0GqgzhfRpAq3NtA83ZAlRb5qIXXkP42g55bsw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151695; h=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=2JJ8uamBQ1yz1ujJvvj1Ccn+AIwyN4th7VBQ4mGZvZQ=; b=jLSRymMUSvh6vt2YSFx72nmpZqtNry9GkTZjy7ndCpxWwoRmg3Jbkw0PogTiUwnmfIwa51GG7qhGyFTjADKcG1PpyJpuCMRnXAsuAEW1fblWNweb4wFWNR/Cd+59c6Ao56F2exN2cnnfAhqr3sIwwa2vMYYQOOaQvHj4Fd9feyU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151695902525.2515308405116; Tue, 8 Jun 2021 04:28:15 -0700 (PDT) Received: from localhost ([::1]:42738 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZu2-0006Et-Q1 for importer2@patchew.org; Tue, 08 Jun 2021 07:28:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43488) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZp8-0006RF-GQ for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:10 -0400 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]:45709) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp5-0007wQ-PN for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:10 -0400 Received: by mail-wr1-x433.google.com with SMTP id z8so21121528wrp.12 for ; Tue, 08 Jun 2021 04:23:07 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=2JJ8uamBQ1yz1ujJvvj1Ccn+AIwyN4th7VBQ4mGZvZQ=; b=JTenFFlMYwG6RJIkc/4vnkhoF2ImDtCAUVJC7OYjOeFe6PFes0KCfrK/rbfOFgzLbe Ij7lutbFCwwiTZcNBdQwY1+t0Lun8WU37p9XQehtu8As9hIi7EbYQVpUKP7i6ZzUMg/2 0sACTevelR6UDI3tj6fjAmS1tsLAfVg0ZgCTnOQAdf28rTS5yXXh829akfloBSvg2kh9 oRF6Jssrmq4tzZV+XekszUO9nqEPZp4Q62eE7gklDN7851uOA/AJHdj+7PNcbIf0IAky niE+2EE+oZxpgWhfWkBRXthEh+5RIHRabgVWZwgcQmFTjlwv+TVMGt3Whc+sVnn6m47I 6PwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=2JJ8uamBQ1yz1ujJvvj1Ccn+AIwyN4th7VBQ4mGZvZQ=; b=GyOMkHfZtoviZasVst6a18PFqJFeghwunSO3OOCoCEVibQVlg3icI1TEWEs/9gUw4N 5k+n0rpaDizzq7+jbxLTFLoWvII5NFfVeG6Oq3eUQIyKddhHzaEqztegJKvCTzb30b3N Ha9vxepuZBHKARwR1PeSXHOpuUfnubC7doDdFDe7Hg7CQwFmrchwjksVyG3BuZhMMmt8 V0k2GjPzYZ0GI9V6J1iDC0ysDQx9OOnuvQXT1vBS46bPM/gw0F/xTO7Mq2ok3TGxCj04 inz2mMoo5C514QdR/i5vvSU5FRNyDFu9Mkb26kIZ7nofU+iKlmsaUUNrbDUR5Lg8IoWh 10pw== X-Gm-Message-State: AOAM532cdDkeQXQ95KaIqgrn2sBSxMLFI5D87PXAY1KQgWZ/4O+Un9LB rp+2qMcX95D/4kD0tu8TXlzJYvNM3qxnHA== X-Google-Smtp-Source: ABdhPJzETgomTHK7Y3gHkf7QL+GJ6MZJa8IQlXQ6wf0BUtKQnV42RcXUr9n0spv8mMTqoMjuURf2Kw== X-Received: by 2002:adf:ee46:: with SMTP id w6mr22624927wro.345.1623151386360; Tue, 08 Jun 2021 04:23:06 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 04/26] configure, meson: convert libtasn1 detection to meson Date: Tue, 8 Jun 2021 13:22:39 +0200 Message-Id: <20210608112301.402434-5-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::433; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x433.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Make it depend on gnutls too, since it is only used as part of gnutls tests. Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 Reviewed-by: Richard Henderson --- configure | 19 ------------------- meson.build | 9 +++++---- tests/unit/meson.build | 2 +- 3 files changed, 6 insertions(+), 24 deletions(-) diff --git a/configure b/configure index 74c8ea8cf1..ebe327b592 100755 --- a/configure +++ b/configure @@ -2799,20 +2799,6 @@ EOF fi fi =20 -########################################## -# libtasn1 - only for the TLS creds/session test suite - -tasn1=3Dyes -tasn1_cflags=3D"" -tasn1_libs=3D"" -if $pkg_config --exists "libtasn1"; then - tasn1_cflags=3D$($pkg_config --cflags libtasn1) - tasn1_libs=3D$($pkg_config --libs libtasn1) -else - tasn1=3Dno -fi - - ########################################## # PAM probe =20 @@ -5552,9 +5538,6 @@ if test "$gdbus_codegen" !=3D "" ; then echo "GDBUS_CODEGEN=3D$gdbus_codegen" >> $config_host_mak fi echo "CONFIG_TLS_PRIORITY=3D\"$tls_priority\"" >> $config_host_mak -if test "$tasn1" =3D "yes" ; then - echo "CONFIG_TASN1=3Dy" >> $config_host_mak -fi if test "$auth_pam" =3D "yes" ; then echo "CONFIG_AUTH_PAM=3Dy" >> $config_host_mak fi @@ -6016,8 +5999,6 @@ echo "LD_I386_EMULATION=3D$ld_i386_emulation" >> $con= fig_host_mak echo "EXESUF=3D$EXESUF" >> $config_host_mak echo "HOST_DSOSUF=3D$HOST_DSOSUF" >> $config_host_mak echo "LIBS_QGA=3D$libs_qga" >> $config_host_mak -echo "TASN1_LIBS=3D$tasn1_libs" >> $config_host_mak -echo "TASN1_CFLAGS=3D$tasn1_cflags" >> $config_host_mak if test "$gcov" =3D "yes" ; then echo "CONFIG_GCOV=3Dy" >> $config_host_mak fi diff --git a/meson.build b/meson.build index b374fa92cd..305b750ced 100644 --- a/meson.build +++ b/meson.build @@ -985,9 +985,10 @@ if 'CONFIG_LIBDAXCTL' in config_host libdaxctl =3D declare_dependency(link_args: config_host['LIBDAXCTL_LIBS'= ].split()) endif tasn1 =3D not_found -if 'CONFIG_TASN1' in config_host - tasn1 =3D declare_dependency(compile_args: config_host['TASN1_CFLAGS'].s= plit(), - link_args: config_host['TASN1_LIBS'].split()) +if gnutls.found() + tasn1 =3D dependency('libtasn1', + method: 'pkg-config', + kwargs: static_kwargs) endif keyutils =3D dependency('libkeyutils', required: false, method: 'pkg-config', kwargs: static_kwargs) @@ -2741,7 +2742,7 @@ summary_info +=3D {'pixman': pixman.found(= )} summary_info +=3D {'VTE support': config_host.has_key('CONFIG_VTE')} # TODO: add back version summary_info +=3D {'slirp support': slirp_opt =3D=3D 'disabled' ? fals= e : slirp_opt} -summary_info +=3D {'libtasn1': config_host.has_key('CONFIG_TASN1'= )} +summary_info +=3D {'libtasn1': tasn1.found()} summary_info +=3D {'PAM': config_host.has_key('CONFIG_AUTH_P= AM')} summary_info +=3D {'iconv support': iconv.found()} summary_info +=3D {'curses support': curses.found()} diff --git a/tests/unit/meson.build b/tests/unit/meson.build index fcf6ed2ef5..4c1ebc06ac 100644 --- a/tests/unit/meson.build +++ b/tests/unit/meson.build @@ -84,7 +84,7 @@ if have_block 'test-crypto-block': [io], } if gnutls.found() and \ - 'CONFIG_TASN1' in config_host and \ + tasn1.found() and \ 'CONFIG_POSIX' in config_host tests +=3D { 'test-crypto-tlscredsx509': ['crypto-tls-x509-helpers.c', 'pkix_asn1= _tab.c', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151708; cv=none; d=zohomail.com; s=zohoarc; b=eqTirQwRL16cF0OtdSuC0y2wkb+b1qorD9F9rFs7OHN9bwNx83EcVHwRYOhEhpxF3jlxUmVWjOt7yKgbEUP6H4zDLsWSzMCOtB2V63sTXhM39c5LQxQeoVkdebGukWLp5k5//TtjA1johZduaQHNfw7JrFkIv6/Nbt7v68dEjS0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151708; h=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=57UsR0DTUAS02KZLVE5DyliFV/++/zkdaZfMUJMA7R8=; b=KznnKzkBtoWbfcpDbzdgLML3t+/eDl15EYGI+OuP6iDOkEjJNvYxqis9A2iLob3Rwhp3TKQR+CucT7nVT3NKfV5TnXdLIyVbRlpkLvFoOjdUYH2oit2VEBZjOWOOKS5XNMgGpIdnfVy0psutZ4uqB6t4GtFr/z7WzVSOUgo+PVA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 162315170851129.78685706830413; Tue, 8 Jun 2021 04:28:28 -0700 (PDT) Received: from localhost ([::1]:43402 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZuF-0006gh-CX for importer2@patchew.org; Tue, 08 Jun 2021 07:28:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43510) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZp9-0006Sv-OI for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:11 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:45700) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp6-0007wZ-ND for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:10 -0400 Received: by mail-wr1-x429.google.com with SMTP id z8so21121587wrp.12 for ; Tue, 08 Jun 2021 04:23:08 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=57UsR0DTUAS02KZLVE5DyliFV/++/zkdaZfMUJMA7R8=; b=JeNiydQ6U2wUff40ScujQepEKqTwHBBFdVPeAMtXpbYIG2cdJ9HXhTZnnRDuJMTTff uzRzp+PwiAmkGKOtRqrDTy+CLTK15PqTi+CBgP6Sa/8HTlfot5V0kEGsjsq5D7zv6aVt uSYC9PFim3LwvHWXBY9NTGyQImywzPa6Xm4SCgZwWxh9XuSA0NLYQJHhfq4DxpjS1KY+ UDSssND966sDFYf8DMSz1mH/+UAT0UVLBJ+HN7div/f1Db3RqdH7xjxKqU5GKgXaaj6w W0UNaPm5dLimb99zWv6MfZjzL+4QYGGsfkksoQtQ+AkXnrj1/9rNtpXWvK7zNakAXArb dYaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=57UsR0DTUAS02KZLVE5DyliFV/++/zkdaZfMUJMA7R8=; b=IOOAjog56PIYN6qKukX7qio0rjYshoNlYl9Ja14bP1qSwmV026ILdRVu4Ly5/iwyNH puhgJmV8B17XRdhfWftmTrXaW3SG/BFf+fW543qWi1JRkOT82otap2z14SyhDOi8B/nQ 9VRQBdw4LQJhGpgDh086KSA6hZYEsNaQVJGergWP6KmYXjX3yPIV0NxIm93GBTZNO3RF M/HixEdkSAmBTSVEM9a0Q6K60xNeANAEopupVrEZThwgzsEay3HuI8jCy3FPYHRiadSM CkU+FLguPc9EWBy0cCe68buPR976h6O/DbaPdcFhXfRCiUsiCkdNVMU2/E+4aSnMzhvV 61dw== X-Gm-Message-State: AOAM533oHiMNnOJXTNGctFLicnL8K9pn26FQTRDCLGrRQ5LlnKomBaj3 uekhE8rjMqCTI2LEUFbmkbYZ/lhYkqxEFw== X-Google-Smtp-Source: ABdhPJzYhRROQjWjIWp2Pp5zUMbuF7L24cD0FqgYV86N3EwwCRX1LayX4SBgGQumjwTFXv92PJWNoQ== X-Received: by 2002:adf:e4cf:: with SMTP id v15mr22227553wrm.162.1623151387487; Tue, 08 Jun 2021 04:23:07 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 05/26] configure, meson: convert pam detection to meson Date: Tue, 8 Jun 2021 13:22:40 +0200 Message-Id: <20210608112301.402434-6-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x429.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- authz/meson.build | 2 +- configure | 38 ++++---------------------------------- meson.build | 30 +++++++++++++++++++++++++----- meson_options.txt | 2 ++ tests/unit/meson.build | 2 +- 5 files changed, 33 insertions(+), 41 deletions(-) diff --git a/authz/meson.build b/authz/meson.build index 88fa7769cb..42a1ec0ff6 100644 --- a/authz/meson.build +++ b/authz/meson.build @@ -6,4 +6,4 @@ authz_ss.add(files( 'simple.c', )) =20 -authz_ss.add(when: ['CONFIG_AUTH_PAM', pam], if_true: files('pamacct.c')) +authz_ss.add(when: pam, if_true: files('pamacct.c')) diff --git a/configure b/configure index ebe327b592..d3c2e8ccaf 100755 --- a/configure +++ b/configure @@ -407,7 +407,7 @@ tls_priority=3D"NORMAL" gnutls=3D"auto" nettle=3D"auto" gcrypt=3D"auto" -auth_pam=3D"$default_feature" +auth_pam=3D"auto" vte=3D"$default_feature" virglrenderer=3D"$default_feature" tpm=3D"$default_feature" @@ -1383,9 +1383,9 @@ for opt do ;; --enable-gcrypt) gcrypt=3D"enabled" ;; - --disable-auth-pam) auth_pam=3D"no" + --disable-auth-pam) auth_pam=3D"disabled" ;; - --enable-auth-pam) auth_pam=3D"yes" + --enable-auth-pam) auth_pam=3D"enabled" ;; --enable-rdma) rdma=3D"yes" ;; @@ -2799,33 +2799,6 @@ EOF fi fi =20 -########################################## -# PAM probe - -if test "$auth_pam" !=3D "no"; then - cat > $TMPC < -#include -int main(void) { - const char *service_name =3D "qemu"; - const char *user =3D "frank"; - const struct pam_conv pam_conv =3D { 0 }; - pam_handle_t *pamh =3D NULL; - pam_start(service_name, user, &pam_conv, &pamh); - return 0; -} -EOF - if compile_prog "" "-lpam" ; then - auth_pam=3Dyes - else - if test "$auth_pam" =3D "yes"; then - feature_not_found "PAM" "Install PAM development package" - else - auth_pam=3Dno - fi - fi -fi - ########################################## # VTE probe =20 @@ -5538,9 +5511,6 @@ if test "$gdbus_codegen" !=3D "" ; then echo "GDBUS_CODEGEN=3D$gdbus_codegen" >> $config_host_mak fi echo "CONFIG_TLS_PRIORITY=3D\"$tls_priority\"" >> $config_host_mak -if test "$auth_pam" =3D "yes" ; then - echo "CONFIG_AUTH_PAM=3Dy" >> $config_host_mak -fi if test "$have_broken_size_max" =3D "yes" ; then echo "HAVE_BROKEN_SIZE_MAX=3Dy" >> $config_host_mak fi @@ -6250,7 +6220,7 @@ if test "$skip_meson" =3D no; then -Dcurl=3D$curl -Dglusterfs=3D$glusterfs -Dbzip2=3D$bzip2 -Dlibiscs= i=3D$libiscsi \ -Dlibnfs=3D$libnfs -Diconv=3D$iconv -Dcurses=3D$curses -Dlibudev= =3D$libudev\ -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ - -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt \ + -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt -Dauth_pa= m=3D$auth_pam \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ -Dattr=3D$attr -Ddefault_devices=3D$default_devices \ -Ddocs=3D$docs -Dsphinx_build=3D$sphinx_build -Dinstall_blobs=3D$b= lobs \ diff --git a/meson.build b/meson.build index 305b750ced..0d4b6fff16 100644 --- a/meson.build +++ b/meson.build @@ -325,10 +325,6 @@ if have_system or have_tools pixman =3D dependency('pixman-1', required: have_system, version:'>=3D0.= 21.8', method: 'pkg-config', kwargs: static_kwargs) endif -pam =3D not_found -if 'CONFIG_AUTH_PAM' in config_host - pam =3D cc.find_library('pam') -endif libaio =3D cc.find_library('aio', required: false) zlib =3D dependency('zlib', required: true, kwargs: static_kwargs) linux_io_uring =3D not_found @@ -907,6 +903,30 @@ if get_option('vnc').enabled() endif endif =20 +pam =3D not_found +if not get_option('auth_pam').auto() or have_system + pam =3D cc.find_library('pam', has_headers: ['security/pam_appl.h'], + required: get_option('auth_pam'), + kwargs: static_kwargs) +endif +if pam.found() and not cc.links(''' + #include + int main(void) { + const char *service_name =3D "qemu"; + const char *user =3D "frank"; + const struct pam_conv pam_conv =3D { 0 }; + pam_handle_t *pamh =3D NULL; + pam_start(service_name, user, &pam_conv, &pamh); + return 0; + }''', dependencies: pam) + pam =3D not_found + if get_option('auth_pam').enabled() + error('could not link libpam') + else + warning('could not link libpam, disabling') + endif +endif + snappy =3D not_found if not get_option('snappy').auto() or have_system snappy =3D cc.find_library('snappy', has_headers: ['snappy-c.h'], @@ -2743,7 +2763,7 @@ summary_info +=3D {'VTE support': config_host.h= as_key('CONFIG_VTE')} # TODO: add back version summary_info +=3D {'slirp support': slirp_opt =3D=3D 'disabled' ? fals= e : slirp_opt} summary_info +=3D {'libtasn1': tasn1.found()} -summary_info +=3D {'PAM': config_host.has_key('CONFIG_AUTH_P= AM')} +summary_info +=3D {'PAM': pam.found()} summary_info +=3D {'iconv support': iconv.found()} summary_info +=3D {'curses support': curses.found()} # TODO: add back version diff --git a/meson_options.txt b/meson_options.txt index 343ffffb7c..ac6e90da07 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -52,6 +52,8 @@ option('multiprocess', type: 'feature', value: 'auto', =20 option('attr', type : 'feature', value : 'auto', description: 'attr/xattr support') +option('auth_pam', type : 'feature', value : 'auto', + description: 'PAM access control') option('brlapi', type : 'feature', value : 'auto', description: 'brlapi character device driver') option('bzip2', type : 'feature', value : 'auto', diff --git a/tests/unit/meson.build b/tests/unit/meson.build index 4c1ebc06ac..3e0504dd21 100644 --- a/tests/unit/meson.build +++ b/tests/unit/meson.build @@ -94,7 +94,7 @@ if have_block 'test-io-channel-tls': ['io-channel-helpers.c', 'crypto-tls-x509-hel= pers.c', 'pkix_asn1_tab.c', tasn1, io, crypto, gnutls]} endif - if 'CONFIG_AUTH_PAM' in config_host + if pam.found() tests +=3D {'test-authz-pam': [authz]} endif if xts =3D=3D 'private' --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151831; cv=none; d=zohomail.com; s=zohoarc; b=O+0f6daWNYLnAIA9xFI5Z91ofUYOMl6RdTf3LuDS533kXEhoNnFlWfWwOeDWWd9CeR1FJRVEAFnnrhVXqoaOmKenjQLw1YVd+YtL1WZHneTxA9PQUgOEKpnOf02nSE1ve44iblejIHMbjI4/FhNDHMlOB/lp97rcc4g29yBfipM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151831; h=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=ryYpyCa0TSy+bqr+nzscGtPe1ekDpgp26HoVE89U+pY=; b=dGFs0RwDwRh24BCq4IVMIQul1y7R59m0zX6jhkrbBPHfWWXJIWXy+rq6rZlCFZx1hFvkQT0eHk7Qp7Kn+RDAlGQchcidND0q4IDuGGPHKwkuEElZHhlPiGxvZV/2GWyZlPG3dqy4+N4ji+5MLUrLyy2ycPbxsWZz/xqSXZ/ZuKA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151831899278.7284314984928; Tue, 8 Jun 2021 04:30:31 -0700 (PDT) Received: from localhost ([::1]:51310 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZwE-0003S5-Q2 for importer2@patchew.org; Tue, 08 Jun 2021 07:30:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43514) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZp9-0006T4-P0 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:11 -0400 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]:44951) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp7-0007yb-Fa for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:11 -0400 Received: by mail-wr1-x433.google.com with SMTP id f2so21118531wri.11 for ; Tue, 08 Jun 2021 04:23:09 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.07 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ryYpyCa0TSy+bqr+nzscGtPe1ekDpgp26HoVE89U+pY=; b=rcP+1Fmo8QBpva58NtbWPYEPlNs7ewvf4xIC9Oq3T/CioghrZWC5y+ZPeMtik6tXb7 /gh0HoqBaO+UGzDH+z6TToh458R0vj8mruiJbbqWsS7buge+LzfNLwVM6Fc0MF94wUak rVKVM0oRtlRgPWWMjA1EQXkORPdjISsJILEVu9a4FuRe56MscV78PHU0W3kR3mo4VFXo lNzgfrbgQYA077FKhRnIv7jsyn6YcCjCN8KuLCg+KvWlDj8kYRKjuKRH25mzAWN/ep7P ZfeC2MRzwXVfHcKcczo7ayDkoEnY3dFIdXwfVoGdckDX9lTFicm/pTas2XBIFJTPu/dH eIRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=ryYpyCa0TSy+bqr+nzscGtPe1ekDpgp26HoVE89U+pY=; b=cMGQ/Hk/xAYrmyu/nwHii4zHhenrfi91yCynBFf1b1K0J+b1wq3VvlSvPDJ2uPLoFm T6OZmQFKJ6T9/AIzszkv96CqmAjbwrsZpU/AJjAgZZJHwG4Y/aHA5bIKBI0vFv4wyWsO l/vFb9wQYlXpO5FXrLThmCrs5BGcORzC5+be/jfyeAGD3ufAzWHq3DWlqVrZK7z618Js qbtgQ8+hyL5r2UT5z7Y3DDHzV4Xp4Wp4wBrdTj+bSoM0jdRxz9lmNuGgqt6PxURkd5OQ 3AUiud/Np26DmY3l8TceSdUVnWKkq+W/QPVU2VFVq/R5pQJqcNUeCFPU7YnbWC7JYEth JDjg== X-Gm-Message-State: AOAM531RZGDsF+/rRE/8vhODsCTVdazLurwdcdZDk0/aqNCmfVjTHN4n +EYJ0BSo0Vx21cYonwMU8k4/KSp36G6dfQ== X-Google-Smtp-Source: ABdhPJyfiVGbDpmG/pY0X+Lj1LzLr7+FvNN2T8ScD/oifo2bDo6UY0HoMkPMdj66VRQ+BDMkOV8gIg== X-Received: by 2002:a05:6000:1542:: with SMTP id 2mr22237625wry.4.1623151388282; Tue, 08 Jun 2021 04:23:08 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 06/26] configure, meson: convert libusb detection to meson Date: Tue, 8 Jun 2021 13:22:41 +0200 Message-Id: <20210608112301.402434-7-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::433; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x433.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini --- configure | 27 ++++----------------------- hw/usb/meson.build | 2 +- meson.build | 11 +++++++---- meson_options.txt | 2 ++ 4 files changed, 14 insertions(+), 28 deletions(-) diff --git a/configure b/configure index d3c2e8ccaf..651273c023 100755 --- a/configure +++ b/configure @@ -374,7 +374,7 @@ spice_protocol=3D"auto" rbd=3D"auto" smartcard=3D"$default_feature" u2f=3D"auto" -libusb=3D"$default_feature" +libusb=3D"auto" usb_redir=3D"$default_feature" opengl=3D"$default_feature" cpuid_h=3D"no" @@ -1285,9 +1285,9 @@ for opt do ;; --enable-u2f) u2f=3D"enabled" ;; - --disable-libusb) libusb=3D"no" + --disable-libusb) libusb=3D"disabled" ;; - --enable-libusb) libusb=3D"yes" + --enable-libusb) libusb=3D"enabled" ;; --disable-usb-redir) usb_redir=3D"no" ;; @@ -3994,20 +3994,6 @@ if test "$smartcard" !=3D "no"; then fi fi =20 -# check for libusb -if test "$libusb" !=3D "no" ; then - if $pkg_config --atleast-version=3D1.0.13 libusb-1.0; then - libusb=3D"yes" - libusb_cflags=3D$($pkg_config --cflags libusb-1.0) - libusb_libs=3D$($pkg_config --libs libusb-1.0) - else - if test "$libusb" =3D "yes"; then - feature_not_found "libusb" "Install libusb devel >=3D 1.0.13" - fi - libusb=3D"no" - fi -fi - # check for usbredirparser for usb network redirection support if test "$usb_redir" !=3D "no" ; then if $pkg_config --atleast-version=3D0.6 libusbredirparser-0.5; then @@ -5626,12 +5612,6 @@ if test "$smartcard" =3D "yes" ; then echo "SMARTCARD_LIBS=3D$libcacard_libs" >> $config_host_mak fi =20 -if test "$libusb" =3D "yes" ; then - echo "CONFIG_USB_LIBUSB=3Dy" >> $config_host_mak - echo "LIBUSB_CFLAGS=3D$libusb_cflags" >> $config_host_mak - echo "LIBUSB_LIBS=3D$libusb_libs" >> $config_host_mak -fi - if test "$usb_redir" =3D "yes" ; then echo "CONFIG_USB_REDIR=3Dy" >> $config_host_mak echo "USB_REDIR_CFLAGS=3D$usb_redir_cflags" >> $config_host_mak @@ -6214,6 +6194,7 @@ if test "$skip_meson" =3D no; then -Dkvm=3D$kvm -Dhax=3D$hax -Dwhpx=3D$whpx -Dhvf=3D$hvf -Dnvmm=3D$nv= mm \ -Dxen=3D$xen -Dxen_pci_passthrough=3D$xen_pci_passthrough -Dtcg=3D= $tcg \ -Dcocoa=3D$cocoa -Dgtk=3D$gtk -Dmpath=3D$mpath -Dsdl=3D$sdl -Dsdl_= image=3D$sdl_image \ + -Dlibusb=3D$libusb \ -Dvnc=3D$vnc -Dvnc_sasl=3D$vnc_sasl -Dvnc_jpeg=3D$vnc_jpeg -Dvnc_p= ng=3D$vnc_png \ -Dgettext=3D$gettext -Dxkbcommon=3D$xkbcommon -Du2f=3D$u2f -Dvirti= ofsd=3D$virtiofsd \ -Dcapstone=3D$capstone -Dslirp=3D$slirp -Dfdt=3D$fdt -Dbrlapi=3D$b= rlapi \ diff --git a/hw/usb/meson.build b/hw/usb/meson.build index f357270d0b..bd3f8735b9 100644 --- a/hw/usb/meson.build +++ b/hw/usb/meson.build @@ -72,7 +72,7 @@ if config_host.has_key('CONFIG_USB_REDIR') endif =20 # usb pass-through -softmmu_ss.add(when: ['CONFIG_USB', 'CONFIG_USB_LIBUSB', libusb], +softmmu_ss.add(when: ['CONFIG_USB', libusb], if_true: files('host-libusb.c'), if_false: files('host-stub.c')) softmmu_ss.add(when: 'CONFIG_ALL', if_true: files('host-stub.c')) diff --git a/meson.build b/meson.build index 0d4b6fff16..2a4a47d281 100644 --- a/meson.build +++ b/meson.build @@ -991,10 +991,12 @@ if 'CONFIG_USB_REDIR' in config_host link_args: config_host['USB_REDIR_LIBS'].s= plit()) endif libusb =3D not_found -if 'CONFIG_USB_LIBUSB' in config_host - libusb =3D declare_dependency(compile_args: config_host['LIBUSB_CFLAGS']= .split(), - link_args: config_host['LIBUSB_LIBS'].split(= )) +if not get_option('libusb').auto() or have_system + libusb =3D dependency('libusb-1.0', required: get_option('libusb'), + version: '>=3D1.0.13', method: 'pkg-config', + kwargs: static_kwargs) endif + libpmem =3D not_found if 'CONFIG_LIBPMEM' in config_host libpmem =3D declare_dependency(compile_args: config_host['LIBPMEM_CFLAGS= '].split(), @@ -1213,6 +1215,7 @@ config_host_data.set('CONFIG_SDL', sdl.found()) config_host_data.set('CONFIG_SDL_IMAGE', sdl_image.found()) config_host_data.set('CONFIG_SECCOMP', seccomp.found()) config_host_data.set('CONFIG_SNAPPY', snappy.found()) +config_host_data.set('CONFIG_USB_LIBUSB', libusb.found()) config_host_data.set('CONFIG_VHOST_USER_BLK_SERVER', have_vhost_user_blk_s= erver) config_host_data.set('CONFIG_VNC', vnc.found()) config_host_data.set('CONFIG_VNC_JPEG', jpeg.found()) @@ -2793,7 +2796,7 @@ summary_info +=3D {'rbd support': rbd.found()} summary_info +=3D {'xfsctl support': config_host.has_key('CONFIG_XFS')} summary_info +=3D {'smartcard support': config_host.has_key('CONFIG_SMARTC= ARD')} summary_info +=3D {'U2F support': u2f.found()} -summary_info +=3D {'libusb': config_host.has_key('CONFIG_USB_LI= BUSB')} +summary_info +=3D {'libusb': libusb.found()} summary_info +=3D {'usb net redir': config_host.has_key('CONFIG_USB_RE= DIR')} summary_info +=3D {'OpenGL support': config_host.has_key('CONFIG_OPENGL= ')} summary_info +=3D {'GBM': config_host.has_key('CONFIG_GBM')} diff --git a/meson_options.txt b/meson_options.txt index ac6e90da07..02c14d4751 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -86,6 +86,8 @@ option('gcrypt', type : 'feature', value : 'auto', description: 'libgcrypt cryptography support') option('libudev', type : 'feature', value : 'auto', description: 'Use libudev to enumerate host devices') +option('libusb', type : 'feature', value : 'auto', + description: 'libusb support for USB passthrough') option('lzfse', type : 'feature', value : 'auto', description: 'lzfse support for DMG images') option('lzo', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151830; cv=none; d=zohomail.com; s=zohoarc; b=NGUIovXQdIGa5IEPBwzihQgb3jjzu64/dlXIzcx8VzFOybjEgu6Bjc5GIy7juTm91HAYY9CbGgMLKXozRVts5V/XyjrZj+65ja58SMs363MZW9YD22wyawKMkuETt2POkv4rt8czHwXLt40fbzACAl8pI4Rj41/iJUU6z3z0Kr4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151830; h=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=G61MEnWdFvevbLBmfZeLg3VT1jlEJuO/IOD5W0UALKo=; b=EHuHhmLI4ef4jz/rA82v8BoO1CIQivAqVGN4CdWwyytN1kzqx3MMpn0mbFRp2TyIOdnfrz0ER8IBny/sjxR3fy3VyE9Ts8KeDv5yPABqbxCsZ+A6VIJMPFb0Eqq8eE1Fs5f28z7DMCslV1PTF0HQ9M565tBIGj7fmjCHH0ONeM0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151830619228.71004761694712; Tue, 8 Jun 2021 04:30:30 -0700 (PDT) Received: from localhost ([::1]:51246 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZwD-0003PY-BE for importer2@patchew.org; Tue, 08 Jun 2021 07:30:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43522) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpA-0006V8-I3 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:12 -0400 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]:55047) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp8-0007yp-NA for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:12 -0400 Received: by mail-wm1-x336.google.com with SMTP id o127so1587171wmo.4 for ; Tue, 08 Jun 2021 04:23:10 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=G61MEnWdFvevbLBmfZeLg3VT1jlEJuO/IOD5W0UALKo=; b=ukKAZjCs45KFmOKoMhPw8ChpEtqEl8a1LjM1BCjHzMjE/hwKhUBfg/OIgqRXrfBxm0 7+ATOx96j6scP1ozVCjwsRB9susDzw0LLeJm2qgK3o7vRf0yCTJ0nG5r6NZau8PaqQUx FvYHGyWyqraW6zjUU5V0eAIDqowWepiNsr3tLln2R2RUpKuMrk6bBbH4dhKQhG8kZqq+ hrzJIE+MBFWE5hZb6CSWOQVvv5qw8VNE57Dm9QCdKepXgaYtQAUSWxdu0gH7U9FBhXki QZNTtiVgZ78xp3CthNwBpwVsMgUQAra9OI2faKFhAbsZAlfO8AdJXfSfAt5dhY+rGAjr VIlw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=G61MEnWdFvevbLBmfZeLg3VT1jlEJuO/IOD5W0UALKo=; b=PxT9lgIxO9ZRRzt50TmI5ZfUlkvTDjPC1KOs0KZJrFWB1Qfx5DtavzgGNWJRV8HKNw w5yldBEt8pRthYpQb1F69+fkQGQbtj+orpVhkdWPVmZgOlOeYhXExXLCGTSaGdM3e1Su DbPW08wLapV9A36iWmT5Uv0f8I/2qc9JmVtlnq4aGyr0u8fgFHfxntOP3tBFe4kNUFgr dbW1sEeNb/2cfZdOB+qURmPAme3a9MfJFGIEeQAW7XW3DP12uWOKewMG+xDfx4vIu6AW BfOrUhpyxDkTV4mjfqztzfgKFGHLZNjycCEm5kU6QkACUDhh44J0c80yRHOpZM1/iAed nDMA== X-Gm-Message-State: AOAM530BU8y2TnHiSX3br/6SpT0aOSD7NnAYIQTypzr855mAZfq0Llbw BVccynDH9Dw1UK8CDbWy8gNjc9GoiAjnuw== X-Google-Smtp-Source: ABdhPJyfYnBe1A3TjIHxePHyoitCaoVA/49D7YH5Np6SXDb2CX+o/CxTTXzodX+nTc6kkcPmyT8rTw== X-Received: by 2002:a7b:cc09:: with SMTP id f9mr21261272wmh.104.1623151389312; Tue, 08 Jun 2021 04:23:09 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 07/26] configure, meson: convert libcacard detection to meson Date: Tue, 8 Jun 2021 13:22:42 +0200 Message-Id: <20210608112301.402434-8-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::336; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x336.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 28 ++++------------------------ hw/usb/meson.build | 2 +- meson.build | 9 +++++---- meson_options.txt | 2 ++ 4 files changed, 12 insertions(+), 29 deletions(-) diff --git a/configure b/configure index 651273c023..591acd0750 100755 --- a/configure +++ b/configure @@ -372,7 +372,7 @@ trace_file=3D"trace" spice=3D"$default_feature" spice_protocol=3D"auto" rbd=3D"auto" -smartcard=3D"$default_feature" +smartcard=3D"auto" u2f=3D"auto" libusb=3D"auto" usb_redir=3D"$default_feature" @@ -1277,9 +1277,9 @@ for opt do ;; --enable-xfsctl) xfs=3D"yes" ;; - --disable-smartcard) smartcard=3D"no" + --disable-smartcard) smartcard=3D"disabled" ;; - --enable-smartcard) smartcard=3D"yes" + --enable-smartcard) smartcard=3D"enabled" ;; --disable-u2f) u2f=3D"disabled" ;; @@ -3980,20 +3980,6 @@ EOF fi fi =20 -# check for smartcard support -if test "$smartcard" !=3D "no"; then - if $pkg_config --atleast-version=3D2.5.1 libcacard; then - libcacard_cflags=3D$($pkg_config --cflags libcacard) - libcacard_libs=3D$($pkg_config --libs libcacard) - smartcard=3D"yes" - else - if test "$smartcard" =3D "yes"; then - feature_not_found "smartcard" "Install libcacard devel" - fi - smartcard=3D"no" - fi -fi - # check for usbredirparser for usb network redirection support if test "$usb_redir" !=3D "no" ; then if $pkg_config --atleast-version=3D0.6 libusbredirparser-0.5; then @@ -5606,12 +5592,6 @@ if test "$spice" =3D "yes" ; then echo "SPICE_LIBS=3D$spice_libs" >> $config_host_mak fi =20 -if test "$smartcard" =3D "yes" ; then - echo "CONFIG_SMARTCARD=3Dy" >> $config_host_mak - echo "SMARTCARD_CFLAGS=3D$libcacard_cflags" >> $config_host_mak - echo "SMARTCARD_LIBS=3D$libcacard_libs" >> $config_host_mak -fi - if test "$usb_redir" =3D "yes" ; then echo "CONFIG_USB_REDIR=3Dy" >> $config_host_mak echo "USB_REDIR_CFLAGS=3D$usb_redir_cflags" >> $config_host_mak @@ -6194,7 +6174,7 @@ if test "$skip_meson" =3D no; then -Dkvm=3D$kvm -Dhax=3D$hax -Dwhpx=3D$whpx -Dhvf=3D$hvf -Dnvmm=3D$nv= mm \ -Dxen=3D$xen -Dxen_pci_passthrough=3D$xen_pci_passthrough -Dtcg=3D= $tcg \ -Dcocoa=3D$cocoa -Dgtk=3D$gtk -Dmpath=3D$mpath -Dsdl=3D$sdl -Dsdl_= image=3D$sdl_image \ - -Dlibusb=3D$libusb \ + -Dlibusb=3D$libusb -Dsmartcard=3D$smartcard \ -Dvnc=3D$vnc -Dvnc_sasl=3D$vnc_sasl -Dvnc_jpeg=3D$vnc_jpeg -Dvnc_p= ng=3D$vnc_png \ -Dgettext=3D$gettext -Dxkbcommon=3D$xkbcommon -Du2f=3D$u2f -Dvirti= ofsd=3D$virtiofsd \ -Dcapstone=3D$capstone -Dslirp=3D$slirp -Dfdt=3D$fdt -Dbrlapi=3D$b= rlapi \ diff --git a/hw/usb/meson.build b/hw/usb/meson.build index bd3f8735b9..df9effbb10 100644 --- a/hw/usb/meson.build +++ b/hw/usb/meson.build @@ -49,7 +49,7 @@ softmmu_ss.add(when: ['CONFIG_POSIX', 'CONFIG_USB_STORAGE= _MTP'], if_true: files( # smartcard softmmu_ss.add(when: 'CONFIG_USB_SMARTCARD', if_true: files('dev-smartcard= -reader.c')) =20 -if config_host.has_key('CONFIG_SMARTCARD') +if cacard.found() usbsmartcard_ss =3D ss.source_set() usbsmartcard_ss.add(when: 'CONFIG_USB_SMARTCARD', if_true: [cacard, files('ccid-card-emulated.c', 'cci= d-card-passthru.c')]) diff --git a/meson.build b/meson.build index 2a4a47d281..d2efa6178a 100644 --- a/meson.build +++ b/meson.build @@ -975,9 +975,10 @@ if 'CONFIG_XEN_BACKEND' in config_host link_args: config_host['XEN_LIBS'].split()) endif cacard =3D not_found -if 'CONFIG_SMARTCARD' in config_host - cacard =3D declare_dependency(compile_args: config_host['SMARTCARD_CFLAG= S'].split(), - link_args: config_host['SMARTCARD_LIBS'].spl= it()) +if not get_option('smartcard').auto() or have_system + cacard =3D dependency('libcacard', required: get_option('smartcard'), + version: '>=3D2.5.1', method: 'pkg-config', + kwargs: static_kwargs) endif u2f =3D not_found if have_system @@ -2794,7 +2795,7 @@ summary_info +=3D {'bpf support': libbpf.found()} summary_info +=3D {'spice support': config_host.has_key('CONFIG_SPICE'= )} summary_info +=3D {'rbd support': rbd.found()} summary_info +=3D {'xfsctl support': config_host.has_key('CONFIG_XFS')} -summary_info +=3D {'smartcard support': config_host.has_key('CONFIG_SMARTC= ARD')} +summary_info +=3D {'smartcard support': cacard.found()} summary_info +=3D {'U2F support': u2f.found()} summary_info +=3D {'libusb': libusb.found()} summary_info +=3D {'usb net redir': config_host.has_key('CONFIG_USB_RE= DIR')} diff --git a/meson_options.txt b/meson_options.txt index 02c14d4751..cd9374384e 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -102,6 +102,8 @@ option('sdl_image', type : 'feature', value : 'auto', description: 'SDL Image support for icons') option('seccomp', type : 'feature', value : 'auto', description: 'seccomp support') +option('smartcard', type : 'feature', value : 'auto', + description: 'CA smartcard emulation support') option('snappy', type : 'feature', value : 'auto', description: 'snappy compression support') option('u2f', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151763; cv=none; d=zohomail.com; s=zohoarc; b=FtJpvER6nkGds3S+lV0BvhRg7UaDTv5qQlKGmNzLxuX8/htrGsFhsG5Ii07DKJAZ9UTPFBqDdSBNUIM45gxCNm0mhglIV6BqxP8exPTbVMuZ0AaWf9N2eZ+vEk8D9Vpd86cTChrNCDJAVi+Fq7CfrJvhkDwIoF4M3QwPOJxkKPY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151763; h=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=3BHzzehIAd6rLWsdffGUKDOovWe+Q46KfbqgPwO3Ny4=; b=LZMaQCVmzwXKIqPNkZDo9qLA1OVL1zRGR0MGjrSCm55hEEP0anNPv+Fcumhh/PPne/GKfWCM2UUa01uHWJCQFDC4kRJCfl0RwzVS2Idv4XpkcA1RprxEjFompE6fY/xtGTM0HhGupIuc6t2H0GeITs6ItKZR7Aj1T1AeswxO23U= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151763432591.3680947229973; Tue, 8 Jun 2021 04:29:23 -0700 (PDT) Received: from localhost ([::1]:46572 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZv8-0000L3-EP for importer2@patchew.org; Tue, 08 Jun 2021 07:29:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43528) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpB-0006WG-9L for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:14 -0400 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]:41848) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZp9-0007z4-I9 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:12 -0400 Received: by mail-wm1-x32b.google.com with SMTP id l11-20020a05600c4f0bb029017a7cd488f5so1632062wmq.0 for ; Tue, 08 Jun 2021 04:23:11 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=3BHzzehIAd6rLWsdffGUKDOovWe+Q46KfbqgPwO3Ny4=; b=d+eDGFdViaoWBKenOh2tf31JJYKlvU0vf47RcMhuOAZhST5BPQwrcDkMjIdzyL8hd4 w4p4yGV5fGNNAZn0z2Yu15TztX7jpInXIYxpu1pqq6TDq+ZcyFHteOXxmBdpzptbkClU Z3tb7OxkB6Zm02R/66cvO9XK2gnxS2zNmGM+3u/ZvVEKyH2ZKn8wMNKEaRGUpXRXloWM uMsPVKDckabXrbFcaWLSl3AAKXTJqrjoxzBdNISN7nTsQaL4RqhW0F5OKkRFuRKIujNr RM5WF84oAR/Kz3mU2466c2/+gOlRFRqoXUmT2ABvmd6kmTY3GWv5brXgnsNCOf5eww4q wVlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=3BHzzehIAd6rLWsdffGUKDOovWe+Q46KfbqgPwO3Ny4=; b=kiLMe9j/NOkCAg+FaOqA7WAzorKBn4T0YKk/AFwhG5AULw3KJKqp4Ytm6OEGnwrksw zYZT52EJDPVQKO0nKHph5t9zsxA/ULTNiIeXh7uel/8Har77WQnMlasIOGFSH/6EAEuo stRAR+HB0FOIwaRqDXD9399HK8zeTbkmRvxhznLxwk1lhlLufH6FCoZ04fggtMrfYnay IB7iUm6CfS55x3CfAGhH3svv8v6TlM7ibEYD535n6Cfg50JTHsBbK61j5piPTFmT+0E+ 6glUwPY6vGwpI55aindqvrw1l/8+KuJmlo6xhmVaP1OIV615nntak2n0I72p8N8qPhMk 2LZg== X-Gm-Message-State: AOAM531kPk5SJ369lq59cvBAJzeP6AHyJiSe8kqTXlOjMJtsCeNqeGV5 +ZUm+rmfeohg8oZr/X2Chj7gDynO4c1JSg== X-Google-Smtp-Source: ABdhPJyrSQkInCe6YwfCqieCVkEvSGXju1IRi9fn7KUx/xtNXnkh5jenWV/cF5ad1pj1Q9Q8yOgC5w== X-Received: by 2002:a05:600c:3ba2:: with SMTP id n34mr13265634wms.120.1623151390219; Tue, 08 Jun 2021 04:23:10 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 08/26] configure, meson: convert libusbredir detection to meson Date: Tue, 8 Jun 2021 13:22:43 +0200 Message-Id: <20210608112301.402434-9-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x32b.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 28 ++++------------------------ hw/usb/meson.build | 2 +- meson.build | 9 +++++---- meson_options.txt | 2 ++ 4 files changed, 12 insertions(+), 29 deletions(-) diff --git a/configure b/configure index 591acd0750..9a6217a3bf 100755 --- a/configure +++ b/configure @@ -375,7 +375,7 @@ rbd=3D"auto" smartcard=3D"auto" u2f=3D"auto" libusb=3D"auto" -usb_redir=3D"$default_feature" +usb_redir=3D"auto" opengl=3D"$default_feature" cpuid_h=3D"no" avx2_opt=3D"$default_feature" @@ -1289,9 +1289,9 @@ for opt do ;; --enable-libusb) libusb=3D"enabled" ;; - --disable-usb-redir) usb_redir=3D"no" + --disable-usb-redir) usb_redir=3D"disabled" ;; - --enable-usb-redir) usb_redir=3D"yes" + --enable-usb-redir) usb_redir=3D"enabled" ;; --disable-zlib-test) ;; @@ -3980,20 +3980,6 @@ EOF fi fi =20 -# check for usbredirparser for usb network redirection support -if test "$usb_redir" !=3D "no" ; then - if $pkg_config --atleast-version=3D0.6 libusbredirparser-0.5; then - usb_redir=3D"yes" - usb_redir_cflags=3D$($pkg_config --cflags libusbredirparser-0.5) - usb_redir_libs=3D$($pkg_config --libs libusbredirparser-0.5) - else - if test "$usb_redir" =3D "yes"; then - feature_not_found "usb-redir" "Install usbredir devel" - fi - usb_redir=3D"no" - fi -fi - ########################################## # check if we have VSS SDK headers for win =20 @@ -5592,12 +5578,6 @@ if test "$spice" =3D "yes" ; then echo "SPICE_LIBS=3D$spice_libs" >> $config_host_mak fi =20 -if test "$usb_redir" =3D "yes" ; then - echo "CONFIG_USB_REDIR=3Dy" >> $config_host_mak - echo "USB_REDIR_CFLAGS=3D$usb_redir_cflags" >> $config_host_mak - echo "USB_REDIR_LIBS=3D$usb_redir_libs" >> $config_host_mak -fi - if test "$opengl" =3D "yes" ; then echo "CONFIG_OPENGL=3Dy" >> $config_host_mak echo "OPENGL_CFLAGS=3D$opengl_cflags" >> $config_host_mak @@ -6174,7 +6154,7 @@ if test "$skip_meson" =3D no; then -Dkvm=3D$kvm -Dhax=3D$hax -Dwhpx=3D$whpx -Dhvf=3D$hvf -Dnvmm=3D$nv= mm \ -Dxen=3D$xen -Dxen_pci_passthrough=3D$xen_pci_passthrough -Dtcg=3D= $tcg \ -Dcocoa=3D$cocoa -Dgtk=3D$gtk -Dmpath=3D$mpath -Dsdl=3D$sdl -Dsdl_= image=3D$sdl_image \ - -Dlibusb=3D$libusb -Dsmartcard=3D$smartcard \ + -Dlibusb=3D$libusb -Dsmartcard=3D$smartcard -Dusb_redir=3D$usb_red= ir \ -Dvnc=3D$vnc -Dvnc_sasl=3D$vnc_sasl -Dvnc_jpeg=3D$vnc_jpeg -Dvnc_p= ng=3D$vnc_png \ -Dgettext=3D$gettext -Dxkbcommon=3D$xkbcommon -Du2f=3D$u2f -Dvirti= ofsd=3D$virtiofsd \ -Dcapstone=3D$capstone -Dslirp=3D$slirp -Dfdt=3D$fdt -Dbrlapi=3D$b= rlapi \ diff --git a/hw/usb/meson.build b/hw/usb/meson.build index df9effbb10..4f24b5274d 100644 --- a/hw/usb/meson.build +++ b/hw/usb/meson.build @@ -64,7 +64,7 @@ if u2f.found() endif =20 # usb redirect -if config_host.has_key('CONFIG_USB_REDIR') +if usbredir.found() usbredir_ss =3D ss.source_set() usbredir_ss.add(when: 'CONFIG_USB', if_true: [usbredir, files('redirect.c', 'quirks.c')]) diff --git a/meson.build b/meson.build index d2efa6178a..ae40bdf7c4 100644 --- a/meson.build +++ b/meson.build @@ -987,9 +987,10 @@ if have_system kwargs: static_kwargs) endif usbredir =3D not_found -if 'CONFIG_USB_REDIR' in config_host - usbredir =3D declare_dependency(compile_args: config_host['USB_REDIR_CFL= AGS'].split(), - link_args: config_host['USB_REDIR_LIBS'].s= plit()) +if not get_option('usb_redir').auto() or have_system + usbredir =3D dependency('libusbredirparser-0.5', required: get_option('u= sb_redir'), + version: '>=3D0.6', method: 'pkg-config', + kwargs: static_kwargs) endif libusb =3D not_found if not get_option('libusb').auto() or have_system @@ -2798,7 +2799,7 @@ summary_info +=3D {'xfsctl support': config_host.h= as_key('CONFIG_XFS')} summary_info +=3D {'smartcard support': cacard.found()} summary_info +=3D {'U2F support': u2f.found()} summary_info +=3D {'libusb': libusb.found()} -summary_info +=3D {'usb net redir': config_host.has_key('CONFIG_USB_RE= DIR')} +summary_info +=3D {'usb net redir': usbredir.found()} summary_info +=3D {'OpenGL support': config_host.has_key('CONFIG_OPENGL= ')} summary_info +=3D {'GBM': config_host.has_key('CONFIG_GBM')} summary_info +=3D {'libiscsi support': libiscsi.found()} diff --git a/meson_options.txt b/meson_options.txt index cd9374384e..f7ec9bee27 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -108,6 +108,8 @@ option('snappy', type : 'feature', value : 'auto', description: 'snappy compression support') option('u2f', type : 'feature', value : 'auto', description: 'U2F emulation support') +option('usb_redir', type : 'feature', value : 'auto', + description: 'libusbredir support') option('vnc', type : 'feature', value : 'enabled', description: 'VNC server') option('vnc_jpeg', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152000; cv=none; d=zohomail.com; s=zohoarc; b=IQW/wG+4HuMGks/0sd++Ms3CIkX2yEoEHghUWVcIBeqJbzo12SBA/aX/ucfTxPmsSnqxfvF+ZqmM/IqLg3i2L4kTYz7VoTO5lzioagqcZ5kKX6sQmN7pw2oRvU/iQm4SNxxNhGFRkP2e8wogzVr2HWqVzSb8CaFWwObfTKMOFOo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152000; h=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=6UDWEf0DLDCUpQTKicBlzYssZ+vCxOEn0uxeWy/2xyI=; b=ABHrmxRdJbwCeiUqUNDhGurO0fJKWUhCKM/ZUNIdjckrexqjWyHq0YxKx/9qptvdcGrk315hDe86U0hZ6c8/9wwiceYFbevvFEi+nuCU9NiCmNMRjbzMipZPG14iNd+zgCDu3zX6nslSYna/P6EpjDNf6kuAf4aXUgwT0D5+6n8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152000304140.92882327114762; Tue, 8 Jun 2021 04:33:20 -0700 (PDT) Received: from localhost ([::1]:59764 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZyx-0000i2-7e for importer2@patchew.org; Tue, 08 Jun 2021 07:33:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43560) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpD-0006Wk-9V for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:15 -0400 Received: from mail-wr1-x435.google.com ([2a00:1450:4864:20::435]:42723) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpB-0007z9-3V for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:14 -0400 Received: by mail-wr1-x435.google.com with SMTP id c5so21118907wrq.9 for ; Tue, 08 Jun 2021 04:23:12 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.10 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6UDWEf0DLDCUpQTKicBlzYssZ+vCxOEn0uxeWy/2xyI=; b=QpKQv1gOBrGXZHQna4vPYPILQRNKhkYurPhSWG9MgJejNKCDMnReI0SU/eXIxu8whL qonTKEPk3Qzs12MtUpoFV2JPb9zy8XfTY5nfJieZYI18XoPMe9sosjHraUIwqIs7kx0f fJKpwrIJJhTMrpd2nf7HXTTYUV3X7dqhYfWSoPoaaS3WRxCiUr4vkUiUhDXVO1PN1gmn 51V14NFOIc+vFiZMGS/hFlPEOTzKEevspVhbDJPAvWFNxJn0WvF8O9PM5Xv8HRwu7oY1 5NceOeHHTlO17OGMNsVBrbwyalrDfvYqY0Mz0mF1Jh/R0SZt9kv2IR0pYywl1Nkd+zN7 TiRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=6UDWEf0DLDCUpQTKicBlzYssZ+vCxOEn0uxeWy/2xyI=; b=jlVgo8WaHh7zfYxTltt+4bA5MacICFMrYtczdNFVV1pYXkQpqinTW32DvaycoED9Jd HxZ1boxYKjBmT3+ALQGJS5IQ3tM8DtdSFMllyXNKO63i6UqOaxyV4xH2gajqr+UXM7pY 5sjkEs6vCj1lPxtVyr5PrhRhITOUf5B9bwb5UzY1wlQTauwOYBwuuwiwJOLHOU9eyTUE G5PNOdI309Jnbn5fZjwnCs5U7SE4J7NbQzVIgMr8jJQt2aiHCWkEI6YnM6T40K+5hXpM 2fBkHAPQXP6oOZNOoU9UULmrRa7ryml8henu4Q8Ihd+Va7g7w4mHXAD3+XiAP2jteek/ ZD6g== X-Gm-Message-State: AOAM533S2t+HKG0AF2OEGONUzf8sv697Wu4dasQwMzC8pZsBqS5shD6n 2dejFOme0Bbb3idTq8xAQ0TDKIvknhYfyQ== X-Google-Smtp-Source: ABdhPJxV27PQvMKDxxrAN5uuzxm54BCTqL01PXmaRKmvWXoGcVJDEDKLuwzIhNYRfR17ZHQg5QgBqw== X-Received: by 2002:adf:b648:: with SMTP id i8mr15699630wre.425.1623151391155; Tue, 08 Jun 2021 04:23:11 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 09/26] configure, meson: convert vte detection to meson Date: Tue, 8 Jun 2021 13:22:44 +0200 Message-Id: <20210608112301.402434-10-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::435; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x435.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 35 ++++------------------------------- meson.build | 22 ++++++++++++++++------ meson_options.txt | 2 ++ 3 files changed, 22 insertions(+), 37 deletions(-) diff --git a/configure b/configure index 9a6217a3bf..d3351557e9 100755 --- a/configure +++ b/configure @@ -408,7 +408,7 @@ gnutls=3D"auto" nettle=3D"auto" gcrypt=3D"auto" auth_pam=3D"auto" -vte=3D"$default_feature" +vte=3D"auto" virglrenderer=3D"$default_feature" tpm=3D"$default_feature" libssh=3D"$default_feature" @@ -1395,9 +1395,9 @@ for opt do ;; --disable-pvrdma) pvrdma=3D"no" ;; - --disable-vte) vte=3D"no" + --disable-vte) vte=3D"disabled" ;; - --enable-vte) vte=3D"yes" + --enable-vte) vte=3D"enabled" ;; --disable-virglrenderer) virglrenderer=3D"no" ;; @@ -2799,28 +2799,6 @@ EOF fi fi =20 -########################################## -# VTE probe - -if test "$vte" !=3D "no"; then - vteminversion=3D"0.32.0" - if $pkg_config --exists "vte-2.91"; then - vtepackage=3D"vte-2.91" - else - vtepackage=3D"vte-2.90" - fi - if $pkg_config --exists "$vtepackage >=3D $vteminversion"; then - vte_cflags=3D$($pkg_config --cflags $vtepackage) - vte_libs=3D$($pkg_config --libs $vtepackage) - vteversion=3D$($pkg_config --modversion $vtepackage) - vte=3D"yes" - elif test "$vte" =3D "yes"; then - feature_not_found "vte" "Install libvte-2.90/2.91 devel" - else - vte=3D"no" - fi -fi - ########################################## # RDMA needs OpenFabrics libraries if test "$rdma" !=3D "no" ; then @@ -5486,11 +5464,6 @@ fi if test "$have_copy_file_range" =3D "yes" ; then echo "HAVE_COPY_FILE_RANGE=3Dy" >> $config_host_mak fi -if test "$vte" =3D "yes" ; then - echo "CONFIG_VTE=3Dy" >> $config_host_mak - echo "VTE_CFLAGS=3D$vte_cflags" >> $config_host_mak - echo "VTE_LIBS=3D$vte_libs" >> $config_host_mak -fi if test "$virglrenderer" =3D "yes" ; then echo "CONFIG_VIRGL=3Dy" >> $config_host_mak echo "VIRGL_CFLAGS=3D$virgl_cflags" >> $config_host_mak @@ -6154,7 +6127,7 @@ if test "$skip_meson" =3D no; then -Dkvm=3D$kvm -Dhax=3D$hax -Dwhpx=3D$whpx -Dhvf=3D$hvf -Dnvmm=3D$nv= mm \ -Dxen=3D$xen -Dxen_pci_passthrough=3D$xen_pci_passthrough -Dtcg=3D= $tcg \ -Dcocoa=3D$cocoa -Dgtk=3D$gtk -Dmpath=3D$mpath -Dsdl=3D$sdl -Dsdl_= image=3D$sdl_image \ - -Dlibusb=3D$libusb -Dsmartcard=3D$smartcard -Dusb_redir=3D$usb_red= ir \ + -Dlibusb=3D$libusb -Dsmartcard=3D$smartcard -Dusb_redir=3D$usb_red= ir -Dvte=3D$vte \ -Dvnc=3D$vnc -Dvnc_sasl=3D$vnc_sasl -Dvnc_jpeg=3D$vnc_jpeg -Dvnc_p= ng=3D$vnc_png \ -Dgettext=3D$gettext -Dxkbcommon=3D$xkbcommon -Du2f=3D$u2f -Dvirti= ofsd=3D$virtiofsd \ -Dcapstone=3D$capstone -Dslirp=3D$slirp -Dfdt=3D$fdt -Dbrlapi=3D$b= rlapi \ diff --git a/meson.build b/meson.build index ae40bdf7c4..f3af9ee3cf 100644 --- a/meson.build +++ b/meson.build @@ -860,6 +860,7 @@ endif =20 gtk =3D not_found gtkx11 =3D not_found +vte =3D not_found if not get_option('gtk').auto() or (have_system and not cocoa.found()) gtk =3D dependency('gtk+-3.0', version: '>=3D3.22.0', method: 'pkg-config', @@ -871,14 +872,22 @@ if not get_option('gtk').auto() or (have_system and n= ot cocoa.found()) required: false, kwargs: static_kwargs) gtk =3D declare_dependency(dependencies: [gtk, gtkx11]) + + if not get_option('vte').auto() or have_system + vte =3D dependency('vte-2.91', version: '>=3D0.32.0', + method: 'pkg-config', + required: get_option('vte'), + kwargs: static_kwargs) + if not vte.found() + vte =3D dependency('vte-2.90', version: '>=3D0.32.0', + method: 'pkg-config', + required: get_option('vte'), + kwargs: static_kwargs) + endif + endif endif endif =20 -vte =3D not_found -if 'CONFIG_VTE' in config_host - vte =3D declare_dependency(compile_args: config_host['VTE_CFLAGS'].split= (), - link_args: config_host['VTE_LIBS'].split()) -endif x11 =3D not_found if gtkx11.found() x11 =3D dependency('x11', method: 'pkg-config', required: gtkx11.found(), @@ -1207,6 +1216,7 @@ if glusterfs.found() config_host_data.set('CONFIG_GLUSTERFS_IOCB_HAS_STAT', glusterfs_iocb_ha= s_stat) endif config_host_data.set('CONFIG_GTK', gtk.found()) +config_host_data.set('CONFIG_VTE', vte.found()) config_host_data.set('CONFIG_LIBATTR', have_old_libattr) config_host_data.set('CONFIG_LIBCAP_NG', libcap_ng.found()) config_host_data.set('CONFIG_EBPF', libbpf.found()) @@ -2764,7 +2774,7 @@ summary_info +=3D {'SDL image support': sdl_image.fou= nd()} summary_info +=3D {'GTK support': gtk.found()} summary_info +=3D {'pixman': pixman.found()} # TODO: add back version -summary_info +=3D {'VTE support': config_host.has_key('CONFIG_VTE')} +summary_info +=3D {'VTE support': vte.found()} # TODO: add back version summary_info +=3D {'slirp support': slirp_opt =3D=3D 'disabled' ? fals= e : slirp_opt} summary_info +=3D {'libtasn1': tasn1.found()} diff --git a/meson_options.txt b/meson_options.txt index f7ec9bee27..8af42987f4 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -118,6 +118,8 @@ option('vnc_png', type : 'feature', value : 'auto', description: 'PNG compression for VNC server') option('vnc_sasl', type : 'feature', value : 'auto', description: 'SASL authentication for VNC server') +option('vte', type : 'feature', value : 'auto', + description: 'vte support for the gtk UI') option('xkbcommon', type : 'feature', value : 'auto', description: 'xkbcommon support') option('zstd', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151517; cv=none; d=zohomail.com; s=zohoarc; b=Llgi46wLdjL4JH98qsgYtQryEKJTx3MaNB/WmehwuPYmrN1zx0NoXPIN0MrEkIcVnuYTX4SKnccXb0BNyQG2hkCxvYkzw8c2H8OyipxKhOSVMdDY1fSqWE1M5HEc1ORRs4hAWjefj+BVEOrUjI15oaXfqEIWuMc/1LzKdc4tCh0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151517; h=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=KPzZ7D1UtY+QeqXtKh3Tp3/QcBfmpOIZBp3Ec0jWE6s=; b=NmWJ2RzewZbYaIPhE08psL0gs613Sg8upPXMigX+sWTg1sABCkrbUgcoSemHsnh6jqaX28rUyUoD4j7KF/9wgilqObeCQEkn0L27uK18Fb8Xbl/j7C/dmBz+ZNnSm6h/YYiPue5l5otUcOnEardC7enedR19YgBNb1mc5eNJUPw= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151517786538.4952737355296; Tue, 8 Jun 2021 04:25:17 -0700 (PDT) Received: from localhost ([::1]:34826 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZrA-0000wl-Im for importer2@patchew.org; Tue, 08 Jun 2021 07:25:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43558) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpD-0006Wj-8u for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:15 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:36778) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpB-000800-AG for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:14 -0400 Received: by mail-wr1-x434.google.com with SMTP id e11so10954515wrg.3 for ; Tue, 08 Jun 2021 04:23:12 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KPzZ7D1UtY+QeqXtKh3Tp3/QcBfmpOIZBp3Ec0jWE6s=; b=rBXdkHHwiB/bEJJ6HHt5QuWWQeYfTFEKerZKdi1KHLMqCf2aV1kZdB7IYpIFP2AMhv sQUc/+u8+wkePc+OLGzf5RRx5mdroEXV5SW420Rw/FJll7IXj7mRUjdBHUAm/GNNrHWD M+ZGfdn1e+tTymh18yfvkpjTa1SZ3flgHPNwEnwh2WM6OcTRjmt9qVvyRMaDK5pG8GgA 6gIA6z0MgfVIRR5dl02WCh8DOg3OP6Rm+51irRFh95j92FveoZ4YAx7ZRoR734jAwFJT Czg5tvJWzacegGvhQo++idptT23baQ2+a7qxTBEbsn3480FF+E7munqzLbOLGSK/KAcs og3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=KPzZ7D1UtY+QeqXtKh3Tp3/QcBfmpOIZBp3Ec0jWE6s=; b=C7fFWHo/fMQHqYuVdHQGTpmLB+q+F/1QC3Edv7amEXpk5ZT9RHA2eUd+C9JROfFPnF waXoCzi2nMTpIOQacjN6gJV+S76wzudOcNsWJM0H/CoQe9JIPzOI69VXCM1Addt6A7ra JK6z4C9PoFeT2Lyb1VQoHJA6i5x0NmKL37NgyYkWIvbPOkBRPGDjkZPF9bQHFppgi2RT BHHqKDPzi41/syQS/sojXAXg4HRSEFBIlhMEc9GmvTRJ7m1lwgOSmheKWGgDySICq5Er BjeduaFklbPyVeGUh5z2HaIaGEagV++8ie3qxNUFSTLoJmNeFrOfrpsFL+lBK5GnMYBE 5r9Q== X-Gm-Message-State: AOAM533j78LQ/K2CuJYMMi6tvQw6ex4MEarJFwF8WuyZBGbBi1u/McY3 IvYcJzQsf7ehuFwddunlPTSo6+VN+DWv/g== X-Google-Smtp-Source: ABdhPJx44VprtCKaLIoK6QdMoAIkuOqbnd5uiGHaaAKQ0A4Jflb4OPdlKrazRmrusPsjzO6d0QQu1g== X-Received: by 2002:adf:e4cf:: with SMTP id v15mr22227895wrm.162.1623151391975; Tue, 08 Jun 2021 04:23:11 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 10/26] configure, meson: convert virgl detection to meson Date: Tue, 8 Jun 2021 13:22:45 +0200 Message-Id: <20210608112301.402434-11-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::434; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x434.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 35 ++++------------------------------- hw/display/meson.build | 6 +++--- meson.build | 10 ++++++---- meson_options.txt | 2 ++ 4 files changed, 15 insertions(+), 38 deletions(-) diff --git a/configure b/configure index d3351557e9..c2c8c9f2d6 100755 --- a/configure +++ b/configure @@ -409,7 +409,7 @@ nettle=3D"auto" gcrypt=3D"auto" auth_pam=3D"auto" vte=3D"auto" -virglrenderer=3D"$default_feature" +virglrenderer=3D"auto" tpm=3D"$default_feature" libssh=3D"$default_feature" live_block_migration=3D${default_feature:-yes} @@ -1399,9 +1399,9 @@ for opt do ;; --enable-vte) vte=3D"enabled" ;; - --disable-virglrenderer) virglrenderer=3D"no" + --disable-virglrenderer) virglrenderer=3D"disabled" ;; - --enable-virglrenderer) virglrenderer=3D"yes" + --enable-virglrenderer) virglrenderer=3D"enabled" ;; --disable-tpm) tpm=3D"no" ;; @@ -4036,28 +4036,6 @@ EOF fi fi =20 -########################################## -# virgl renderer probe - -if test "$virglrenderer" !=3D "no" ; then - cat > $TMPC << EOF -#include -int main(void) { virgl_renderer_poll(); return 0; } -EOF - virgl_cflags=3D$($pkg_config --cflags virglrenderer 2>/dev/null) - virgl_libs=3D$($pkg_config --libs virglrenderer 2>/dev/null) - virgl_version=3D$($pkg_config --modversion virglrenderer 2>/dev/null) - if $pkg_config virglrenderer >/dev/null 2>&1 && \ - compile_prog "$virgl_cflags" "$virgl_libs" ; then - virglrenderer=3D"yes" - else - if test "$virglrenderer" =3D "yes" ; then - feature_not_found "virglrenderer" - fi - virglrenderer=3D"no" - fi -fi - ########################################## # capstone =20 @@ -5464,11 +5442,6 @@ fi if test "$have_copy_file_range" =3D "yes" ; then echo "HAVE_COPY_FILE_RANGE=3Dy" >> $config_host_mak fi -if test "$virglrenderer" =3D "yes" ; then - echo "CONFIG_VIRGL=3Dy" >> $config_host_mak - echo "VIRGL_CFLAGS=3D$virgl_cflags" >> $config_host_mak - echo "VIRGL_LIBS=3D$virgl_libs" >> $config_host_mak -fi if test "$xen" =3D "enabled" ; then echo "CONFIG_XEN_BACKEND=3Dy" >> $config_host_mak echo "CONFIG_XEN_CTRL_INTERFACE_VERSION=3D$xen_ctrl_version" >> $config_= host_mak @@ -6136,7 +6109,7 @@ if test "$skip_meson" =3D no; then -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt -Dauth_pa= m=3D$auth_pam \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ - -Dattr=3D$attr -Ddefault_devices=3D$default_devices \ + -Dattr=3D$attr -Ddefault_devices=3D$default_devices -Dvirglrendere= r=3D$virglrenderer \ -Ddocs=3D$docs -Dsphinx_build=3D$sphinx_build -Dinstall_blobs=3D$b= lobs \ -Dvhost_user_blk_server=3D$vhost_user_blk_server -Dmultiprocess=3D= $multiprocess \ -Dfuse=3D$fuse -Dfuse_lseek=3D$fuse_lseek -Dguest_agent_msi=3D$gue= st_agent_msi -Dbpf=3D$bpf\ diff --git a/hw/display/meson.build b/hw/display/meson.build index e1f473c1df..1e6b707d3c 100644 --- a/hw/display/meson.build +++ b/hw/display/meson.build @@ -61,7 +61,7 @@ if config_all_devices.has_key('CONFIG_VIRTIO_GPU') hw_display_modules +=3D {'virtio-gpu': virtio_gpu_ss} =20 virtio_gpu_gl_ss =3D ss.source_set() - virtio_gpu_gl_ss.add(when: ['CONFIG_VIRTIO_GPU', 'CONFIG_VIRGL', opengl], + virtio_gpu_gl_ss.add(when: ['CONFIG_VIRTIO_GPU', virgl, opengl], if_true: [files('virtio-gpu-gl.c', 'virtio-gpu-virg= l.c'), pixman, virgl]) hw_display_modules +=3D {'virtio-gpu-gl': virtio_gpu_gl_ss} endif @@ -75,7 +75,7 @@ if config_all_devices.has_key('CONFIG_VIRTIO_PCI') hw_display_modules +=3D {'virtio-gpu-pci': virtio_gpu_pci_ss} =20 virtio_gpu_pci_gl_ss =3D ss.source_set() - virtio_gpu_pci_gl_ss.add(when: ['CONFIG_VIRTIO_GPU', 'CONFIG_VIRTIO_PCI'= , 'CONFIG_VIRGL', opengl], + virtio_gpu_pci_gl_ss.add(when: ['CONFIG_VIRTIO_GPU', 'CONFIG_VIRTIO_PCI'= , virgl, opengl], if_true: [files('virtio-gpu-pci-gl.c'), pixman]) hw_display_modules +=3D {'virtio-gpu-pci-gl': virtio_gpu_pci_gl_ss} endif @@ -89,7 +89,7 @@ if config_all_devices.has_key('CONFIG_VIRTIO_VGA') hw_display_modules +=3D {'virtio-vga': virtio_vga_ss} =20 virtio_vga_gl_ss =3D ss.source_set() - virtio_vga_gl_ss.add(when: ['CONFIG_VIRTIO_VGA', 'CONFIG_VIRGL', opengl], + virtio_vga_gl_ss.add(when: ['CONFIG_VIRTIO_VGA', virgl, opengl], if_true: [files('virtio-vga-gl.c'), pixman]) hw_display_modules +=3D {'virtio-vga-gl': virtio_vga_gl_ss} endif diff --git a/meson.build b/meson.build index f3af9ee3cf..842831e1fb 100644 --- a/meson.build +++ b/meson.build @@ -471,9 +471,11 @@ if 'CONFIG_GBM' in config_host link_args: config_host['GBM_LIBS'].split()) endif virgl =3D not_found -if 'CONFIG_VIRGL' in config_host - virgl =3D declare_dependency(compile_args: config_host['VIRGL_CFLAGS'].s= plit(), - link_args: config_host['VIRGL_LIBS'].split()) +if not get_option('virglrenderer').auto() or have_system + virgl =3D dependency('virglrenderer', + method: 'pkg-config', + required: get_option('virglrenderer'), + kwargs: static_kwargs) endif curl =3D not_found if not get_option('curl').auto() or have_block @@ -2782,7 +2784,7 @@ summary_info +=3D {'PAM': pam.found()} summary_info +=3D {'iconv support': iconv.found()} summary_info +=3D {'curses support': curses.found()} # TODO: add back version -summary_info +=3D {'virgl support': config_host.has_key('CONFIG_VIRGL'= )} +summary_info +=3D {'virgl support': virgl.found()} summary_info +=3D {'curl support': curl.found()} summary_info +=3D {'Multipath support': mpathpersist.found()} summary_info +=3D {'VNC support': vnc.found()} diff --git a/meson_options.txt b/meson_options.txt index 8af42987f4..a70aedb0eb 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -110,6 +110,8 @@ option('u2f', type : 'feature', value : 'auto', description: 'U2F emulation support') option('usb_redir', type : 'feature', value : 'auto', description: 'libusbredir support') +option('virglrenderer', type : 'feature', value : 'auto', + description: 'virgl rendering support') option('vnc', type : 'feature', value : 'enabled', description: 'VNC server') option('vnc_jpeg', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152001; cv=none; d=zohomail.com; s=zohoarc; b=gQ5V1O/V79vwt0mWyncMGFkLrVJSbBHzjGnklgRcWwjIhjeQo/iTPmY6warO7gD4a812XyP85UZuh0poM9pZPfhEyPWkCaHqEjlASJ5tnBm2lh4R+hVZ51gWnpBhA+rQ4A0slMh4RCKasPmpqsHBgvn03umdQr+aJlOHBi5aAr4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152001; h=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=LZLODOBcrmhrnrdjLeC81KpnKgMjP8hJ8DsNQAfM7Xg=; b=W7pK+mZyanggYMlj7svnBDX4QYAcBB1j9NR6p98ybZqa9mf9IJRQ1762Cc/NqH2EFfFtmM6bSkpzPbupwyXP3bIT4aeqkDm2lGxLISDRp/5aiL4UIBewuwpxNVkjjHg4AwQia/mbnp87wPx2tvAzVSFGykjsz5kqqOQn1uUMSl0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152001741408.4586649184106; Tue, 8 Jun 2021 04:33:21 -0700 (PDT) Received: from localhost ([::1]:59950 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZyy-0000pW-Lg for importer2@patchew.org; Tue, 08 Jun 2021 07:33:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43564) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpD-0006Xt-JV for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:15 -0400 Received: from mail-wm1-x329.google.com ([2a00:1450:4864:20::329]:53960) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpC-00080l-15 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:15 -0400 Received: by mail-wm1-x329.google.com with SMTP id h3so1588625wmq.3 for ; Tue, 08 Jun 2021 04:23:13 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=LZLODOBcrmhrnrdjLeC81KpnKgMjP8hJ8DsNQAfM7Xg=; b=ENwMr/JxFL/3Xe7LCyLif39qmnb3m+TA5LEF2Uf9NQ6oqLZVDv0A+kaLQl/7qU6up2 VZZMZphaS3B6w/pYvgf2s1jkXjiD4PP+qVbcOv3dY9qgwAiRwj8twktQtmWfswcg0YJg qhg2BOPkKkcizLIOS5o8qH1KI+PE1hcxSjJuU/LCxEFyxpTLLIGbBbOkc/QjZEe35996 cj81Gaa4Vu/umt6ngPMUncdLakV17OmlA9rW13Ih3JsdOOJJdsBPOb/+9BwLyvwAPaBR 2dbKJu7/pByQZ41NDyUspwG6WP5P/AICNKRYf2TEssQvgreVOeaU8rzmhKaY+kzwKiGt 86Bw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=LZLODOBcrmhrnrdjLeC81KpnKgMjP8hJ8DsNQAfM7Xg=; b=GMatydq44Deh9ev46rv2D4PP0VFkRdwkAcMUfpnK/2yxJ7GLAW+jzxzo4R4Z1IyCai Hazp5AVJ7b12IKmAuBPwvgs0wHcpWgYOAAxx5cMcOl87hL5x1/HqH2gCkJZJtKYKLo9D 6kGU8nL/foqEnyqrdwcovedBFegBkaqH7PkgASeH83vH/88WQBQGSLQMq13P0p6wEyBv E6i6KLEXe3quqtLDszfDun2QTbXSg4SJyuNC5PxYnb8B/sH36QpiEpId/GKF+yp+5pad xmkGP4kDzqrugDxgp4/FbtwGSd/zaTPpbSNfpZdHwJGQ+LBe9BlYY+YYMxn+MHvIAYl8 IPUw== X-Gm-Message-State: AOAM5332PdudbCHHISjUFhdVJBvIe3l55DOyza5OY0WWU/Ig511/gNw3 7Kp0maziX+diu67oXBPmqCdlSuFznLr7cQ== X-Google-Smtp-Source: ABdhPJxeY1UWWubYc7eXZXFiovCRbCsOqsav+hL++TY3weUz2wAvyvRSW7aGDs9fo0Z1wPFKjJUmdw== X-Received: by 2002:a05:600c:3b11:: with SMTP id m17mr21620278wms.150.1623151392881; Tue, 08 Jun 2021 04:23:12 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 11/26] configure, meson: convert libdaxctl detection to meson Date: Tue, 8 Jun 2021 13:22:46 +0200 Message-Id: <20210608112301.402434-12-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::329; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x329.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini --- configure | 28 ++++------------------------ meson.build | 8 +++++--- meson_options.txt | 2 ++ 3 files changed, 11 insertions(+), 27 deletions(-) diff --git a/configure b/configure index c2c8c9f2d6..bd675f2254 100755 --- a/configure +++ b/configure @@ -433,7 +433,7 @@ plugins=3D"no" fuzzing=3D"no" rng_none=3D"no" secret_keyring=3D"$default_feature" -libdaxctl=3D"$default_feature" +libdaxctl=3D"auto" meson=3D"" ninja=3D"" skip_meson=3Dno @@ -1534,9 +1534,9 @@ for opt do ;; --disable-keyring) secret_keyring=3D"no" ;; - --enable-libdaxctl) libdaxctl=3Dyes + --enable-libdaxctl) libdaxctl=3Ddisabled ;; - --disable-libdaxctl) libdaxctl=3Dno + --disable-libdaxctl) libdaxctl=3Denabled ;; --enable-fuse) fuse=3D"enabled" ;; @@ -4950,22 +4950,6 @@ if test "$libpmem" !=3D "no"; then fi fi =20 -########################################## -# check for libdaxctl - -if test "$libdaxctl" !=3D "no"; then - if $pkg_config --atleast-version=3D57 "libdaxctl"; then - libdaxctl=3D"yes" - libdaxctl_libs=3D$($pkg_config --libs libdaxctl) - libdaxctl_cflags=3D$($pkg_config --cflags libdaxctl) - else - if test "$libdaxctl" =3D "yes" ; then - feature_not_found "libdaxctl" "Install libdaxctl" - fi - libdaxctl=3D"no" - fi -fi - ########################################## # check for slirp =20 @@ -5737,11 +5721,6 @@ if test "$libpmem" =3D "yes" ; then echo "LIBPMEM_CFLAGS=3D$libpmem_cflags" >> $config_host_mak fi =20 -if test "$libdaxctl" =3D "yes" ; then - echo "CONFIG_LIBDAXCTL=3Dy" >> $config_host_mak - echo "LIBDAXCTL_LIBS=3D$libdaxctl_libs" >> $config_host_mak -fi - if test "$bochs" =3D "yes" ; then echo "CONFIG_BOCHS=3Dy" >> $config_host_mak fi @@ -6107,6 +6086,7 @@ if test "$skip_meson" =3D no; then -Dcurl=3D$curl -Dglusterfs=3D$glusterfs -Dbzip2=3D$bzip2 -Dlibiscs= i=3D$libiscsi \ -Dlibnfs=3D$libnfs -Diconv=3D$iconv -Dcurses=3D$curses -Dlibudev= =3D$libudev\ -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ + -Dlibdaxctl=3D$libdaxctl \ -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt -Dauth_pa= m=3D$auth_pam \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ -Dattr=3D$attr -Ddefault_devices=3D$default_devices -Dvirglrendere= r=3D$virglrenderer \ diff --git a/meson.build b/meson.build index 842831e1fb..f1ece39736 100644 --- a/meson.build +++ b/meson.build @@ -1016,8 +1016,10 @@ if 'CONFIG_LIBPMEM' in config_host link_args: config_host['LIBPMEM_LIBS'].spli= t()) endif libdaxctl =3D not_found -if 'CONFIG_LIBDAXCTL' in config_host - libdaxctl =3D declare_dependency(link_args: config_host['LIBDAXCTL_LIBS'= ].split()) +if not get_option('libdaxctl').auto() or have_system + libdaxctl =3D dependency('libdaxctl', required: get_option('libdaxctl'), + version: '>=3D57', method: 'pkg-config', + kwargs: static_kwargs) endif tasn1 =3D not_found if gnutls.found() @@ -2835,7 +2837,7 @@ summary_info +=3D {'NUMA host support': config_host.h= as_key('CONFIG_NUMA')} summary_info +=3D {'libxml2': config_host.has_key('CONFIG_LIBXML= 2')} summary_info +=3D {'capstone': capstone_opt =3D=3D 'disabled' ? f= alse : capstone_opt} summary_info +=3D {'libpmem support': config_host.has_key('CONFIG_LIBPME= M')} -summary_info +=3D {'libdaxctl support': config_host.has_key('CONFIG_LIBDAX= CTL')} +summary_info +=3D {'libdaxctl support': libdaxctl.found()} summary_info +=3D {'libudev': libudev.found()} summary_info +=3D {'FUSE lseek': fuse_lseek.found()} summary(summary_info, bool_yn: true, section: 'Dependencies') diff --git a/meson_options.txt b/meson_options.txt index a70aedb0eb..46180000fd 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -84,6 +84,8 @@ option('nettle', type : 'feature', value : 'auto', description: 'nettle cryptography support') option('gcrypt', type : 'feature', value : 'auto', description: 'libgcrypt cryptography support') +option('libdaxctl', type : 'feature', value : 'auto', + description: 'libdaxctl support') option('libudev', type : 'feature', value : 'auto', description: 'Use libudev to enumerate host devices') option('libusb', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152132; cv=none; d=zohomail.com; s=zohoarc; b=lvWO2/hLPD2DGF2AR9usl+J45/bf6GEGnyOg6hKWB3lr7isK2YezrUI561l1HsPiOXsgCrszxIADmD24FdKNRHVmOA92dshMlswpjYl1ImaIuzZkSdTZ5TQ553PgBB5N1GfxicIdhoGLu586ys4v+EUcQRykcC/e7mmpPjOm6QE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152132; h=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=x9Fn8aGSUN1MXpHE+pv+qJcB/2aEHuqSvmuUZb8Mu0g=; b=ByxaROHCTtM1S98Sd9SBeduix/HFcqqbIMsuf8osZocdJvPCQKPQHqG9ZD2R8yUDnWYnvr6e6A3d+LbkUOXjPNX+MHe/6Pzq8XmAybxI4V+JigOJVdGoPwQMpP3ib0NiOD16tojg3ss7fQ5K8VOCD3GjhbjYe9IdoehCsK9vjzE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152132575688.5876043911898; Tue, 8 Jun 2021 04:35:32 -0700 (PDT) Received: from localhost ([::1]:40154 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa15-0006Nu-4s for importer2@patchew.org; Tue, 08 Jun 2021 07:35:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43588) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpF-0006cy-CV for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:17 -0400 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]:42721) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpD-00081J-EK for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:16 -0400 Received: by mail-wr1-x432.google.com with SMTP id c5so21119024wrq.9 for ; Tue, 08 Jun 2021 04:23:14 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=x9Fn8aGSUN1MXpHE+pv+qJcB/2aEHuqSvmuUZb8Mu0g=; b=iaXHm1dI9McIFrWTMHlk7alsajwKopdOxeB8xR31ON7VtoZYZifHFJ5OYrONzZ/vjU IdRU2pvzGClthwCNszXUYkxsxkzXFecmcEJuKJidDTGClU2NNY+6JHwOy0WqsygnD3FL xPCTGkJPXlCa19NLqz6UcUlBIySvsows6ig8PCTk6i2YLnUJKM6mukGOwXWiXLR4tHmJ +9MXr2pU+kub64nQge0DivGkK4JArzbZVvRJAZJmtrNd/v/M1J4ZyrRoZZfKiP746MH1 Knl0XxIq2ITN+GWBmcozTCRQph1X1IceEeX2tiMmQxiDAlpiuAOJu0BYUwmPqkHmrM8r qPeg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=x9Fn8aGSUN1MXpHE+pv+qJcB/2aEHuqSvmuUZb8Mu0g=; b=CK2QM8YZIMSbDv3Ep9bbqvbpvDCjnCydcBE5GRacgLoncBLaU3kTXsDP3wVN1zk5gy zFaNAkJdkKAdBrJoNEwmCoBz5nqu/imaKcT8JrhIfcHx+3d/qilAJ8HBDdV6Gq7CyqpS WULTEG605MKCgW4PLMpG1sDUZo2z1YwsXo0gAVWHjlwup6tWADbSMhyGI0vrm3tDcEYA oSYyDlBhyNZwC+Mm8i9q53TwhrqhehOwfD0N71ucgIqPaQ+QNaAsSYDiTgSBq22szVtv SvU1LD3qlLcqfRsvOzg/gnJIYUXjeQXhYlvtxyXOiRWO42+ndV7rg2jvvgnoyYdgnizp iyAA== X-Gm-Message-State: AOAM532G2Zz9Sjg9f95UGBqjJJfrC7shzkqqO0GzMY022dS4V7MMH6Cy iurRPT5nc3Rm5Y2pb42EwKgkrw1czh1zsA== X-Google-Smtp-Source: ABdhPJxaOI6sk0j5NagF9P/5H41LAupHvzBm+kNRqaMueo5DbWe/tvyFwrGJGSh79JAnqmByBTqdPQ== X-Received: by 2002:adf:e3cf:: with SMTP id k15mr21672466wrm.403.1623151393808; Tue, 08 Jun 2021 04:23:13 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 12/26] configure, meson: convert libpmem detection to meson Date: Tue, 8 Jun 2021 13:22:47 +0200 Message-Id: <20210608112301.402434-13-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x432.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 24 ++++-------------------- meson.build | 8 ++++---- meson_options.txt | 2 ++ 3 files changed, 10 insertions(+), 24 deletions(-) diff --git a/configure b/configure index bd675f2254..8389a6f73f 100755 --- a/configure +++ b/configure @@ -427,7 +427,7 @@ qed=3D${default_feature:-yes} parallels=3D${default_feature:-yes} libxml2=3D"$default_feature" debug_mutex=3D"no" -libpmem=3D"$default_feature" +libpmem=3D"auto" default_devices=3D"true" plugins=3D"no" fuzzing=3D"no" @@ -1504,9 +1504,9 @@ for opt do ;; --disable-debug-mutex) debug_mutex=3Dno ;; - --enable-libpmem) libpmem=3Dyes + --enable-libpmem) libpmem=3Ddisabled ;; - --disable-libpmem) libpmem=3Dno + --disable-libpmem) libpmem=3Denabled ;; --enable-xkbcommon) xkbcommon=3D"enabled" ;; @@ -4934,22 +4934,6 @@ EOF fi fi =20 -########################################## -# check for libpmem - -if test "$libpmem" !=3D "no"; then - if $pkg_config --exists "libpmem"; then - libpmem=3D"yes" - libpmem_libs=3D$($pkg_config --libs libpmem) - libpmem_cflags=3D$($pkg_config --cflags libpmem) - else - if test "$libpmem" =3D "yes" ; then - feature_not_found "libpmem" "Install nvml or pmdk" - fi - libpmem=3D"no" - fi -fi - ########################################## # check for slirp =20 @@ -6086,7 +6070,7 @@ if test "$skip_meson" =3D no; then -Dcurl=3D$curl -Dglusterfs=3D$glusterfs -Dbzip2=3D$bzip2 -Dlibiscs= i=3D$libiscsi \ -Dlibnfs=3D$libnfs -Diconv=3D$iconv -Dcurses=3D$curses -Dlibudev= =3D$libudev\ -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ - -Dlibdaxctl=3D$libdaxctl \ + -Dlibdaxctl=3D$libdaxctl -Dlibpmem=3D$libpmem \ -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt -Dauth_pa= m=3D$auth_pam \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ -Dattr=3D$attr -Ddefault_devices=3D$default_devices -Dvirglrendere= r=3D$virglrenderer \ diff --git a/meson.build b/meson.build index f1ece39736..8563443865 100644 --- a/meson.build +++ b/meson.build @@ -1011,9 +1011,9 @@ if not get_option('libusb').auto() or have_system endif =20 libpmem =3D not_found -if 'CONFIG_LIBPMEM' in config_host - libpmem =3D declare_dependency(compile_args: config_host['LIBPMEM_CFLAGS= '].split(), - link_args: config_host['LIBPMEM_LIBS'].spli= t()) +if not get_option('libpmem').auto() or have_system + libpmem =3D dependency('libpmem', required: get_option('libpmem'), + method: 'pkg-config', kwargs: static_kwargs) endif libdaxctl =3D not_found if not get_option('libdaxctl').auto() or have_system @@ -2836,7 +2836,7 @@ summary_info +=3D {'zstd support': zstd.found()} summary_info +=3D {'NUMA host support': config_host.has_key('CONFIG_NUMA')} summary_info +=3D {'libxml2': config_host.has_key('CONFIG_LIBXML= 2')} summary_info +=3D {'capstone': capstone_opt =3D=3D 'disabled' ? f= alse : capstone_opt} -summary_info +=3D {'libpmem support': config_host.has_key('CONFIG_LIBPME= M')} +summary_info +=3D {'libpmem support': libpmem.found()} summary_info +=3D {'libdaxctl support': libdaxctl.found()} summary_info +=3D {'libudev': libudev.found()} summary_info +=3D {'FUSE lseek': fuse_lseek.found()} diff --git a/meson_options.txt b/meson_options.txt index 46180000fd..b23174d0a1 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -86,6 +86,8 @@ option('gcrypt', type : 'feature', value : 'auto', description: 'libgcrypt cryptography support') option('libdaxctl', type : 'feature', value : 'auto', description: 'libdaxctl support') +option('libpmem', type : 'feature', value : 'auto', + description: 'libpmem support') option('libudev', type : 'feature', value : 'auto', description: 'Use libudev to enumerate host devices') option('libusb', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151844; cv=none; d=zohomail.com; s=zohoarc; b=k6dRvnvDDeQOTmfnqwQuP1B+nFk8BXn3p93Ecnv25Pfpaub7R1f5HlcAWzTMCmqgcSHC3v8+G4H2yaEey8hBtFmy//X3L0DI/yYkU7y6ZmTqojqI0Jle4wBX42oxjqF+mHBiRctltnC7sTOMArj1yVZK/Ugl54QjA5bAxDRD8jg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151844; h=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=fsOgg96A2kjSZMB4eKkTFEeBkFP/7luQOiHJgIFc3q0=; b=XD96b93tdR5jMKnVYwOKB3w108BJDQwTDtVlF+jjFAijf1XJsDyfmSIlqAV9oYIyu6UmdSPEkNBW+nDxpxWAG8/fIouynU/Hu+rTtjovGdc3bVRs3jUwvQGFohRI8ytpbyzKfZ9mGEeHXasetAvdzvPPrTHuiYrAaQswmJjGMhQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151844875932.4887366129836; Tue, 8 Jun 2021 04:30:44 -0700 (PDT) Received: from localhost ([::1]:52020 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZwR-0003w0-Ld for importer2@patchew.org; Tue, 08 Jun 2021 07:30:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43628) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpJ-0006iK-5e for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:21 -0400 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]:46978) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpE-00081W-0W for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:18 -0400 Received: by mail-wr1-x42b.google.com with SMTP id a11so19287157wrt.13 for ; Tue, 08 Jun 2021 04:23:15 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=fsOgg96A2kjSZMB4eKkTFEeBkFP/7luQOiHJgIFc3q0=; b=QNBgmj+TyLWsG7wQ2Mn9vV/Ls2+o2kAD4X1l7l0putMUquEDHC+oWBmG9R+6mP3fGl vMX9vEGTIqmf0yZ+etvQhrfOjHCxqd9gdZtfjgN78uAi6qiNWDOTgK3FqAc9FY1zJ2KZ YNvZ+LNxF/iuNNWbyYKMtV/rfrMCvKuoGCa7PYcho3X3WVYEwuDJQcltQm+uh+OOcVQB D+VA12hpXwa+9zgEaVtI/udq4MNrPw6gri/miLY5yShYGIZlVbWZcnz2wOhT9JI3Yuo1 RqxLTrD9Qne1B9aa5bKPcGY/slMjgy2+OmaK6fIHIQuaBGIrfIL1zWO22ws8s7gBFATG U95w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=fsOgg96A2kjSZMB4eKkTFEeBkFP/7luQOiHJgIFc3q0=; b=X9+Lbk7MLwwtxsfFyiRDL1u/QCPiAYtw2i7oIX4Xk6LMJcKA7ZBSpy0w3qphhrD37D v/BSjNRLAXnpvorHR7/PFoziYA3QgK0ckuzj9Crx8ptWrNdUT1RVUOOUc9Wx+M+XDbJ2 je+uTLQyDSO3LvVuzRqeMJeODXVYFGSUr2+1uJX3ZtuBxQLEDOzXdMkbfq1QKpKvoUOj hCa9KYaJdNtCdx2aqoIzYrI6CD+O+AceftY1XJ8f105CToD+kzzipSGxfeLRejf/UMxW biJId15FtwLMZANfLFXGbDb3ar7/EelwbzG1+0FwMXCQjVS9ebjD7oWHlB9Jr/2ARncZ OKcQ== X-Gm-Message-State: AOAM531U1vTMGqcEXwtxb4B2BJC2wmtDmRJdWNK0a0HLkFdOsvE5mAxE 6AFpEFAR33VvE2y2dsURJmosTORt+wmrzw== X-Google-Smtp-Source: ABdhPJz62+tr0gBEjvjtvpREDDfz9qvAzOorNmEFbcCk525lATOTsGWah6wsyZyjOkyk5rblspIchg== X-Received: by 2002:adf:f1c3:: with SMTP id z3mr21521370wro.375.1623151394740; Tue, 08 Jun 2021 04:23:14 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 13/26] configure, meson: convert liburing detection to meson Date: Tue, 8 Jun 2021 13:22:48 +0200 Message-Id: <20210608112301.402434-14-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x42b.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 28 ++++------------------------ meson.build | 9 +++++---- meson_options.txt | 2 ++ 3 files changed, 11 insertions(+), 28 deletions(-) diff --git a/configure b/configure index 8389a6f73f..ed62531416 100755 --- a/configure +++ b/configure @@ -315,7 +315,7 @@ xen=3D"$default_feature" xen_ctrl_version=3D"$default_feature" xen_pci_passthrough=3D"auto" linux_aio=3D"$default_feature" -linux_io_uring=3D"$default_feature" +linux_io_uring=3D"auto" cap_ng=3D"auto" attr=3D"auto" xfs=3D"$default_feature" @@ -1205,9 +1205,9 @@ for opt do ;; --enable-linux-aio) linux_aio=3D"yes" ;; - --disable-linux-io-uring) linux_io_uring=3D"no" + --disable-linux-io-uring) linux_io_uring=3D"disabled" ;; - --enable-linux-io-uring) linux_io_uring=3D"yes" + --enable-linux-io-uring) linux_io_uring=3D"enabled" ;; --disable-attr) attr=3D"disabled" ;; @@ -3334,21 +3334,6 @@ EOF linux_aio=3Dno fi fi -########################################## -# linux-io-uring probe - -if test "$linux_io_uring" !=3D "no" ; then - if $pkg_config liburing; then - linux_io_uring_cflags=3D$($pkg_config --cflags liburing) - linux_io_uring_libs=3D$($pkg_config --libs liburing) - linux_io_uring=3Dyes - else - if test "$linux_io_uring" =3D "yes" ; then - feature_not_found "linux io_uring" "Install liburing devel" - fi - linux_io_uring=3Dno - fi -fi =20 ########################################## # TPM emulation is only on POSIX @@ -5419,11 +5404,6 @@ fi if test "$linux_aio" =3D "yes" ; then echo "CONFIG_LINUX_AIO=3Dy" >> $config_host_mak fi -if test "$linux_io_uring" =3D "yes" ; then - echo "CONFIG_LINUX_IO_URING=3Dy" >> $config_host_mak - echo "LINUX_IO_URING_CFLAGS=3D$linux_io_uring_cflags" >> $config_host_mak - echo "LINUX_IO_URING_LIBS=3D$linux_io_uring_libs" >> $config_host_mak -fi if test "$vhost_scsi" =3D "yes" ; then echo "CONFIG_VHOST_SCSI=3Dy" >> $config_host_mak fi @@ -6070,7 +6050,7 @@ if test "$skip_meson" =3D no; then -Dcurl=3D$curl -Dglusterfs=3D$glusterfs -Dbzip2=3D$bzip2 -Dlibiscs= i=3D$libiscsi \ -Dlibnfs=3D$libnfs -Diconv=3D$iconv -Dcurses=3D$curses -Dlibudev= =3D$libudev\ -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ - -Dlibdaxctl=3D$libdaxctl -Dlibpmem=3D$libpmem \ + -Dlibdaxctl=3D$libdaxctl -Dlibpmem=3D$libpmem -Dlinux_io_uring=3D$= linux_io_uring \ -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt -Dauth_pa= m=3D$auth_pam \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ -Dattr=3D$attr -Ddefault_devices=3D$default_devices -Dvirglrendere= r=3D$virglrenderer \ diff --git a/meson.build b/meson.build index 8563443865..560b1739ec 100644 --- a/meson.build +++ b/meson.build @@ -327,10 +327,11 @@ if have_system or have_tools endif libaio =3D cc.find_library('aio', required: false) zlib =3D dependency('zlib', required: true, kwargs: static_kwargs) + linux_io_uring =3D not_found -if 'CONFIG_LINUX_IO_URING' in config_host - linux_io_uring =3D declare_dependency(compile_args: config_host['LINUX_I= O_URING_CFLAGS'].split(), - link_args: config_host['LINUX_IO_URI= NG_LIBS'].split()) +if not get_option('linux_io_uring').auto() or have_block + linux_io_uring =3D dependency('liburing', required: get_option('linux_io= _uring'), + method: 'pkg-config', kwargs: static_kwargs) endif libxml2 =3D not_found if 'CONFIG_LIBXML2' in config_host @@ -2799,7 +2800,7 @@ summary_info +=3D {'brlapi support': brlapi.found(= )} summary_info +=3D {'vde support': config_host.has_key('CONFIG_VDE')} summary_info +=3D {'netmap support': config_host.has_key('CONFIG_NETMAP= ')} summary_info +=3D {'Linux AIO support': config_host.has_key('CONFIG_LINUX_= AIO')} -summary_info +=3D {'Linux io_uring support': config_host.has_key('CONFIG_L= INUX_IO_URING')} +summary_info +=3D {'Linux io_uring support': linux_io_uring.found()} summary_info +=3D {'ATTR/XATTR support': libattr.found()} summary_info +=3D {'RDMA support': config_host.has_key('CONFIG_RDMA')} summary_info +=3D {'PVRDMA support': config_host.has_key('CONFIG_PVRDMA= ')} diff --git a/meson_options.txt b/meson_options.txt index b23174d0a1..6610c4dc64 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -92,6 +92,8 @@ option('libudev', type : 'feature', value : 'auto', description: 'Use libudev to enumerate host devices') option('libusb', type : 'feature', value : 'auto', description: 'libusb support for USB passthrough') +option('linux_io_uring', type : 'feature', value : 'auto', + description: 'Linux io_uring support') option('lzfse', type : 'feature', value : 'auto', description: 'lzfse support for DMG images') option('lzo', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152143; cv=none; d=zohomail.com; s=zohoarc; b=MgDuu9htqUx+kjXxFiI6ep5/6oQvfHTnmtGXIOTiLfhInmQeY4VarN2vLY0a3IwxsjBDEYjvM6fv3CWhLKDXWrJWNfhBVDlVSuAeM/u0aQDZhME0P/ldFkDDxXWYoK5Qcwxmtg86qwfhLDYa14FJYf/JvyLrTVlI7Gempctn9Wo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152143; h=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=3WUvE/j1VN+cbtn/hnsAUaevrPtRYFe5XER8HgZZZOI=; b=f4dxPsoZdS0/QUN3TUarmH9BZfKO8u0cV1B2qsk3IbrvcQ96duztRiCstP7ED33wL43JxMX9gmUbGJRWCEH1EaAHIuLqCwv/YZ27w3RSo6+ONsN7M/d4CsrK7hoe0FNpw79JWYQ3crb1iQeMmpSFJQhi3f7+ajIWQYhBYNOmXwo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152143295529.0802278878017; Tue, 8 Jun 2021 04:35:43 -0700 (PDT) Received: from localhost ([::1]:40672 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa1G-0006is-8G for importer2@patchew.org; Tue, 08 Jun 2021 07:35:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43632) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpJ-0006ig-7j for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:21 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:40520) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpF-000832-5F for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:18 -0400 Received: by mail-wr1-x429.google.com with SMTP id y7so16515623wrh.7 for ; Tue, 08 Jun 2021 04:23:16 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=3WUvE/j1VN+cbtn/hnsAUaevrPtRYFe5XER8HgZZZOI=; b=cpXdbEZPj0X+IPX+kTUcEqUTHZoKRwsdSG6Q18ANqHgOXiqMbfNu5oinjPABQl9TVV vC8eUX9mPkIeAf8fNDJc/DTkUzZSL9FoOVwBTfUKjf7YGvwMHQ6YaFbkGIe94DcnDXxU O3gqAJ6FQHw6cRh5dsmmzGqIqyp8xV76oMxMggSMXE/e5S5vhLD0o/xLk1M4Ikrj50GY ab9YKqcYKvPGtpza5uVcyAobHs2XiKgRNVdAwH+40atLGSQwizZ8hbikoImmVjJWx8Bp 0QVA1CGAHMTrGk5Rb8NqQDVc/D8uZxKFndVh5K4lpZMQKw/aUBqDDgPfs93dm9OmWRQl HsUQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=3WUvE/j1VN+cbtn/hnsAUaevrPtRYFe5XER8HgZZZOI=; b=jisTQXTSzMlivSujqq1bHmWhu6pm8RW9Q2i4LB8oeaSd6zkpn4WxfUFYNS/R96lWwf Zpx7JqKvteLX5eY2aIxbB+YCg+ZaMtf47P2QgUasbCKEJX75s/ByhzYvszKCyHRmkOHb 0tciaPlRgYdghWZVTUeYCUV5SrmNQZobxEuTrvP8mMOfs6upnv0JXXaWEkzkw3Vd+VWp 5QSqZXuCfMd3Dd4uybxMydSNG55rfJFiavfDJulxL063JPiKtQ4+8YyZLpo2rjuv/6/2 4LjJwzEm9AIU+OH4Kgy9O3M0g0lIUTdDM89aDYLwE63DhAsh3NeDKwqTCsuJk0lak/B5 JwCg== X-Gm-Message-State: AOAM530S6u+/fX02H7Irq3Eq9ZuEUYwZd63eAYj1LX2wI3ufM4b0ekuN 9M4AKCVEM0I09Ee/LgYmaOUYNMS09tW1sw== X-Google-Smtp-Source: ABdhPJz61BTOvxMEJicorhgQROk6pBED/0OFc4H9gp2IOw2W/fR9S4umwoAGH9V4oQbfLsrgWLJqUg== X-Received: by 2002:a5d:4dc4:: with SMTP id f4mr22084829wru.181.1623151395597; Tue, 08 Jun 2021 04:23:15 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 14/26] configure, meson: convert libxml2 detection to meson Date: Tue, 8 Jun 2021 13:22:49 +0200 Message-Id: <20210608112301.402434-15-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x429.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 29 ++++------------------------- meson.build | 8 ++++---- meson_options.txt | 2 ++ 3 files changed, 10 insertions(+), 29 deletions(-) diff --git a/configure b/configure index ed62531416..2c0f16488e 100755 --- a/configure +++ b/configure @@ -425,7 +425,7 @@ vdi=3D${default_feature:-yes} vvfat=3D${default_feature:-yes} qed=3D${default_feature:-yes} parallels=3D${default_feature:-yes} -libxml2=3D"$default_feature" +libxml2=3D"auto" debug_mutex=3D"no" libpmem=3D"auto" default_devices=3D"true" @@ -1419,9 +1419,9 @@ for opt do ;; --enable-numa) numa=3D"yes" ;; - --disable-libxml2) libxml2=3D"no" + --disable-libxml2) libxml2=3D"disabled" ;; - --enable-libxml2) libxml2=3D"yes" + --enable-libxml2) libxml2=3D"enabled" ;; --disable-tcmalloc) tcmalloc=3D"no" ;; @@ -3409,21 +3409,6 @@ EOF fi fi =20 -########################################## -# libxml2 probe -if test "$libxml2" !=3D "no" ; then - if $pkg_config --exists libxml-2.0; then - libxml2=3D"yes" - libxml2_cflags=3D$($pkg_config --cflags libxml-2.0) - libxml2_libs=3D$($pkg_config --libs libxml-2.0) - else - if test "$libxml2" =3D "yes"; then - feature_not_found "libxml2" "Install libxml2 devel" - fi - libxml2=3D"no" - fi -fi - # Check for inotify functions when we are building linux-user # emulator. This is done because older glibc versions don't # have syscall stubs for these implemented. In that case we @@ -5631,12 +5616,6 @@ if test "$have_rtnetlink" =3D "yes" ; then echo "CONFIG_RTNETLINK=3Dy" >> $config_host_mak fi =20 -if test "$libxml2" =3D "yes" ; then - echo "CONFIG_LIBXML2=3Dy" >> $config_host_mak - echo "LIBXML2_CFLAGS=3D$libxml2_cflags" >> $config_host_mak - echo "LIBXML2_LIBS=3D$libxml2_libs" >> $config_host_mak -fi - if test "$replication" =3D "yes" ; then echo "CONFIG_REPLICATION=3Dy" >> $config_host_mak fi @@ -6049,7 +6028,7 @@ if test "$skip_meson" =3D no; then -Dcapstone=3D$capstone -Dslirp=3D$slirp -Dfdt=3D$fdt -Dbrlapi=3D$b= rlapi \ -Dcurl=3D$curl -Dglusterfs=3D$glusterfs -Dbzip2=3D$bzip2 -Dlibiscs= i=3D$libiscsi \ -Dlibnfs=3D$libnfs -Diconv=3D$iconv -Dcurses=3D$curses -Dlibudev= =3D$libudev\ - -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse \ + -Drbd=3D$rbd -Dlzo=3D$lzo -Dsnappy=3D$snappy -Dlzfse=3D$lzfse -Dli= bxml2=3D$libxml2 \ -Dlibdaxctl=3D$libdaxctl -Dlibpmem=3D$libpmem -Dlinux_io_uring=3D$= linux_io_uring \ -Dgnutls=3D$gnutls -Dnettle=3D$nettle -Dgcrypt=3D$gcrypt -Dauth_pa= m=3D$auth_pam \ -Dzstd=3D$zstd -Dseccomp=3D$seccomp -Dvirtfs=3D$virtfs -Dcap_ng=3D= $cap_ng \ diff --git a/meson.build b/meson.build index 560b1739ec..28825dec18 100644 --- a/meson.build +++ b/meson.build @@ -334,9 +334,9 @@ if not get_option('linux_io_uring').auto() or have_block method: 'pkg-config', kwargs: static_kwargs) endif libxml2 =3D not_found -if 'CONFIG_LIBXML2' in config_host - libxml2 =3D declare_dependency(compile_args: config_host['LIBXML2_CFLAGS= '].split(), - link_args: config_host['LIBXML2_LIBS'].spli= t()) +if not get_option('libxml2').auto() or have_block + libxml2 =3D dependency('libxml-2.0', required: get_option('libxml2'), + method: 'pkg-config', kwargs: static_kwargs) endif libnfs =3D not_found if not get_option('libnfs').auto() or have_block @@ -2835,7 +2835,7 @@ summary_info +=3D {'bzip2 support': libbzip2.foun= d()} summary_info +=3D {'lzfse support': liblzfse.found()} summary_info +=3D {'zstd support': zstd.found()} summary_info +=3D {'NUMA host support': config_host.has_key('CONFIG_NUMA')} -summary_info +=3D {'libxml2': config_host.has_key('CONFIG_LIBXML= 2')} +summary_info +=3D {'libxml2': libxml2.found()} summary_info +=3D {'capstone': capstone_opt =3D=3D 'disabled' ? f= alse : capstone_opt} summary_info +=3D {'libpmem support': libpmem.found()} summary_info +=3D {'libdaxctl support': libdaxctl.found()} diff --git a/meson_options.txt b/meson_options.txt index 6610c4dc64..a9a9b8f4c6 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -92,6 +92,8 @@ option('libudev', type : 'feature', value : 'auto', description: 'Use libudev to enumerate host devices') option('libusb', type : 'feature', value : 'auto', description: 'libusb support for USB passthrough') +option('libxml2', type : 'feature', value : 'auto', + description: 'libxml2 support for Parallels image format') option('linux_io_uring', type : 'feature', value : 'auto', description: 'Linux io_uring support') option('lzfse', type : 'feature', value : 'auto', --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152007; cv=none; d=zohomail.com; s=zohoarc; b=aMwODwwlh3VhY4C5OfJLtLOhCgWB1RaLzqJ5491+F/8OSPhg7Hr9I7s2XMFA5QCEnb9t7/MTDDxoL5DazwM+JydM1GRpmwAD9z6kfjWQc7PHGgnCeOF6eofR6QvxD2u3MB1Pq4a1HI6uJE+CHOuB9HyIdzSJfiOrj9DVSYkZ/88= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152007; h=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=C9phMDSl+z0yBs8xiAAqnb7izn5gBQT6DdDlqQBBBhs=; b=HP+aRpkM7kUtJs7rdHxpdd3Ni/zmSf8wjaQOko5Ed21HYeu2dsG3XgqRevrIDNs5+v3/zpLV7fuVEitM/H3OToKNhDR4FCVSOlYB/dhjPBvYDlGYw6kW/b3NXuhP7ivN8VvohzfenB76ISRFYoVHzGzgNbJKIL1aD6gBgvYu9ew= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152007863933.584036697659; Tue, 8 Jun 2021 04:33:27 -0700 (PDT) Received: from localhost ([::1]:60482 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZz3-0001BI-Ob for importer2@patchew.org; Tue, 08 Jun 2021 07:33:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43630) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpJ-0006iL-7R for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:21 -0400 Received: from mail-wr1-x436.google.com ([2a00:1450:4864:20::436]:42725) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpG-00083A-3h for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:19 -0400 Received: by mail-wr1-x436.google.com with SMTP id c5so21119148wrq.9 for ; Tue, 08 Jun 2021 04:23:17 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=C9phMDSl+z0yBs8xiAAqnb7izn5gBQT6DdDlqQBBBhs=; b=oVdTgN7TYqFx2CWBlESxLR0Q1o9SKrQ3QHc+5hDQS2GmEiW79RGoBxyjacXPB2jC34 0PeBTcUwciNWXyIo4Z9XFfkKHUE38LQd0QB+lr27bMPUSjASxNqGxAQznzC+SJoMcL+h aw9IewWTmU2Cgm5CixUrgCheB4qoyE9x9VgG+3hJt9PZc675DP6K8vUTo9VlsG1CshSw r8kVUu1wE9Y9+zNL4AL4tTIQALWORxXKLcslCYTtaphWmbVrDwLEzkDsjQU5sE7nYl4+ 0ClmT5b4QSQ6e7pyeXuylIULH45n0hpStecgssIOdQ8dF7L7REdwsTUXoRoxCrH21/fQ M/TA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=C9phMDSl+z0yBs8xiAAqnb7izn5gBQT6DdDlqQBBBhs=; b=i9D8C2CUnBQJWqQTQPOHDpULZYi8fXLqYZrSwz5FWdWQyX2MVf7WTxkkzceRILL7mn za+PZ8IMiGU95XVVgAX/ssgtvXWVrN3lpyAWyfCEXfuiZHZxQ2mgo2xsGIEgto0jbsEy mGe1PoHmLtcBDAOCziPLDaFcltMfmsILKFpiFjFeN5ftknx9F6ZPs7GFFC0C2OmCh1D1 9NwbbRlJY51dm/h+CB35u6mWK6DKFz/IGrQZoln8joJIgFqeBT+el75aIiUiLNJbIt2c lMN8cBKu4kJToca/Q/6HJ0mQTG+M+ZucGnYFed9o176eoVHDdXCKVRm8b4w+Z7iUBvXg aZ3A== X-Gm-Message-State: AOAM53089YaKn/FzLDlkUwEXILHCQ2UrBtHgPknqMTcBCZGYEe5wSShL rn/gu8YfU+35svW0GuvEi6hL6iwuXVc3yQ== X-Google-Smtp-Source: ABdhPJyit3q77/qphMF0rFFcx4bhc6+CrX1+YMAGHxpG58M7NJT/75yPNaDCtoVRzZQzu9+YCTaphw== X-Received: by 2002:adf:b648:: with SMTP id i8mr15700042wre.425.1623151396723; Tue, 08 Jun 2021 04:23:16 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 15/26] meson: sort header tests Date: Tue, 8 Jun 2021 13:22:50 +0200 Message-Id: <20210608112301.402434-16-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::436; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x436.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- meson.build | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/meson.build b/meson.build index 28825dec18..5fdb757751 100644 --- a/meson.build +++ b/meson.build @@ -1258,16 +1258,17 @@ config_host_data.set('QEMU_VERSION_MAJOR', meson.pr= oject_version().split('.')[0] config_host_data.set('QEMU_VERSION_MINOR', meson.project_version().split('= .')[1]) config_host_data.set('QEMU_VERSION_MICRO', meson.project_version().split('= .')[2]) =20 +config_host_data.set('HAVE_HOST_BLOCK_DEVICE', have_host_block_device) + config_host_data.set('HAVE_BTRFS_H', cc.has_header('linux/btrfs.h')) config_host_data.set('HAVE_DRM_H', cc.has_header('libdrm/drm.h')) config_host_data.set('HAVE_PTY_H', cc.has_header('pty.h')) +config_host_data.set('HAVE_SYS_DISK_H', cc.has_header('sys/disk.h')) config_host_data.set('HAVE_SYS_IOCCOM_H', cc.has_header('sys/ioccom.h')) config_host_data.set('HAVE_SYS_KCOV_H', cc.has_header('sys/kcov.h')) -config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', pre= fix: '#include ')) -config_host_data.set('HAVE_HOST_BLOCK_DEVICE', have_host_block_device) -config_host_data.set('HAVE_SYS_DISK_H', cc.has_header('sys/disk.h')) =20 config_host_data.set('CONFIG_PREADV', cc.has_function('preadv', prefix: '#= include ')) +config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', pre= fix: '#include ')) =20 ignored =3D ['CONFIG_QEMU_INTERP_PREFIX'] # actually per-target arrays =3D ['CONFIG_AUDIO_DRIVERS', 'CONFIG_BDRV_RW_WHITELIST', 'CONFIG_BD= RV_RO_WHITELIST'] --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152272; cv=none; d=zohomail.com; s=zohoarc; b=PMUReGdFboKpxQeXnuOTXEq6ZBaMQsKIW92OePc3V7uV0/TlzMVvCkJbOQoLHqbmE+j9u1F1A0nHwfJEzc/C5Gn/KKhzeQ9u9J2YnkXlT5QF6fBRSxnJ/lTHdemGig3puueOEF3ZziAWO2QTSzhQYIhBZ2p8EAKW4GfaLP+bETE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152272; h=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=FO5Bdi+1PC20U6f9IU1bMuvi0kdwjXBOHixBHmCvksI=; b=kZRUa9HMerbv1iGRc1AgME5gOX7auIJZYAhKEDDfYTBVnxWAY0xsUUdTCOJCnBjY6LyZPhD8Jl8RZXDYzIyZ3gNFeRO9xtQuOhEsH9hLu/IJm5FDzT6WYx47UaS4EcrBBoBXUiY6AmX3XD2cWDMAQdkw/tERpX+XTjrJ45Jtkbs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152272701224.57632464581297; Tue, 8 Jun 2021 04:37:52 -0700 (PDT) Received: from localhost ([::1]:47232 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa3L-0002nq-OM for importer2@patchew.org; Tue, 08 Jun 2021 07:37:51 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43680) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpL-0006lx-8a for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:23 -0400 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]:51955) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpI-00083q-VX for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:22 -0400 Received: by mail-wm1-x335.google.com with SMTP id l9so1610124wms.1 for ; Tue, 08 Jun 2021 04:23:18 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=FO5Bdi+1PC20U6f9IU1bMuvi0kdwjXBOHixBHmCvksI=; b=uVVvaIx/RcOXQgwBu/KNxG7mSoHJKFV1F93Q7uSlpHSZo42Rd7CIP0z0LUc9kPbjyb wj/X1PwrNl4hWOzTUa5cN5MdhQihqXxe86szYvwZA8iY+IHuPebhzvniCzx8ivLKnCks KMq6hWnBoPMjBY7VaPAielNa5nmX7NqhZ8Jnymggg2mcJgMmpLEY+8zwNJUDeAFnw5DC j3qNwblS4US8Q/ARMzixjgHGDXwEEx8aaX/exbOgZjYvZDZm55yibO7DC8EGMxkrtB5Y TPXJfkaYeGPzPfQlYetfMkmJsEpCKhh+oN8uCtz2L+SpMOtk9Ehk3SiOW05moO/pGNya Hf9Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=FO5Bdi+1PC20U6f9IU1bMuvi0kdwjXBOHixBHmCvksI=; b=kY05Bh6AvI8jVrj09q9YnypVTgwWaR/bE2DU7AB5wUNA6JbNYElNez9VvcU/XPvvX8 yvr3OmSZnO1EIN4PKOlRvpc05hY/+29TK8G0tmCfmt+8gHchBPs1szqAADnbGwHoEQEJ CQTO6R4SL0Tg8sgT+dqpotzg9ewGFUrFz6Piv01aBFajhubIP6/NyPs7fbyicoJNXS43 t11IkvYSCyPLE3WFb3CfZlivihs8oodOCcQxh1xQpsGRj1FVbCUU7B6YWaXUBTrf1TnK usVOdfXML554QUePqXcESioEzCQOhXWKaP1VDKc1Gz68heZSRHvVyOYoC6hwtiKpWy67 seAw== X-Gm-Message-State: AOAM5322OMMh6PePxvKK7T6hXgGktG4kTGUZmf8B4w4UVSk3Ui72ur0E mIeg6y/ZXqCc8F+VQZan+OsWEogt4OVc2A== X-Google-Smtp-Source: ABdhPJwXQHEGMyQAYrOkhkNiAEbzch+33LGKv0PubVzMPhompSHZOkvjtH8iQe73jPIfaNYhdDbgiQ== X-Received: by 2002:a05:600c:1c0b:: with SMTP id j11mr21772881wms.139.1623151397572; Tue, 08 Jun 2021 04:23:17 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 16/26] meson: remove preadv from summary Date: Tue, 8 Jun 2021 13:22:51 +0200 Message-Id: <20210608112301.402434-17-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x335.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Meson is more verbose than the configure script; the outcome of the preadv = test can be found in its output and it is not worth including it again in the su= mmary. Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- meson.build | 1 - 1 file changed, 1 deletion(-) diff --git a/meson.build b/meson.build index 5fdb757751..38f6f193f5 100644 --- a/meson.build +++ b/meson.build @@ -2657,7 +2657,6 @@ summary_info +=3D {'PIE': get_option('b= _pie')} summary_info +=3D {'static build': config_host.has_key('CONFIG_STATIC= ')} summary_info +=3D {'malloc trim support': has_malloc_trim} summary_info +=3D {'membarrier': config_host.has_key('CONFIG_MEMBAR= RIER')} -summary_info +=3D {'preadv support': config_host_data.get('CONFIG_PREAD= V')} summary_info +=3D {'fdatasync': config_host.has_key('CONFIG_FDATAS= YNC')} summary_info +=3D {'madvise': config_host.has_key('CONFIG_MADVIS= E')} summary_info +=3D {'posix_madvise': config_host.has_key('CONFIG_POSIX_= MADVISE')} --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152503; cv=none; d=zohomail.com; s=zohoarc; b=VlQqvJ9oTwR+HNUuJ8J6ddRZlJVuqh3hdO+6m8MbIji97I01UZlbBDYlG6U/NIncqEfPAF2/S1YrMw1lRKdDNwnsi4TtoSRNWE7o11Ga8LN9hwgzxYxDAxuaChNeTLwz91AsQdfpWAovAPoPiqZ6yCNFoWUnCGteirEEluX1Gq4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152503; h=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=QxIxKqTJzlnO5FbyAsTgEah7iNWff4xl/B3WeX6eUjg=; b=TvNqu5oevFe5Ck9RbVZqfjdJ9cML9QBF5OGptTOLF4W4Eo2C0siMR3elW5eii7+O788NQwVmGsJy9/N0BzG2trF/mgOKiq2QDaSPscnC0u35UVwsqdNetsO4HyLi2jIEgkpXASlkkeuWRUHf4RUFRAfRGlAy67iatb6UJG/9hhY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152503146396.9109503425192; Tue, 8 Jun 2021 04:41:43 -0700 (PDT) Received: from localhost ([::1]:54600 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa73-0007gW-Sy for importer2@patchew.org; Tue, 08 Jun 2021 07:41:41 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43686) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpL-0006nQ-Oj for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:23 -0400 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]:38588) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpI-000847-Vx for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:23 -0400 Received: by mail-wm1-x332.google.com with SMTP id t4-20020a1c77040000b029019d22d84ebdso1673874wmi.3 for ; Tue, 08 Jun 2021 04:23:19 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.17 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=QxIxKqTJzlnO5FbyAsTgEah7iNWff4xl/B3WeX6eUjg=; b=qhBlSGE9FjUpoNHuz+uTZYs0BE/57HKNEbjJqf3W51EEww7+RXk9/q8xE+oRPUhDKy 84gpraOaHJ8eWJTl3wzwSkkNfZQy0svf3IoJRPBl2hloOE/lxIX9C/vNbJAV84sWQujs PM4vLwF5PH4nXDp3iU7qHmbvNOOK1cXyAjR6eT/MV4IIjfgwlH1ZQ47DQYr75z8m9oDj alzIB2U1WNDxrQO5JiX5Dma20jxQmAmXkhFhEn80O73whS2ZvEiqiNE7t+jSg173sEaB xikyn2l1DKPx5Wwvr/F5tysA+8uZKWpG4LBMJ9aEBzuUF/GwlKG3UciLNyrTCaO7ggCR Tf5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=QxIxKqTJzlnO5FbyAsTgEah7iNWff4xl/B3WeX6eUjg=; b=sB4QCGzSwtSVYeCZNdywDJjkj6y0l8Zw69Tg9g8LaxEnOuH8HOy6PON5eWWMLxUQgj Z6PjuhRc0ock3VCx3kIjZR4Yb6snBaUdwNvzGYf4i0r336T0s8KTA1CzbVXYUg0YUkEm G/P4gwM5sxuE6mW+0RJy87kIoHjyX54srtzLLW37U2rROo3OZrneP5pqzCPgOam0VS6d nxqqgCd6T+BQrn0VLNp5Sc1ec0FUjFe1ElYLXHD9uC+YAvQsIYy94dhMEl61U3b4UgLP hIsS9AGZTgSroMSh0lpN9PBeK2NLKW4osLceTCO2b38vINByiTBadEL3WmKzmihRwscM FQmA== X-Gm-Message-State: AOAM531JNtl1l0Fnq0pE4hnfZblJxgyp74n9Y0Y8Cewa5C6pQWrslFwl SpUn/wfHUIOSpLPURtsn2jt3BJnOsWW9eQ== X-Google-Smtp-Source: ABdhPJzUqceDE1FXqvmax75LvK2u2g+lx/roHLfJkgYGLINVWncqww8rm3ksmFP+c2mkGMx/SbgExA== X-Received: by 2002:a05:600c:1c28:: with SMTP id j40mr3722757wms.102.1623151398307; Tue, 08 Jun 2021 04:23:18 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 17/26] configure, meson: move CONFIG_IVSHMEM to meson Date: Tue, 8 Jun 2021 13:22:52 +0200 Message-Id: <20210608112301.402434-18-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::332; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x332.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" This is a duplicate of CONFIG_EVENTFD, handle it directly in meson.build. Signed-off-by: Paolo Bonzini --- configure | 8 -------- docs/devel/kconfig.rst | 2 +- meson.build | 5 +++-- 3 files changed, 4 insertions(+), 11 deletions(-) diff --git a/configure b/configure index 2c0f16488e..c95259435f 100755 --- a/configure +++ b/configure @@ -5038,11 +5038,6 @@ if test "$mingw32" =3D "yes" ; then done fi =20 -# We can only support ivshmem if we have eventfd -if [ "$eventfd" =3D "yes" ]; then - ivshmem=3Dyes -fi - # Probe for guest agent support/options =20 if [ "$guest_agent" !=3D "no" ]; then @@ -5638,9 +5633,6 @@ fi if test "$have_getrandom" =3D "yes" ; then echo "CONFIG_GETRANDOM=3Dy" >> $config_host_mak fi -if test "$ivshmem" =3D "yes" ; then - echo "CONFIG_IVSHMEM=3Dy" >> $config_host_mak -fi if test "$debug_mutex" =3D "yes" ; then echo "CONFIG_DEBUG_MUTEX=3Dy" >> $config_host_mak fi diff --git a/docs/devel/kconfig.rst b/docs/devel/kconfig.rst index cb2d7ffac0..a1cdbec751 100644 --- a/docs/devel/kconfig.rst +++ b/docs/devel/kconfig.rst @@ -303,5 +303,5 @@ variable:: host_kconfig =3D \ ('CONFIG_TPM' in config_host ? ['CONFIG_TPM=3Dy'] : []) + \ ('CONFIG_SPICE' in config_host ? ['CONFIG_SPICE=3Dy'] : []) + \ - ('CONFIG_IVSHMEM' in config_host ? ['CONFIG_IVSHMEM=3Dy'] : []) + \ + (have_ivshmem ? ['CONFIG_IVSHMEM=3Dy'] : []) + \ ... diff --git a/meson.build b/meson.build index 38f6f193f5..3be3ef0982 100644 --- a/meson.build +++ b/meson.build @@ -1337,10 +1337,11 @@ if link_language =3D=3D 'cpp' } endif =20 +have_ivshmem =3D config_host.has_key('CONFIG_EVENTFD') host_kconfig =3D \ ('CONFIG_TPM' in config_host ? ['CONFIG_TPM=3Dy'] : []) + \ ('CONFIG_SPICE' in config_host ? ['CONFIG_SPICE=3Dy'] : []) + \ - ('CONFIG_IVSHMEM' in config_host ? ['CONFIG_IVSHMEM=3Dy'] : []) + \ + (have_ivshmem ? ['CONFIG_IVSHMEM=3Dy'] : []) + \ ('CONFIG_OPENGL' in config_host ? ['CONFIG_OPENGL=3Dy'] : []) + \ (x11.found() ? ['CONFIG_X11=3Dy'] : []) + \ ('CONFIG_VHOST_USER' in config_host ? ['CONFIG_VHOST_USER=3Dy'] : []) + \ @@ -2499,7 +2500,7 @@ if have_tools install: true) endif =20 - if 'CONFIG_IVSHMEM' in config_host + if have_ivshmem subdir('contrib/ivshmem-client') subdir('contrib/ivshmem-server') endif --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152135; cv=none; d=zohomail.com; s=zohoarc; b=Uoopht9DD+hbtLheXdZk3lFLBcfYTkjwwx3i0J2XuyvUoa2mjP7bpRg0y97932TYdzyMmkdpTVYgcz152fPIpmXpLW7/TcuGyM4IwYYLv+Krg0IeJuiSLWptRj8UcN7GQkhBjbPaRsl5ijhCVdQ+2AqShzKudths6rvNq/pR3vw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152135; h=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=NFLOcSjovIsq0rrJu+JQcv0N5noAupJu88dEwIvRBvs=; b=CQfN/x2BP0niK0l8w3GHzINLHOVr8Er/EmsONBM8C2R3GJl0N1/DbD2R8Znyhe4qli04wXezAffxKe7CstFYWEEbJ7YELbF/Hjupw0Cw87XKNRFZldIB6v2mJSqO3eWo0kWn5//bFq+mXCTGQMrTdsREv2eAkpn6wgLISxTAkfU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152135016258.46405023631064; Tue, 8 Jun 2021 04:35:35 -0700 (PDT) Received: from localhost ([::1]:40260 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa17-0006SF-LS for importer2@patchew.org; Tue, 08 Jun 2021 07:35:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43678) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpL-0006lv-8g for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:23 -0400 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]:53046) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpI-00084D-VU for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:22 -0400 Received: by mail-wm1-x333.google.com with SMTP id f17so1604981wmf.2 for ; Tue, 08 Jun 2021 04:23:20 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=NFLOcSjovIsq0rrJu+JQcv0N5noAupJu88dEwIvRBvs=; b=k7lwZJxT+tGDa0Kp5wJ2ioyIX3cNdBXbn7Nk6/MFhDZyRrASb0uYwJVRRtOIT3MTKy +2EeFALgP79J7rHV82HybsH3k1ixkw4KqZiKVREXQzSoLGcWw1ro8X8vdGHpDuGWFnKr GhpPlYUUusk60/+GDZFT41o3w4sSbTIyPeM1iQhZ5IqJh7UhD4VTsxLK6ME/aV7qj82o muMZ4PFPclOcZTb+mhsmXpR49LG0RdxkVuwQAFhTkVQ8hqz3xsUrLytTVCYAn7U1n4rh dP0MCbXWX/Naom38SpecWwdSs25LO384t/XO1HLR1d1lixSEKsi/Yf66FiuZat00gEC6 8Xog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=NFLOcSjovIsq0rrJu+JQcv0N5noAupJu88dEwIvRBvs=; b=dyGPCV5SMvzIspdQvMpwWP0Osoi3qeHBVifrlN7iIbI49UNzxHz0DHXlOFSGCPEhwR 3+7hbKYUYm5ctOBav8ezClTvok4Nv2af0m3x9ZoJ6t6ALGKWQsgeN/7aVb6FLdBEKCKs ozSe6Jy5xHEmRS4fuBazDLHO6pe/b0qPzDci9lmxJ6tx5ZmbwZA7kNPcH2GOtQs2JFRz NrqtTB6sKtcHKAHCCWBuosK9APR6Es6wwkyS3fxajjAbPh1QzfIopcYEf8VN+CygrZjz oOgxFk7mlLuQKRY+QJCu66xLnsjQMowbWtHG9EWyqgzlaRjQLHWWH3kbcNb06QKRglyg 0QWQ== X-Gm-Message-State: AOAM533iMMB6g/tOpBvrJQJB9nvAmoPA381c/nBeZIqhN6fe+M1JTIha tzRjetuC6umAYrHQCLrulj3oW/wNWIussA== X-Google-Smtp-Source: ABdhPJxAofrY7Ll0s4AavDjEgeIh+vE8iQbv2Vc2tsNIXJ025g/lQPnvmLLqyvHkSrTaBh7WDJvxdQ== X-Received: by 2002:a1c:9a45:: with SMTP id c66mr16649376wme.43.1623151399243; Tue, 08 Jun 2021 04:23:19 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 18/26] configure: convert HAVE_BROKEN_SIZE_MAX to meson Date: Tue, 8 Jun 2021 13:22:53 +0200 Message-Id: <20210608112301.402434-19-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::333; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x333.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini --- configure | 17 ----------------- meson.build | 9 +++++++++ 2 files changed, 9 insertions(+), 17 deletions(-) diff --git a/configure b/configure index c95259435f..e11174f810 100755 --- a/configure +++ b/configure @@ -2375,20 +2375,6 @@ if test "$softmmu" =3D "no"; then audio_drv_list=3D"" fi =20 -########################################## -# Some versions of Mac OS X incorrectly define SIZE_MAX -cat > $TMPC << EOF -#include -#include -int main(int argc, char *argv[]) { - return printf("%zu", SIZE_MAX); -} -EOF -have_broken_size_max=3Dno -if ! compile_object -Werror ; then - have_broken_size_max=3Dyes -fi - ########################################## # L2TPV3 probe =20 @@ -5358,9 +5344,6 @@ if test "$gdbus_codegen" !=3D "" ; then echo "GDBUS_CODEGEN=3D$gdbus_codegen" >> $config_host_mak fi echo "CONFIG_TLS_PRIORITY=3D\"$tls_priority\"" >> $config_host_mak -if test "$have_broken_size_max" =3D "yes" ; then - echo "HAVE_BROKEN_SIZE_MAX=3Dy" >> $config_host_mak -fi if test "$have_openpty" =3D "yes" ; then echo "HAVE_OPENPTY=3Dy" >> $config_host_mak fi diff --git a/meson.build b/meson.build index 3be3ef0982..2a19f6c1bd 100644 --- a/meson.build +++ b/meson.build @@ -1270,6 +1270,15 @@ config_host_data.set('HAVE_SYS_KCOV_H', cc.has_heade= r('sys/kcov.h')) config_host_data.set('CONFIG_PREADV', cc.has_function('preadv', prefix: '#= include ')) config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', pre= fix: '#include ')) =20 +# Some versions of Mac OS X incorrectly define SIZE_MAX +config_host_data.set('HAVE_BROKEN_SIZE_MAX', not cc.compiles(''' + #include + #include + int main(int argc, char *argv[]) { + return printf("%zu", SIZE_MAX); + }''', args: ['-Werror'])) + + ignored =3D ['CONFIG_QEMU_INTERP_PREFIX'] # actually per-target arrays =3D ['CONFIG_AUDIO_DRIVERS', 'CONFIG_BDRV_RW_WHITELIST', 'CONFIG_BD= RV_RO_WHITELIST'] strings =3D ['HOST_DSOSUF', 'CONFIG_IASL'] --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623151931; cv=none; d=zohomail.com; s=zohoarc; b=WXJRZtl4kNOkhMPzHy0vsqc7ivATO6rNtkqKVB4IdXapmwb1CttZF0CBSErmpf9CYFx376552bAhxywRzqcQAEp/AkJmgs496UjE9d8tUAfy03T6G+E0MsFgv5sALqO/CUmnuVvMiflcn/v1cOzDJUZqDeujjNwtrrJzmYGiQCg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623151931; h=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=seFU97Ec+z34tB6wgE87ei/l5SBOcKQS3T1ahUNKdmE=; b=mdbcnLBf9ry0eNoAwfS6+PKBjZgFGM2XJ3xOUwL0v1djN6yVn3XTL81SUQgZbpmefl3Hlzy2RReDOa0o306g2kV+oz8LKamvz1ucVIzj3hUvah69o4wwL2Zi42yTdNm+1oasLRKQNZ/neaG0J80g33VKu92j6ts6T0G5czKIr3M= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623151931571395.2452020968211; Tue, 8 Jun 2021 04:32:11 -0700 (PDT) Received: from localhost ([::1]:55240 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZxq-00067l-AP for importer2@patchew.org; Tue, 08 Jun 2021 07:32:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43728) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpN-0006sd-At for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:25 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:35358) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpJ-00084N-Rw for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:25 -0400 Received: by mail-wr1-x434.google.com with SMTP id m18so21173928wrv.2 for ; Tue, 08 Jun 2021 04:23:21 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=seFU97Ec+z34tB6wgE87ei/l5SBOcKQS3T1ahUNKdmE=; b=g/iaW/YGHSNM1KZWKE3VckcPICWBFr4sqMp4yoDZsWD96j1vgtJnCXJ8SOb+pLkUYM 3gQOHFUMowhaSu9pDovf7E3V7FqgGdcsvBd3wrhqyk+2Ikn+uE1JfxFoFD5JDHDnuJbI Mq7P+UZdBhHg1WYTAHGqNi2kHW/xDxIzy7OWr8OoZTGxYkqoJXqowuwPK+3/tJX4+XTg 6fxFfpsTfGBVUeu02OmjuDYOCQir8d0ghteJPUnDsJr4gMNGGsGU7pHmvmxI25c34X8e 1tHZZyrALpjmL7uBhXvrdmBt3mpvSvhRV1kBJYL/DA/493d+DIaTWH3JF+S9brpKx+BF xSYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=seFU97Ec+z34tB6wgE87ei/l5SBOcKQS3T1ahUNKdmE=; b=QcBXzLtxDZb4abfQ4uOBArzJkDQz4rYrLYgZ/5cGJ6icNROapxCmS3a/wUC00zQVOV 1+P0vQnyBQ9MViTJivbXEe3se02aPlB2Myw9P1YOLbsnMUbB7BP/BJAoLbAlGDTAX8fr cy4IzRMW9v/YkFK8fBpBDOxjYsAtPDMYoetL7rDrSnDl9t0yOKq6CV+x7A1ykYmSaBoq Wdd58NBfYYTnyXJ79QGByaw1BgnhjHIVo+tXW2IgLb0ov0BlLME7G9BWhys5j0V+Unmr 1tSPz+XWJ2B02R34viFXCc7dwVLwJMX6IQfyjar8mSeZSX0gLTJKNQmG+ASLTGouWKbJ HOeQ== X-Gm-Message-State: AOAM531Bl5JZbFsUiva0GiOzrs4B9sHW/KupICZcpfIGWxZqzm80OO0f KQMPw2AhiZH4AFXBdwn4vxZ2zuyvqnFSFA== X-Google-Smtp-Source: ABdhPJw/TJxqmA0wv++P7GLg8o2y1HJNzlREBwqFY2eSaHMb465BihsvOB1VR6Qg9kg+0xLAj6uVIQ== X-Received: by 2002:a05:6000:508:: with SMTP id a8mr22022945wrf.315.1623151400187; Tue, 08 Jun 2021 04:23:20 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 19/26] configure: convert compiler tests to meson, part 1 Date: Tue, 8 Jun 2021 13:22:54 +0200 Message-Id: <20210608112301.402434-20-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::434; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x434.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini --- configure | 348 --------------------------------------------- meson.build | 35 ++++- ui/vnc-auth-sasl.c | 2 +- util/meson.build | 4 +- 4 files changed, 38 insertions(+), 351 deletions(-) diff --git a/configure b/configure index e11174f810..b16c84ca74 100755 --- a/configure +++ b/configure @@ -3588,297 +3588,6 @@ EOF fi fi =20 -# check for fallocate -fallocate=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - fallocate(0, 0, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - fallocate=3Dyes -fi - -# check for fallocate hole punching -fallocate_punch_hole=3Dno -cat > $TMPC << EOF -#include -#include - -int main(void) -{ - fallocate(0, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - fallocate_punch_hole=3Dyes -fi - -# check that fallocate supports range zeroing inside the file -fallocate_zero_range=3Dno -cat > $TMPC << EOF -#include -#include - -int main(void) -{ - fallocate(0, FALLOC_FL_ZERO_RANGE, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - fallocate_zero_range=3Dyes -fi - -# check for posix_fallocate -posix_fallocate=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - posix_fallocate(0, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - posix_fallocate=3Dyes -fi - -# check for sync_file_range -sync_file_range=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - sync_file_range(0, 0, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - sync_file_range=3Dyes -fi - -# check for linux/fiemap.h and FS_IOC_FIEMAP -fiemap=3Dno -cat > $TMPC << EOF -#include -#include -#include - -int main(void) -{ - ioctl(0, FS_IOC_FIEMAP, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - fiemap=3Dyes -fi - -# check for dup3 -dup3=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - dup3(0, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - dup3=3Dyes -fi - -# check for ppoll support -ppoll=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - struct pollfd pfd =3D { .fd =3D 0, .events =3D 0, .revents =3D 0 }; - ppoll(&pfd, 1, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - ppoll=3Dyes -fi - -# check for prctl(PR_SET_TIMERSLACK , ... ) support -prctl_pr_set_timerslack=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - prctl(PR_SET_TIMERSLACK, 1, 0, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - prctl_pr_set_timerslack=3Dyes -fi - -# check for epoll support -epoll=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - epoll_create(0); - return 0; -} -EOF -if compile_prog "" "" ; then - epoll=3Dyes -fi - -# epoll_create1 is a later addition -# so we must check separately for its presence -epoll_create1=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - /* Note that we use epoll_create1 as a value, not as - * a function being called. This is necessary so that on - * old SPARC glibc versions where the function was present in - * the library but not declared in the header file we will - * fail the configure check. (Otherwise we will get a compiler - * warning but not an error, and will proceed to fail the - * qemu compile where we compile with -Werror.) - */ - return (int)(uintptr_t)&epoll_create1; -} -EOF -if compile_prog "" "" ; then - epoll_create1=3Dyes -fi - -# check for sendfile support -sendfile=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - return sendfile(0, 0, 0, 0); -} -EOF -if compile_prog "" "" ; then - sendfile=3Dyes -fi - -# check for timerfd support (glibc 2.8 and newer) -timerfd=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - return(timerfd_create(CLOCK_REALTIME, 0)); -} -EOF -if compile_prog "" "" ; then - timerfd=3Dyes -fi - -# check for setns and unshare support -setns=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - int ret; - ret =3D setns(0, 0); - ret =3D unshare(0); - return ret; -} -EOF -if compile_prog "" "" ; then - setns=3Dyes -fi - -# clock_adjtime probe -clock_adjtime=3Dno -cat > $TMPC < -#include - -int main(void) -{ - return clock_adjtime(0, 0); -} -EOF -clock_adjtime=3Dno -if compile_prog "" "" ; then - clock_adjtime=3Dyes -fi - -# syncfs probe -syncfs=3Dno -cat > $TMPC < - -int main(void) -{ - return syncfs(0); -} -EOF -syncfs=3Dno -if compile_prog "" "" ; then - syncfs=3Dyes -fi - -# Search for bswap_32 function -byteswap_h=3Dno -cat > $TMPC << EOF -#include -int main(void) { return bswap_32(0); } -EOF -if compile_prog "" "" ; then - byteswap_h=3Dyes -fi - -# Search for bswap32 function -bswap_h=3Dno -cat > $TMPC << EOF -#include -#include -#include -int main(void) { return bswap32(0); } -EOF -if compile_prog "" "" ; then - bswap_h=3Dyes -fi - -# Check whether we have openpty() in either libc or libutil -cat > $TMPC << EOF -extern int openpty(int *am, int *as, char *name, void *termp, void *winp); -int main(void) { return openpty(0, 0, 0, 0, 0); } -EOF - -have_openpty=3D"no" -if compile_prog "" "" ; then - have_openpty=3D"yes" -else - if compile_prog "" "-lutil" ; then - have_openpty=3D"yes" - fi -fi - ########################################## # spice probe if test "$spice_protocol" !=3D "no" ; then @@ -5266,54 +4975,6 @@ fi if test "$have_usbfs" =3D "yes" ; then echo "CONFIG_USBFS=3Dy" >> $config_host_mak fi -if test "$fallocate" =3D "yes" ; then - echo "CONFIG_FALLOCATE=3Dy" >> $config_host_mak -fi -if test "$fallocate_punch_hole" =3D "yes" ; then - echo "CONFIG_FALLOCATE_PUNCH_HOLE=3Dy" >> $config_host_mak -fi -if test "$fallocate_zero_range" =3D "yes" ; then - echo "CONFIG_FALLOCATE_ZERO_RANGE=3Dy" >> $config_host_mak -fi -if test "$posix_fallocate" =3D "yes" ; then - echo "CONFIG_POSIX_FALLOCATE=3Dy" >> $config_host_mak -fi -if test "$sync_file_range" =3D "yes" ; then - echo "CONFIG_SYNC_FILE_RANGE=3Dy" >> $config_host_mak -fi -if test "$fiemap" =3D "yes" ; then - echo "CONFIG_FIEMAP=3Dy" >> $config_host_mak -fi -if test "$dup3" =3D "yes" ; then - echo "CONFIG_DUP3=3Dy" >> $config_host_mak -fi -if test "$ppoll" =3D "yes" ; then - echo "CONFIG_PPOLL=3Dy" >> $config_host_mak -fi -if test "$prctl_pr_set_timerslack" =3D "yes" ; then - echo "CONFIG_PRCTL_PR_SET_TIMERSLACK=3Dy" >> $config_host_mak -fi -if test "$epoll" =3D "yes" ; then - echo "CONFIG_EPOLL=3Dy" >> $config_host_mak -fi -if test "$epoll_create1" =3D "yes" ; then - echo "CONFIG_EPOLL_CREATE1=3Dy" >> $config_host_mak -fi -if test "$sendfile" =3D "yes" ; then - echo "CONFIG_SENDFILE=3Dy" >> $config_host_mak -fi -if test "$timerfd" =3D "yes" ; then - echo "CONFIG_TIMERFD=3Dy" >> $config_host_mak -fi -if test "$setns" =3D "yes" ; then - echo "CONFIG_SETNS=3Dy" >> $config_host_mak -fi -if test "$clock_adjtime" =3D "yes" ; then - echo "CONFIG_CLOCK_ADJTIME=3Dy" >> $config_host_mak -fi -if test "$syncfs" =3D "yes" ; then - echo "CONFIG_SYNCFS=3Dy" >> $config_host_mak -fi if test "$inotify" =3D "yes" ; then echo "CONFIG_INOTIFY=3Dy" >> $config_host_mak fi @@ -5329,12 +4990,6 @@ fi if test "$st_atim" =3D "yes" ; then echo "HAVE_STRUCT_STAT_ST_ATIM=3Dy" >> $config_host_mak fi -if test "$byteswap_h" =3D "yes" ; then - echo "CONFIG_BYTESWAP_H=3Dy" >> $config_host_mak -fi -if test "$bswap_h" =3D "yes" ; then - echo "CONFIG_MACHINE_BSWAP_H=3Dy" >> $config_host_mak -fi if test "$gio" =3D "yes" ; then echo "CONFIG_GIO=3Dy" >> $config_host_mak echo "GIO_CFLAGS=3D$gio_cflags" >> $config_host_mak @@ -5344,9 +4999,6 @@ if test "$gdbus_codegen" !=3D "" ; then echo "GDBUS_CODEGEN=3D$gdbus_codegen" >> $config_host_mak fi echo "CONFIG_TLS_PRIORITY=3D\"$tls_priority\"" >> $config_host_mak -if test "$have_openpty" =3D "yes" ; then - echo "HAVE_OPENPTY=3Dy" >> $config_host_mak -fi =20 # Work around a system header bug with some kernel/XFS header # versions where they both try to define 'struct fsxattr': diff --git a/meson.build b/meson.build index 2a19f6c1bd..fe8f64763b 100644 --- a/meson.build +++ b/meson.build @@ -1055,10 +1055,12 @@ endif =20 # Check whether the glibc provides statx() =20 -statx_test =3D ''' +gnu_source_prefix =3D ''' #ifndef _GNU_SOURCE #define _GNU_SOURCE #endif +''' +statx_test =3D gnu_source_prefix + ''' #include int main(void) { struct statx statxbuf; @@ -1260,6 +1262,7 @@ config_host_data.set('QEMU_VERSION_MICRO', meson.proj= ect_version().split('.')[2] =20 config_host_data.set('HAVE_HOST_BLOCK_DEVICE', have_host_block_device) =20 +config_host_data.set('CONFIG_EPOLL', cc.has_header('sys/epoll.h')) config_host_data.set('HAVE_BTRFS_H', cc.has_header('linux/btrfs.h')) config_host_data.set('HAVE_DRM_H', cc.has_header('libdrm/drm.h')) config_host_data.set('HAVE_PTY_H', cc.has_header('pty.h')) @@ -1267,9 +1270,39 @@ config_host_data.set('HAVE_SYS_DISK_H', cc.has_heade= r('sys/disk.h')) config_host_data.set('HAVE_SYS_IOCCOM_H', cc.has_header('sys/ioccom.h')) config_host_data.set('HAVE_SYS_KCOV_H', cc.has_header('sys/kcov.h')) =20 +config_host_data.set('CONFIG_CLOCK_ADJTIME', cc.has_function('clock_adjtim= e')) +config_host_data.set('CONFIG_DUP3', cc.has_function('dup3')) +config_host_data.set('CONFIG_FALLOCATE', cc.has_function('fallocate')) +config_host_data.set('CONFIG_POSIX_FALLOCATE', cc.has_function('posix_fall= ocate')) +config_host_data.set('CONFIG_PPOLL', cc.has_function('ppoll')) config_host_data.set('CONFIG_PREADV', cc.has_function('preadv', prefix: '#= include ')) +config_host_data.set('CONFIG_SENDFILE', cc.has_function('sendfile')) +config_host_data.set('CONFIG_SETNS', cc.has_function('setns') and cc.has_f= unction('unshare')) +config_host_data.set('CONFIG_SYNCFS', cc.has_function('syncfs')) +config_host_data.set('CONFIG_SYNC_FILE_RANGE', cc.has_function('sync_file_= range')) +config_host_data.set('CONFIG_TIMERFD', cc.has_function('timerfd_create')) +config_host_data.set('HAVE_OPENPTY', cc.has_function('openpty', dependenci= es: util)) config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', pre= fix: '#include ')) =20 +config_host_data.set('CONFIG_BYTESWAP_H', + cc.has_header_symbol('byteswap.h', 'bswap_32')) +config_host_data.set('CONFIG_EPOLL_CREATE1', + cc.has_header_symbol('sys/epoll.h', 'epoll_create1')) +config_host_data.set('CONFIG_FALLOCATE_PUNCH_HOLE', + cc.has_header_symbol('linux/falloc.h', 'FALLOC_FL_PUN= CH_HOLE') and + cc.has_header_symbol('linux/falloc.h', 'FALLOC_FL_KEE= P_SIZE')) +config_host_data.set('CONFIG_FALLOCATE_ZERO_RANGE', + cc.has_header_symbol('linux/falloc.h', 'FALLOC_FL_ZER= O_RANGE')) +config_host_data.set('CONFIG_FIEMAP', + cc.has_header('linux/fiemap.h') and + cc.has_header_symbol('linux/fs.h', 'FS_IOC_FIEMAP')) +config_host_data.set('CONFIG_MACHINE_BSWAP_H', + cc.has_header_symbol('machine/bswap.h', 'bswap32', + prefix: '''#include + #include ''')) +config_host_data.set('CONFIG_PRCTL_PR_SET_TIMERSLACK', + cc.has_header_symbol('sys/prctl.h', 'PR_SET_TIMERSLAC= K')) + # Some versions of Mac OS X incorrectly define SIZE_MAX config_host_data.set('HAVE_BROKEN_SIZE_MAX', not cc.compiles(''' #include diff --git a/ui/vnc-auth-sasl.c b/ui/vnc-auth-sasl.c index 47fdae5b21..cf65a0b161 100644 --- a/ui/vnc-auth-sasl.c +++ b/ui/vnc-auth-sasl.c @@ -33,7 +33,7 @@ * files that use SASL API need to disable -Wdeprecated-declarations. */ #ifdef CONFIG_DARWIN -#pragma GCC diagnostic ignored "-Wdeprecated-declarations" +#pragma GCC diagnostic warning "-Wdeprecated-declarations" #endif =20 /* Max amount of data we send/recv for SASL steps to prevent DOS */ diff --git a/util/meson.build b/util/meson.build index 97fad44105..7fe9da60ab 100644 --- a/util/meson.build +++ b/util/meson.build @@ -3,7 +3,9 @@ util_ss.add(files('osdep.c', 'cutils.c', 'unicode.c', 'qemu= -timer-common.c')) util_ss.add(when: 'CONFIG_ATOMIC64', if_false: files('atomic64.c')) util_ss.add(when: 'CONFIG_POSIX', if_true: files('aio-posix.c')) util_ss.add(when: 'CONFIG_POSIX', if_true: files('fdmon-poll.c')) -util_ss.add(when: 'CONFIG_EPOLL_CREATE1', if_true: files('fdmon-epoll.c')) +if config_host_data.get('CONFIG_EPOLL_CREATE1') + util_ss.add(files('fdmon-epoll.c')) +endif util_ss.add(when: ['CONFIG_LINUX_IO_URING', linux_io_uring], if_true: file= s('fdmon-io_uring.c')) util_ss.add(when: 'CONFIG_POSIX', if_true: files('compatfd.c')) util_ss.add(when: 'CONFIG_POSIX', if_true: files('event_notifier-posix.c')) --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152282; cv=none; d=zohomail.com; s=zohoarc; b=DKY3M0Ron7PrwDuTyW3E4LnrRXau/esqxJkVBjKqeg/lZWRCcIwAbD+pAtwoQh+6jaF3ARBcp26BHwwjUBqw66XKXN4Z/xilULjyqw7KOKQJVgelqVhLL5JccmHUBM4Xa2pJT8XlnAlP6arWB4rJKyPdT0QPqicAletZbRFIEWE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152282; h=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=QDkAahc/7Evrh6Gg+jrUeAT0alx/Ii7bF4bgVCdmccM=; b=HMZ+2/R2tcPHolU11pYfiyNtVqAGC4JV5wrj314MdmVyssmHOGGffiFXqzVXZ5PMV+njSL3SQuLwWpP0hggvtRxb7trEzHtwVhbn027HQhSfUAOEtfoZGMv+BfNUJzF3KthkUl3HI4jRqbNfw+92hTbSeH080XuiedyU+ibJzcY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152282075544.5088915139297; Tue, 8 Jun 2021 04:38:02 -0700 (PDT) Received: from localhost ([::1]:47324 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa3U-0002sY-LE for importer2@patchew.org; Tue, 08 Jun 2021 07:38:00 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43722) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpM-0006qZ-NM for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:24 -0400 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]:43909) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpK-00084n-Vp for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:24 -0400 Received: by mail-wm1-x32c.google.com with SMTP id 3-20020a05600c0243b029019f2f9b2b8aso1601917wmj.2 for ; Tue, 08 Jun 2021 04:23:21 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.20 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=QDkAahc/7Evrh6Gg+jrUeAT0alx/Ii7bF4bgVCdmccM=; b=lkuEc1bAMWkzY/qiUNjxODgEJn6+AaXEneKPL5EQ4XFMm1MiiEzB0G0CdPWix3KEkk rQ52iNfyH7rMerdk1tRswkgK4txBXpm6BUdYE+JONxs1NFNdrhpGV6CyyvBlTtQWfFXk zO2S4oK3Qw8o8FknBSnO8hE+BQbK0q1X9ffUlpHWUT9htwlq9KHg2fo0Wrfhnqbs4fOM 5gIM5PXGWwY6YWjJV2g8x0MZFu/CUaWYVyWC4PHxMTXIMZf3YxKX9RxkCBt2RRm7a4tv YebKPmqmHCR462/3RnaegKtvQf9PmJC68/A70MKMpVdTPuUA5RKLltr14OSINDl1qYY/ /Pcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=QDkAahc/7Evrh6Gg+jrUeAT0alx/Ii7bF4bgVCdmccM=; b=K6iecGMsK/bP1Z2K0V3nYe7IIdFDiMtgerDRAe7eDPrSD6eCyTOxZn3qd+ewnbMP+g O1Qy+wHjO2sI7Ag0IB3dARy+XAMgPyUTCmrbeT7tvll8cxVRBBN6bD/b6AnyYdqH3ZJJ fkuOV6rRy1Rot6VrrIzjqBbsFOuCLaObESqn6EFJrQy7dmU5HHLvh+Tj6hPn+5xVwUsu pp7JGTS0o7qTN2us6ziJFg9a/x7FOZeSLJLdOT7E7Z3XQjKvaGzUOSFffBFi9hxOzZkw i+tVEIXJY1+jaDjvv1VMcCuDxRJYwrVeC4D8gcb6jn6sKpNR/vVKx0GdhClm1GA1lW2O 8QPA== X-Gm-Message-State: AOAM533W1j/jkKsX/j66DdNPPk0O8GRAHTJqLnOXvq/B3nrIKpPuIcy5 M1ig+CAqk4NW6q/AIVCFQdCuFHGIz+NRQA== X-Google-Smtp-Source: ABdhPJyLYQYLeGIsTc0tw+96Lpyp/F193xC4mcWAgwTGUyUlhssxqD3fNBTTH5Dn3iFPh+aN3JSmmA== X-Received: by 2002:a05:600c:410c:: with SMTP id j12mr21180805wmi.117.1623151401076; Tue, 08 Jun 2021 04:23:21 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 20/26] meson: store dependency('threads') in a variable Date: Tue, 8 Jun 2021 13:22:55 +0200 Message-Id: <20210608112301.402434-21-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32c; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x32c.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" It can be useful for has_function checks. Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- meson.build | 3 ++- util/meson.build | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/meson.build b/meson.build index fe8f64763b..0f2b05eef6 100644 --- a/meson.build +++ b/meson.build @@ -164,6 +164,7 @@ endif multiprocess_allowed =3D targetos =3D=3D 'linux' and not get_option('multi= process').disabled() =20 libm =3D cc.find_library('m', required: false) +threads =3D dependency('threads') util =3D cc.find_library('util', required: false) winmm =3D [] socket =3D [] @@ -2045,7 +2046,7 @@ util_ss.add_all(trace_ss) util_ss =3D util_ss.apply(config_all, strict: false) libqemuutil =3D static_library('qemuutil', sources: util_ss.sources() + stub_ss.sources(= ) + genh, - dependencies: [util_ss.dependencies(), libm, = glib, socket, malloc, pixman]) + dependencies: [util_ss.dependencies(), libm, = threads, glib, socket, malloc, pixman]) qemuutil =3D declare_dependency(link_with: libqemuutil, sources: genh + version_res) =20 diff --git a/util/meson.build b/util/meson.build index 7fe9da60ab..0ffd7f4bde 100644 --- a/util/meson.build +++ b/util/meson.build @@ -1,4 +1,3 @@ -util_ss.add(dependency('threads')) util_ss.add(files('osdep.c', 'cutils.c', 'unicode.c', 'qemu-timer-common.c= ')) util_ss.add(when: 'CONFIG_ATOMIC64', if_false: files('atomic64.c')) util_ss.add(when: 'CONFIG_POSIX', if_true: files('aio-posix.c')) --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152616; cv=none; d=zohomail.com; s=zohoarc; b=m8SDX2y4zQbiPwwJPPV0vAUaIjna3SdUyqh/C5gL0GQeVSgyQTcs6LJ295d+DJ56vg0RS8KJ+HlCY5TOo8W82kod2aKkBH2HTuHvHbeallSNsimRbZzfiywk/Oua3gl01Ht0j6y1zaIb+wuHeZ5AQ+7Uall9ZrXEPqLVKyQahtk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152616; h=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=nxQQsAycHrHRuZp2uJOU6Ym9EXI/GhjmjKYDjFLL3UU=; b=kWCLjkW0zYZT/a5q9cQzvi/eJn3JP4UPYPPgQGY9yvzyx4b+z8UF3It7kjLBNGgHNmmY7N+h8Aepfg0wOgb+3i+qmZVx1h5syZdQT78IUJpEv7Jw/pEAGir1HpsYCGOIXPw8ky8fItiHJjDaY0BV9DE/ZU8zFR0IAE0ZzFpJzRE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152616137590.4831383490059; Tue, 8 Jun 2021 04:43:36 -0700 (PDT) Received: from localhost ([::1]:60944 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa8t-0003Yn-3O for importer2@patchew.org; Tue, 08 Jun 2021 07:43:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43732) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpN-0006sm-BQ for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:25 -0400 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]:45707) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpL-00085M-7t for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:25 -0400 Received: by mail-wr1-x42e.google.com with SMTP id z8so21122348wrp.12 for ; Tue, 08 Jun 2021 04:23:22 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=nxQQsAycHrHRuZp2uJOU6Ym9EXI/GhjmjKYDjFLL3UU=; b=S94qKCbPt42FZGt2Jz/1CL4A//d8yNPPfRKqSokRzoquxCFfsv6SYnTHdRjy2zPsdP RIuDwswk7wmEOcqmJ1gdxhVkKl4IafqfWVL8omao9acaNcwGiVJMPthhO4NjX4dENXv4 x+HFrXmTMeJFxed70hvgc74lRqI2SkIyV/dAHkb1b3NSqlUsfTylL2pG3Q6OTMOgAga3 OfImvZad09OFtXWs+bjm0N2r4ypA/ZjkKMODxU0M1ktAVvkuQr3hfDO8+MOIbXvq6hh8 v7Jv5l1+U3tSnHWNGk49w3OfsdgA192Z7/GmOquTU6RKO9bw2AmGBjeoBNUdi4v5oK+I w9yA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=nxQQsAycHrHRuZp2uJOU6Ym9EXI/GhjmjKYDjFLL3UU=; b=lfWgpH/nVZc4lsyGsn1nMWEbCJBbcZVw5d5mgBE9rImtITaMLQqI27N8QsuJu+phqF HGt8Qw3avQwabI/OhBECw2omci/TjUo9UBD3kKh46jCFP6UxeUmuxh+9/ztM3b0pG1KS 5VAOowQYnn3slvgx3Y07g0CmzEyuRumPDm37mvmSiH1jN9IDA1pCozbIsL6hfqFi9DNj lT46kYh95FIBSty1b084eqf3Gn8f1TgF1yZ7DbqC0LbbCxhkqVUCfGoFX6unX1POmAc4 CVZgvMmVwZlLq2nF67bf/NlLeAkqvj979mZ2sxaiXOryInl4EKb8kRu66npinuwfPJS7 OlwQ== X-Gm-Message-State: AOAM5334/bBMuVqS/W+L0RCt4aa9raFM8RpAjECbV/RSFsGIRgXXZ9p/ NbWVBDSk0ZFonTDaYckJuJg8eSQ2Exl3zA== X-Google-Smtp-Source: ABdhPJwE5acJ2eaH5Z+JEWSkbNYltjiYx2aehltbEefCDDTE9sHoeYOGUKYt4XvY8lgnWOeHNq+C8g== X-Received: by 2002:adf:e3cf:: with SMTP id k15mr21673039wrm.403.1623151401895; Tue, 08 Jun 2021 04:23:21 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 21/26] configure: convert compiler tests to meson, part 2 Date: Tue, 8 Jun 2021 13:22:56 +0200 Message-Id: <20210608112301.402434-22-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42e; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x42e.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 49 ------------------------------------------------- meson.build | 4 ++++ 2 files changed, 4 insertions(+), 49 deletions(-) diff --git a/configure b/configure index b16c84ca74..7f7f548b1a 100755 --- a/configure +++ b/configure @@ -3783,46 +3783,6 @@ if compile_prog "" "" ; then posix_syslog=3Dyes fi =20 -########################################## -# check if we have sem_timedwait - -sem_timedwait=3Dno -cat > $TMPC << EOF -#include -int main(void) { sem_t s; struct timespec t =3D {0}; return sem_timedwait(= &s, &t); } -EOF -if compile_prog "" "" ; then - sem_timedwait=3Dyes -fi - -########################################## -# check if we have strchrnul - -strchrnul=3Dno -cat > $TMPC << EOF -#include -int main(void); -// Use a haystack that the compiler shouldn't be able to constant fold -char *haystack =3D (char*)&main; -int main(void) { return strchrnul(haystack, 'x') !=3D &haystack[6]; } -EOF -if compile_prog "" "" ; then - strchrnul=3Dyes -fi - -######################################### -# check if we have st_atim - -st_atim=3Dno -cat > $TMPC << EOF -#include -#include -int main(void) { return offsetof(struct stat, st_atim); } -EOF -if compile_prog "" "" ; then - st_atim=3Dyes -fi - ########################################## # check if trace backend exists =20 @@ -4981,15 +4941,6 @@ fi if test "$inotify1" =3D "yes" ; then echo "CONFIG_INOTIFY1=3Dy" >> $config_host_mak fi -if test "$sem_timedwait" =3D "yes" ; then - echo "CONFIG_SEM_TIMEDWAIT=3Dy" >> $config_host_mak -fi -if test "$strchrnul" =3D "yes" ; then - echo "HAVE_STRCHRNUL=3Dy" >> $config_host_mak -fi -if test "$st_atim" =3D "yes" ; then - echo "HAVE_STRUCT_STAT_ST_ATIM=3Dy" >> $config_host_mak -fi if test "$gio" =3D "yes" ; then echo "CONFIG_GIO=3Dy" >> $config_host_mak echo "GIO_CFLAGS=3D$gio_cflags" >> $config_host_mak diff --git a/meson.build b/meson.build index 0f2b05eef6..5e63a21bc1 100644 --- a/meson.build +++ b/meson.build @@ -1277,12 +1277,14 @@ config_host_data.set('CONFIG_FALLOCATE', cc.has_fun= ction('fallocate')) config_host_data.set('CONFIG_POSIX_FALLOCATE', cc.has_function('posix_fall= ocate')) config_host_data.set('CONFIG_PPOLL', cc.has_function('ppoll')) config_host_data.set('CONFIG_PREADV', cc.has_function('preadv', prefix: '#= include ')) +config_host_data.set('CONFIG_SEM_TIMEDWAIT', cc.has_function('sem_timedwai= t', dependencies: threads)) config_host_data.set('CONFIG_SENDFILE', cc.has_function('sendfile')) config_host_data.set('CONFIG_SETNS', cc.has_function('setns') and cc.has_f= unction('unshare')) config_host_data.set('CONFIG_SYNCFS', cc.has_function('syncfs')) config_host_data.set('CONFIG_SYNC_FILE_RANGE', cc.has_function('sync_file_= range')) config_host_data.set('CONFIG_TIMERFD', cc.has_function('timerfd_create')) config_host_data.set('HAVE_OPENPTY', cc.has_function('openpty', dependenci= es: util)) +config_host_data.set('HAVE_STRCHRNUL', cc.has_function('strchrnul')) config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', pre= fix: '#include ')) =20 config_host_data.set('CONFIG_BYTESWAP_H', @@ -1303,6 +1305,8 @@ config_host_data.set('CONFIG_MACHINE_BSWAP_H', #include ''')) config_host_data.set('CONFIG_PRCTL_PR_SET_TIMERSLACK', cc.has_header_symbol('sys/prctl.h', 'PR_SET_TIMERSLAC= K')) +config_host_data.set('HAVE_STRUCT_STAT_ST_ATIM', + cc.has_member('struct stat', 'st_atim', prefix: '#inc= lude ')) =20 # Some versions of Mac OS X incorrectly define SIZE_MAX config_host_data.set('HAVE_BROKEN_SIZE_MAX', not cc.compiles(''' --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152294; cv=none; d=zohomail.com; s=zohoarc; b=czYIp/csgNX6e5OTJ72dkm3JbEjhReJNwIm46hHqb+D3re5dma/Y50HvYBXeXh1/eE2Uj0SUbXxP2QnTRpBpwbhdVp5qHOxvPNfVbUuQ7+CgIiCgJCBI9LROTglyDQh9R708++oRyoxvnxaCbghq2dWyQIQLR7gIFUnIJec26dw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152294; h=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=9ClO7x48cr2DFTHPVK0wr5xSRbkke9BhKLq2zxz5bjw=; b=h9dh0Z6nU9EECx7xLdqVA8K2vmfLegp9utm6RYulINkWiruSgyek48fOJbI9uJHI15MTWcQpRmwLcRrTzKtgRKJTrcr4bW6pwFUKV1UNIh9Gd1TcFsPD3IVl4v+AjdSLOphL5SX7b7UiGBpeUs0hqeOUiTybwcHQ2gz4Un2we6s= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152294884124.0723718325728; Tue, 8 Jun 2021 04:38:14 -0700 (PDT) Received: from localhost ([::1]:47710 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa3h-00037n-Nk for importer2@patchew.org; Tue, 08 Jun 2021 07:38:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43750) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpO-0006vI-9V for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:26 -0400 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]:53973) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpM-000863-AU for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:25 -0400 Received: by mail-wm1-x336.google.com with SMTP id h3so1588995wmq.3 for ; Tue, 08 Jun 2021 04:23:23 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=9ClO7x48cr2DFTHPVK0wr5xSRbkke9BhKLq2zxz5bjw=; b=kkO3I1ORCUmr7AnUa1kWKU/+E67NYe9xb36g7memGLXuQ1QtljDa/AO6IELJRf8jDJ uUe7ZTeEVpAz9yOVyPx4Xcz+Zmeiieksf1rbrg11g2PtNXSiZPRb8EAeEe2FpIUb0qPN f+azJh6/FW4pCN0ZUOO6b5rRgj2ieQ41moOUHbQK318/QuPXLFiknT3+9g5YMMyDrrow mEVJRRJdGAWjb8zqj8MlNqKrPK+rbZvhlzmU56uydKTKXYiYxALGBZiMjvh4jzRfSvJv KmcofcnbxWcfX7L1YY3310xClTEVgKK+4GkASZcagKjY5HtP1oGVls870n7kEKPL6faR CG5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=9ClO7x48cr2DFTHPVK0wr5xSRbkke9BhKLq2zxz5bjw=; b=IK3HKbxc28uf83xiL0nbb1oBjhxp0AcP4d78YvtnE+v3Y25ul7Yo+ji1gubpc+l6u5 4vI+YsLRGbmx+SU12vuojTtK7MLgiJFYjil/SYRQ3yEolE5rqpEvzUgUx4t8R/ghxzzY bCAwgyXhogRngEmbsHqmqpDP0TixJZB0NmauelIWV8efd+tttmRjRgphzeYcg4ncioXt 5QUA9Z5c2G2hyzHAMPbwM0e0dJ+IkgzUD4zbK/b7D/wVP0RjVe8nwHnBNF35/+SwhXTo neJGvnWCqv5IyzXQJxBlmn3EjGkUpbm7maBDdDfy51MPnSt7JA5hhFkBh9FPJaBq3H13 xCgA== X-Gm-Message-State: AOAM530/y0n3VsYi3DtL+yz8T36oUppfxZffK9VAaDEIUGYez9dHjQyL lHNXI3ckiYC9aQss2fpghdiKCh5x6R02SA== X-Google-Smtp-Source: ABdhPJxjTw1IgoMrIz+WspuHOw8zcfG+A1Dr6byIHUVbzjgzEzK9s2/Qlux2f3BzUD6TtZ61GnVsEQ== X-Received: by 2002:a05:600c:1c1b:: with SMTP id j27mr21965467wms.133.1623151402701; Tue, 08 Jun 2021 04:23:22 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 22/26] configure: convert compiler tests to meson, part 3 Date: Tue, 8 Jun 2021 13:22:57 +0200 Message-Id: <20210608112301.402434-23-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::336; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x336.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 87 ----------------------------------------------------- meson.build | 10 ++++++ 2 files changed, 10 insertions(+), 87 deletions(-) diff --git a/configure b/configure index 7f7f548b1a..3e94ec0bd2 100755 --- a/configure +++ b/configure @@ -4293,20 +4293,6 @@ if test "$fortify_source" !=3D "no"; then fi fi =20 -############################################### -# Check if copy_file_range is provided by glibc -have_copy_file_range=3Dno -cat > $TMPC << EOF -#include -int main(void) { - copy_file_range(0, NULL, 0, NULL, 0, 0); - return 0; -} -EOF -if compile_prog "" "" ; then - have_copy_file_range=3Dyes -fi - ########################################## # check if struct fsxattr is available via linux/fs.h =20 @@ -4353,19 +4339,6 @@ else membarrier=3Dno fi =20 -########################################## -# check if rtnetlink.h exists and is useful -have_rtnetlink=3Dno -cat > $TMPC << EOF -#include -int main(void) { - return IFLA_PROTO_DOWN; -} -EOF -if compile_prog "" "" ; then - have_rtnetlink=3Dyes -fi - ########################################## # check for usable AF_VSOCK environment have_af_vsock=3Dno @@ -4419,20 +4392,6 @@ then fi =20 =20 -################################################# -# check for sysmacros.h - -have_sysmacros=3Dno -cat > $TMPC << EOF -#include -int main(void) { - return makedev(0, 0); -} -EOF -if compile_prog "" "" ; then - have_sysmacros=3Dyes -fi - ########################################## # check for _Static_assert() =20 @@ -4447,35 +4406,6 @@ if compile_prog "" "" ; then have_static_assert=3Dyes fi =20 -########################################## -# check for utmpx.h, it is missing e.g. on OpenBSD - -have_utmpx=3Dno -cat > $TMPC << EOF -#include -struct utmpx user_info; -int main(void) { - return 0; -} -EOF -if compile_prog "" "" ; then - have_utmpx=3Dyes -fi - -########################################## -# check for getrandom() - -have_getrandom=3Dno -cat > $TMPC << EOF -#include -int main(void) { - return getrandom(0, 0, GRND_NONBLOCK); -} -EOF -if compile_prog "" "" ; then - have_getrandom=3Dyes -fi - ########################################## # checks for sanitizers =20 @@ -4958,9 +4888,6 @@ echo "CONFIG_TLS_PRIORITY=3D\"$tls_priority\"" >> $co= nfig_host_mak if test "$have_fsxattr" =3D "yes" ; then echo "HAVE_FSXATTR=3Dy" >> $config_host_mak fi -if test "$have_copy_file_range" =3D "yes" ; then - echo "HAVE_COPY_FILE_RANGE=3Dy" >> $config_host_mak -fi if test "$xen" =3D "enabled" ; then echo "CONFIG_XEN_BACKEND=3Dy" >> $config_host_mak echo "CONFIG_XEN_CTRL_INTERFACE_VERSION=3D$xen_ctrl_version" >> $config_= host_mak @@ -5193,10 +5120,6 @@ if test "$pvrdma" =3D "yes" ; then echo "CONFIG_PVRDMA=3Dy" >> $config_host_mak fi =20 -if test "$have_rtnetlink" =3D "yes" ; then - echo "CONFIG_RTNETLINK=3Dy" >> $config_host_mak -fi - if test "$replication" =3D "yes" ; then echo "CONFIG_REPLICATION=3Dy" >> $config_host_mak fi @@ -5205,20 +5128,10 @@ if test "$have_af_vsock" =3D "yes" ; then echo "CONFIG_AF_VSOCK=3Dy" >> $config_host_mak fi =20 -if test "$have_sysmacros" =3D "yes" ; then - echo "CONFIG_SYSMACROS=3Dy" >> $config_host_mak -fi - if test "$have_static_assert" =3D "yes" ; then echo "CONFIG_STATIC_ASSERT=3Dy" >> $config_host_mak fi =20 -if test "$have_utmpx" =3D "yes" ; then - echo "HAVE_UTMPX=3Dy" >> $config_host_mak -fi -if test "$have_getrandom" =3D "yes" ; then - echo "CONFIG_GETRANDOM=3Dy" >> $config_host_mak -fi if test "$debug_mutex" =3D "yes" ; then echo "CONFIG_DEBUG_MUTEX=3Dy" >> $config_host_mak fi diff --git a/meson.build b/meson.build index 5e63a21bc1..0b9dac5546 100644 --- a/meson.build +++ b/meson.build @@ -1283,6 +1283,7 @@ config_host_data.set('CONFIG_SETNS', cc.has_function(= 'setns') and cc.has_functio config_host_data.set('CONFIG_SYNCFS', cc.has_function('syncfs')) config_host_data.set('CONFIG_SYNC_FILE_RANGE', cc.has_function('sync_file_= range')) config_host_data.set('CONFIG_TIMERFD', cc.has_function('timerfd_create')) +config_host_data.set('HAVE_COPY_FILE_RANGE', cc.has_function('copy_file_ra= nge')) config_host_data.set('HAVE_OPENPTY', cc.has_function('openpty', dependenci= es: util)) config_host_data.set('HAVE_STRCHRNUL', cc.has_function('strchrnul')) config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', pre= fix: '#include ')) @@ -1299,14 +1300,23 @@ config_host_data.set('CONFIG_FALLOCATE_ZERO_RANGE', config_host_data.set('CONFIG_FIEMAP', cc.has_header('linux/fiemap.h') and cc.has_header_symbol('linux/fs.h', 'FS_IOC_FIEMAP')) +config_host_data.set('CONFIG_GETRANDOM', + cc.has_function('getrandom') and + cc.has_header_symbol('sys/random.h', 'GRND_NONBLOCK')) config_host_data.set('CONFIG_MACHINE_BSWAP_H', cc.has_header_symbol('machine/bswap.h', 'bswap32', prefix: '''#include #include ''')) config_host_data.set('CONFIG_PRCTL_PR_SET_TIMERSLACK', cc.has_header_symbol('sys/prctl.h', 'PR_SET_TIMERSLAC= K')) +config_host_data.set('CONFIG_RTNETLINK', + cc.has_header_symbol('linux/rtnetlink.h', 'IFLA_PROTO= _DOWN')) +config_host_data.set('CONFIG_SYSMACROS', + cc.has_header_symbol('sys/sysmacros.h', 'makedev')) config_host_data.set('HAVE_STRUCT_STAT_ST_ATIM', cc.has_member('struct stat', 'st_atim', prefix: '#inc= lude ')) +config_host_data.set('HAVE_UTMPX', + cc.has_header_symbol('utmpx.h', 'struct utmpx')) =20 # Some versions of Mac OS X incorrectly define SIZE_MAX config_host_data.set('HAVE_BROKEN_SIZE_MAX', not cc.compiles(''' --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152721; cv=none; d=zohomail.com; s=zohoarc; b=UC3gHRwLtQ1t6vGf0AXEookpPCSiBPRMis4uPdxiw9Gtb1QPR1XO5b6EcJyI5mdI6xREQeS2r0PwKCODQ0/pP/gtauAMIW3kn1GuQs+qDqTeb7TXazHlSF6aC4hlzw2qM7zrp7yqqBsFalP8/QuqtOPg8mOmiPZ7374JfpIao5Y= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152721; h=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=7FKShxn7QBxgN3qly4JQ5WCEBg/8yu0IMrH4TjLvmeU=; b=Gr0Hm0RPvnHPrAoneCw+v6rxYsokSser/H/aAzqlAgy/AnLMvv8/MhWrHoHo8fliWwPOTTGza0rGxEhrBxl8nvVvMoFJLeUpdoyv9LzJR/QyUiBRAEZC6ihWd9GByXOwNfnZEZ+9MSWrNhguFpYFJvi+1Q5e9hw4V2L5W4OqyU0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152721408471.8391978341149; Tue, 8 Jun 2021 04:45:21 -0700 (PDT) Received: from localhost ([::1]:36740 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqaAa-0006DA-EH for importer2@patchew.org; Tue, 08 Jun 2021 07:45:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43754) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpO-0006wP-L0 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:26 -0400 Received: from mail-wm1-x329.google.com ([2a00:1450:4864:20::329]:40500) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpM-000873-R3 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:26 -0400 Received: by mail-wm1-x329.google.com with SMTP id b145-20020a1c80970000b029019c8c824054so1668661wmd.5 for ; Tue, 08 Jun 2021 04:23:24 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7FKShxn7QBxgN3qly4JQ5WCEBg/8yu0IMrH4TjLvmeU=; b=VvhahdfHFgs/ilBBpRBRe/xllLg+2WJB4bi09+ETvFE1uzShjSVH6sgt/mzi3XDHbE Jo5WOrIEURakXnAqsqH90vmVBCHQql8tyALBJLpdmkYRDTjw7vD0lb12tMD5uLIy5og2 GJ50BNMlyVaC8uFXGleg/9rce6K38p0BDVIud+OZEOA/loof1vvqmQlicEFIpEZCsAmZ 7317kPyFZVY2IaH2MenjAnD3uE6KxHnY07uylcwxKJ8Qer1NAB5c9qOb23qNsO2NceLs vddAjdVhY7TMdgj2RU0ksUolQnhl5rcS9G91uIhdoFTr3Qht8odXUc+BaBS2A+nQk0ap Xp5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=7FKShxn7QBxgN3qly4JQ5WCEBg/8yu0IMrH4TjLvmeU=; b=mq4Kcd16+I+09U4u4wWf9IIxORk35b9jU1OPWcKsE9wo1ewvpzfM8Avhe2sX0BBGxg VeVDf978J3vefWUKx/RXsVPf0C9Ey4EnOsqVkNdnLsHJYXHgIcRu6JGNok/WwBZKe5En BNsmlLS07UaDW3yWQT3sOyZR8JFEROmQrHjUkwV/NelJDUhsZ8sDEGtz0a0UysdFkbOk zGkrd9qG4sDZx3LFZIKtPr9HPG/++fyXV5YR3TTp4MGTSEKdl5GP49MHLltwjIyTR/Zu 1Rl3qoX5yZ21HpHGvFis/rD9gluhhfEZzqlGeadOzKkn6ccQl8pzPdlAPCAGPj5MOciT abLA== X-Gm-Message-State: AOAM530dXE0UE9nQSqDIDxTeAl0iVx6WKjUgfsJrByMK4ELBl1ZHR574 Ix7lckJg5tdlkr08LZrUw9rrbxyoEW+4Zw== X-Google-Smtp-Source: ABdhPJyWR7ylK5I9sFyQBDCGrdWjWh23vppai8tsxhyLQntoOlWDEgBdNWcygwN9wKVnjHepd44z3w== X-Received: by 2002:a05:600c:3b11:: with SMTP id m17mr21621044wms.150.1623151403716; Tue, 08 Jun 2021 04:23:23 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 23/26] configure: convert CONFIG_STATIC_ASSERT tests to meson Date: Tue, 8 Jun 2021 13:22:58 +0200 Message-Id: <20210608112301.402434-24-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::329; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x329.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- configure | 18 ------------------ meson.build | 6 ++++++ 2 files changed, 6 insertions(+), 18 deletions(-) diff --git a/configure b/configure index 3e94ec0bd2..dd6098e306 100755 --- a/configure +++ b/configure @@ -4392,20 +4392,6 @@ then fi =20 =20 -########################################## -# check for _Static_assert() - -have_static_assert=3Dno -cat > $TMPC << EOF -_Static_assert(1, "success"); -int main(void) { - return 0; -} -EOF -if compile_prog "" "" ; then - have_static_assert=3Dyes -fi - ########################################## # checks for sanitizers =20 @@ -5128,10 +5114,6 @@ if test "$have_af_vsock" =3D "yes" ; then echo "CONFIG_AF_VSOCK=3Dy" >> $config_host_mak fi =20 -if test "$have_static_assert" =3D "yes" ; then - echo "CONFIG_STATIC_ASSERT=3Dy" >> $config_host_mak -fi - if test "$debug_mutex" =3D "yes" ; then echo "CONFIG_DEBUG_MUTEX=3Dy" >> $config_host_mak fi diff --git a/meson.build b/meson.build index 0b9dac5546..4b9bbca7ff 100644 --- a/meson.build +++ b/meson.build @@ -1318,6 +1318,12 @@ config_host_data.set('HAVE_STRUCT_STAT_ST_ATIM', config_host_data.set('HAVE_UTMPX', cc.has_header_symbol('utmpx.h', 'struct utmpx')) =20 +config_host_data.set('CONFIG_STATIC_ASSERT', cc.compiles(''' + _Static_assert(1, "success"); + int main(void) { + return 0; + }''')) + # Some versions of Mac OS X incorrectly define SIZE_MAX config_host_data.set('HAVE_BROKEN_SIZE_MAX', not cc.compiles(''' #include --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152514; cv=none; d=zohomail.com; s=zohoarc; b=HGKsKf0Hi12txzPBKgLfivoErTa/7J9s+4yqO9p3WUfJQtzhEJF8CJx8WgSOvNIP2E6ZmjmS1eo7gxAr1Cfmok47pKaSeHpSdKAVz8ZIzS2dWYYhDZQKafIA2Da1UDHYPKUhZWuRmQS0wvUMzTJOJVP6xPoR1lSrXuJyb92UyBg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152514; h=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=EGBVnS8TDAzYS3n1mdtHDWtzzPZPFr5YshutzoCZnF0=; b=FK7fVz5evk1PjisHqtmmpyylgL4veEk2kOnqqV+BSTcq15wRBeGzikzjGLZgJbH4uUMirHrL+GQzXsxnxixJGdoJ5V9AdNCQyzIHFBtzz+F+qsbill3SYaO2hgQgwyEchaA9DP82I242czmAz1h6BWUtEw+UNNKUp17ACSBQuQ0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152514559571.055173349537; Tue, 8 Jun 2021 04:41:54 -0700 (PDT) Received: from localhost ([::1]:55152 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqa7F-00089f-9B for importer2@patchew.org; Tue, 08 Jun 2021 07:41:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43768) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpP-0006zs-H4 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:27 -0400 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:55976) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpN-00087X-KO for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:27 -0400 Received: by mail-wm1-x334.google.com with SMTP id g204so1584730wmf.5 for ; Tue, 08 Jun 2021 04:23:25 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=EGBVnS8TDAzYS3n1mdtHDWtzzPZPFr5YshutzoCZnF0=; b=HHBN0ecdvVaX0WJ4vLgsHaZO+hIWaa9MfuORC0zSgoYhrDqFuf/lMEFu/lFMygMwBR E9KBVly7c6p6i2WIwWlMZHLdQh2fiTSt68OFUwMOZyKH7LRkqo8js7bYdrHwg2NB4DN5 lQyzlEhe+I8F74hftpBelw5JNvPDLUEayAIalN6yOX5+8Lvb+JbFjipINch0EEQ54BtD HOcqbDnxv4QCcJZheT8CnbcN/xvtCiQCX+QELPJeImOMQ17EM6g3/BBAQwVwzOaN8RZT M1ipaOJfsf/BpeWpcqZTYMq3LVtHYz6CXqg0yOgqm/ahVbIHJqJ29ujZDek7qUHk/bUj s6QQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=EGBVnS8TDAzYS3n1mdtHDWtzzPZPFr5YshutzoCZnF0=; b=FeakJgRrPBudabOya08VVpnEBxJX8u7JcdWfuCyCUiLE0Ws0KzE7Jz30gPNWmixeIb s2UcVk1M0LnHODUeLAamwAvqyMkhdaStIdcbCJqGVvBMGBsB2C0VABoKp/Zg2KO4Er1p A+6w+4OxMKGMoj0VA6ho+KVB88QnUrjM/vS01nuGq3rDzVqmv0t6F3NoiLfR15vplLaS W4I50/5VQajDSknomgJcVxFxUMjD8rM1IrFw5BjxTr4Y/SKJMN6hGXTokDsMsi6lUj9w 1RtlYgSfqniZJKSw2VJmqew8EoMQNqHcpUZP5EV8k13NupbUwboH4FUvQY1mVUk/aoyD fgFg== X-Gm-Message-State: AOAM531poWv5i/+RJYopGtC6aDMB6HALEYXMRBE9qY6ke5Z8ntD+7LpG IDf1uw1yzgqtlIq46Se0XEYojyljLZUrGA== X-Google-Smtp-Source: ABdhPJwLvW3lcg+128M0/Zap8ftdnwEIgr/lcWIYAuNMyb6SwZd6kHiuTb7jiL1M5yZAhNd6hpOzRQ== X-Received: by 2002:a7b:c394:: with SMTP id s20mr16953955wmj.33.1623151404457; Tue, 08 Jun 2021 04:23:24 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 24/26] configure: convert compiler tests to meson, part 4 Date: Tue, 8 Jun 2021 13:22:59 +0200 Message-Id: <20210608112301.402434-25-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x334.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" And remove them from the summary, since now their outcome is verbosely included in the meson output. Signed-off-by: Paolo Bonzini --- configure | 137 ---------------------------------------------------- meson.build | 38 +++++++++++++-- 2 files changed, 33 insertions(+), 142 deletions(-) diff --git a/configure b/configure index dd6098e306..87143ca00d 100755 --- a/configure +++ b/configure @@ -3511,59 +3511,6 @@ elif test "$jemalloc" =3D "yes" ; then malloc=3Djemalloc fi =20 -########################################## -# signalfd probe -signalfd=3D"no" -cat > $TMPC << EOF -#include -#include -#include -int main(void) { return syscall(SYS_signalfd, -1, NULL, _NSIG / 8); } -EOF - -if compile_prog "" "" ; then - signalfd=3Dyes -fi - -# check if optreset global is declared by -optreset=3D"no" -cat > $TMPC << EOF -#include -int main(void) { return optreset; } -EOF - -if compile_prog "" "" ; then - optreset=3Dyes -fi - -# check if eventfd is supported -eventfd=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - return eventfd(0, EFD_NONBLOCK | EFD_CLOEXEC); -} -EOF -if compile_prog "" "" ; then - eventfd=3Dyes -fi - -# check if memfd is supported -memfd=3Dno -cat > $TMPC << EOF -#include - -int main(void) -{ - return memfd_create("foo", MFD_ALLOW_SEALING); -} -EOF -if compile_prog "" "" ; then - memfd=3Dyes -fi - # check for usbfs have_usbfs=3Dno if test "$linux_user" =3D "yes"; then @@ -3711,66 +3658,6 @@ case "$capstone" in ;; esac =20 -########################################## -# check if we have fdatasync - -fdatasync=3Dno -cat > $TMPC << EOF -#include -int main(void) { -#if defined(_POSIX_SYNCHRONIZED_IO) && _POSIX_SYNCHRONIZED_IO > 0 -return fdatasync(0); -#else -#error Not supported -#endif -} -EOF -if compile_prog "" "" ; then - fdatasync=3Dyes -fi - -########################################## -# check if we have madvise - -madvise=3Dno -cat > $TMPC << EOF -#include -#include -#include -int main(void) { return madvise(NULL, 0, MADV_DONTNEED); } -EOF -if compile_prog "" "" ; then - madvise=3Dyes -fi - -########################################## -# check if we have posix_madvise - -posix_madvise=3Dno -cat > $TMPC << EOF -#include -#include -int main(void) { return posix_madvise(NULL, 0, POSIX_MADV_DONTNEED); } -EOF -if compile_prog "" "" ; then - posix_madvise=3Dyes -fi - -########################################## -# check if we have posix_memalign() - -posix_memalign=3Dno -cat > $TMPC << EOF -#include -int main(void) { - void *p; - return posix_memalign(&p, 8, 8); -} -EOF -if compile_prog "" "" ; then - posix_memalign=3Dyes -fi - ########################################## # check if we have posix_syslog =20 @@ -4842,12 +4729,6 @@ fi if test "$splice" =3D "yes" ; then echo "CONFIG_SPLICE=3Dy" >> $config_host_mak fi -if test "$eventfd" =3D "yes" ; then - echo "CONFIG_EVENTFD=3Dy" >> $config_host_mak -fi -if test "$memfd" =3D "yes" ; then - echo "CONFIG_MEMFD=3Dy" >> $config_host_mak -fi if test "$have_usbfs" =3D "yes" ; then echo "CONFIG_USBFS=3Dy" >> $config_host_mak fi @@ -4922,24 +4803,6 @@ fi if test "$membarrier" =3D "yes" ; then echo "CONFIG_MEMBARRIER=3Dy" >> $config_host_mak fi -if test "$signalfd" =3D "yes" ; then - echo "CONFIG_SIGNALFD=3Dy" >> $config_host_mak -fi -if test "$optreset" =3D "yes" ; then - echo "HAVE_OPTRESET=3Dy" >> $config_host_mak -fi -if test "$fdatasync" =3D "yes" ; then - echo "CONFIG_FDATASYNC=3Dy" >> $config_host_mak -fi -if test "$madvise" =3D "yes" ; then - echo "CONFIG_MADVISE=3Dy" >> $config_host_mak -fi -if test "$posix_madvise" =3D "yes" ; then - echo "CONFIG_POSIX_MADVISE=3Dy" >> $config_host_mak -fi -if test "$posix_memalign" =3D "yes" ; then - echo "CONFIG_POSIX_MEMALIGN=3Dy" >> $config_host_mak -fi =20 if test "$spice_protocol" =3D "yes" ; then echo "CONFIG_SPICE_PROTOCOL=3Dy" >> $config_host_mak diff --git a/meson.build b/meson.build index 4b9bbca7ff..e168e166ad 100644 --- a/meson.build +++ b/meson.build @@ -1275,6 +1275,7 @@ config_host_data.set('CONFIG_CLOCK_ADJTIME', cc.has_f= unction('clock_adjtime')) config_host_data.set('CONFIG_DUP3', cc.has_function('dup3')) config_host_data.set('CONFIG_FALLOCATE', cc.has_function('fallocate')) config_host_data.set('CONFIG_POSIX_FALLOCATE', cc.has_function('posix_fall= ocate')) +config_host_data.set('CONFIG_POSIX_MEMALIGN', cc.has_function('posix_memal= ign')) config_host_data.set('CONFIG_PPOLL', cc.has_function('ppoll')) config_host_data.set('CONFIG_PREADV', cc.has_function('preadv', prefix: '#= include ')) config_host_data.set('CONFIG_SEM_TIMEDWAIT', cc.has_function('sem_timedwai= t', dependencies: threads)) @@ -1313,11 +1314,42 @@ config_host_data.set('CONFIG_RTNETLINK', cc.has_header_symbol('linux/rtnetlink.h', 'IFLA_PROTO= _DOWN')) config_host_data.set('CONFIG_SYSMACROS', cc.has_header_symbol('sys/sysmacros.h', 'makedev')) +config_host_data.set('HAVE_OPTRESET', + cc.has_header_symbol('getopt.h', 'optreset')) config_host_data.set('HAVE_STRUCT_STAT_ST_ATIM', cc.has_member('struct stat', 'st_atim', prefix: '#inc= lude ')) config_host_data.set('HAVE_UTMPX', cc.has_header_symbol('utmpx.h', 'struct utmpx')) =20 +config_host_data.set('CONFIG_EVENTFD', cc.compiles(''' + #include + int main(void) { return eventfd(0, EFD_NONBLOCK | EFD_CLOEXEC); }''')) +config_host_data.set('CONFIG_FDATASYNC', cc.compiles(gnu_source_prefix + '= '' + #include + int main(void) { + #if defined(_POSIX_SYNCHRONIZED_IO) && _POSIX_SYNCHRONIZED_IO > 0 + return fdatasync(0); + #else + #error Not supported + #endif + }''')) +config_host_data.set('CONFIG_MADVISE', cc.compiles(gnu_source_prefix + ''' + #include + #include + #include + int main(void) { return madvise(NULL, 0, MADV_DONTNEED); }''')) +config_host_data.set('CONFIG_MEMFD', cc.compiles(gnu_source_prefix + ''' + #include + int main(void) { return memfd_create("foo", MFD_ALLOW_SEALING); }''')) +config_host_data.set('CONFIG_POSIX_MADVISE', cc.compiles(gnu_source_prefix= + ''' + #include + #include + int main(void) { return posix_madvise(NULL, 0, POSIX_MADV_DONTNEED); }''= ')) +config_host_data.set('CONFIG_SIGNALFD', cc.compiles(gnu_source_prefix + ''' + #include + #include + #include + int main(void) { return syscall(SYS_signalfd, -1, NULL, _NSIG / 8); }'''= )) config_host_data.set('CONFIG_STATIC_ASSERT', cc.compiles(''' _Static_assert(1, "success"); int main(void) { @@ -1400,7 +1432,7 @@ if link_language =3D=3D 'cpp' } endif =20 -have_ivshmem =3D config_host.has_key('CONFIG_EVENTFD') +have_ivshmem =3D config_host_data.get('CONFIG_EVENTFD') host_kconfig =3D \ ('CONFIG_TPM' in config_host ? ['CONFIG_TPM=3Dy'] : []) + \ ('CONFIG_SPICE' in config_host ? ['CONFIG_SPICE=3Dy'] : []) + \ @@ -2721,10 +2753,6 @@ summary_info +=3D {'PIE': get_option('= b_pie')} summary_info +=3D {'static build': config_host.has_key('CONFIG_STATIC= ')} summary_info +=3D {'malloc trim support': has_malloc_trim} summary_info +=3D {'membarrier': config_host.has_key('CONFIG_MEMBAR= RIER')} -summary_info +=3D {'fdatasync': config_host.has_key('CONFIG_FDATAS= YNC')} -summary_info +=3D {'madvise': config_host.has_key('CONFIG_MADVIS= E')} -summary_info +=3D {'posix_madvise': config_host.has_key('CONFIG_POSIX_= MADVISE')} -summary_info +=3D {'posix_memalign': config_host.has_key('CONFIG_POSIX_= MEMALIGN')} summary_info +=3D {'debug stack usage': config_host.has_key('CONFIG_DEBUG_= STACK_USAGE')} summary_info +=3D {'mutex debugging': config_host.has_key('CONFIG_DEBUG_= MUTEX')} summary_info +=3D {'memory allocator': get_option('malloc')} --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152046; cv=none; d=zohomail.com; s=zohoarc; b=DkZgwE+d7lsXlYPEYbdgsHIjhU/1d5GRbxQJwBdSXRUi7+vpFd0S6JEAaKiGanUB2yF/XGzIONcRl4YjUVyGvYpUJMBhEg4OFfB4Ms9ofKKElNIr3h+mBqKxru1aIhiXV666rw0VYNNbiRA7irXWx7bdqQ4PKlAE5V6IW1VUdxM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152046; h=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=+6KgIoYBMJpHpXaS8pJvWzbEpMSL2UNGph/MLhTPZFs=; b=jtsIIGsXTiK7nnNuxR91iI380dFkmkx0pgsCcdf6pe4Jx/c2h/6uSkP243zQ0D1CkmxJtr1iPmYM2I6RV7BM7WThPkU+Ew8S8Ic6qQvEzi7E6DBxEFhQbbkYruKLnxp/emEE7nCAqYujigQoC/wP3wFPbaGeQwhi2wZ5PHHneFI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152046870264.8919095623486; Tue, 8 Jun 2021 04:34:06 -0700 (PDT) Received: from localhost ([::1]:35646 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqZzh-0003PR-Ru for importer2@patchew.org; Tue, 08 Jun 2021 07:34:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43782) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpQ-00071X-Bk for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:32 -0400 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:51955) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpO-00088C-K5 for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:28 -0400 Received: by mail-wm1-x334.google.com with SMTP id l9so1610373wms.1 for ; Tue, 08 Jun 2021 04:23:26 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.24 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=+6KgIoYBMJpHpXaS8pJvWzbEpMSL2UNGph/MLhTPZFs=; b=GWNBDPGEnz+SjiYVglAjIIn1bu1l19zBCHeOy9WXzSyw1kxvTyPJWkPdhOg/H/Fl/a b94wQPq8RIR5I9rQN2iCefEkA3YA3rL8a49sF9d40QqLJFYFsKjWxfiO3MMtRBtYC2L4 zJr5nstsGIg+ZBmU26eNUa5L1Pke8LaQ0PSZldMvkxYvH+IxzluXjT6C/yhmuwYnD74S eHV/ULi3dvpnsBtFNcNyI7fNFCqIllMzfXiKmWaMBL5W5kinKPMT92/2Gy3m27EZgjq+ hT8nOEJiR1W3BlmkLhXX4hJGrxY5u4j9IDNtz081S5C1aOBpLBiG0xqf2XfWR+GfyzD6 kqag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=+6KgIoYBMJpHpXaS8pJvWzbEpMSL2UNGph/MLhTPZFs=; b=f0XkPfvDrdsA4rfamuQM2r8lTbwudds4m3P1SikqBPGh67ME2bmVWJ8Xsrjyq0wwAD NaiiFavX2Ucr5nj1Jvw2d54WT+Zlz4+eMhfbca0gAKn6k4TtD67XHBeHPTBKVlbR62P1 xP6Ef0Aj236PDj2z7Ql+luRkhV5Tu4N33jxRG/ua6glNAAUdnF0qGH72a8pAxsEJNTN0 x3P6BdWWC5+8Z3c4vhyGDSV/npLVuw4N32aV1+Km1pxTUsNuTK1cnS+7cXNjl/KZEI1T we6VSU+3+UV0HwEBBvG9cNv685us2/2gwyPtK2mOn5Db2IhCmzRmwhKZow5a87198dHW 2+5g== X-Gm-Message-State: AOAM533kzMqAzQGQbM986eTOnEF611fPJHsvGczYu2lnG3d7FcuZD8Da 1kZbAs/yGLrj+lJ63cuvUkM32OzcA+ua0A== X-Google-Smtp-Source: ABdhPJylPtGi99LUrdBjHo2SgoBjgolwxVLosFDQZEvhNbaD4O01PFC7AvSQj1vjaRnz18URYBWZNA== X-Received: by 2002:a05:600c:1c28:: with SMTP id j40mr3723235wms.102.1623151405376; Tue, 08 Jun 2021 04:23:25 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 25/26] configure: convert compiler tests to meson, part 5 Date: Tue, 8 Jun 2021 13:23:00 +0200 Message-Id: <20210608112301.402434-26-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x334.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 101 ---------------------------------------------------- meson.build | 26 ++++++++++++++ 2 files changed, 26 insertions(+), 101 deletions(-) diff --git a/configure b/configure index 87143ca00d..527a308470 100755 --- a/configure +++ b/configure @@ -3395,92 +3395,6 @@ EOF fi fi =20 -# Check for inotify functions when we are building linux-user -# emulator. This is done because older glibc versions don't -# have syscall stubs for these implemented. In that case we -# don't provide them even if kernel supports them. -# -inotify=3Dno -cat > $TMPC << EOF -#include - -int -main(void) -{ - /* try to start inotify */ - return inotify_init(); -} -EOF -if compile_prog "" "" ; then - inotify=3Dyes -fi - -inotify1=3Dno -cat > $TMPC << EOF -#include - -int -main(void) -{ - /* try to start inotify */ - return inotify_init1(0); -} -EOF -if compile_prog "" "" ; then - inotify1=3Dyes -fi - -# check if pipe2 is there -pipe2=3Dno -cat > $TMPC << EOF -#include -#include - -int main(void) -{ - int pipefd[2]; - return pipe2(pipefd, O_CLOEXEC); -} -EOF -if compile_prog "" "" ; then - pipe2=3Dyes -fi - -# check if accept4 is there -accept4=3Dno -cat > $TMPC << EOF -#include -#include - -int main(void) -{ - accept4(0, NULL, NULL, SOCK_CLOEXEC); - return 0; -} -EOF -if compile_prog "" "" ; then - accept4=3Dyes -fi - -# check if tee/splice is there. vmsplice was added same time. -splice=3Dno -cat > $TMPC << EOF -#include -#include -#include - -int main(void) -{ - int len, fd =3D 0; - len =3D tee(STDIN_FILENO, STDOUT_FILENO, INT_MAX, SPLICE_F_NONBLOCK); - splice(STDIN_FILENO, NULL, fd, NULL, len, SPLICE_F_MOVE); - return 0; -} -EOF -if compile_prog "" "" ; then - splice=3Dyes -fi - ########################################## # libnuma probe =20 @@ -4720,24 +4634,9 @@ fi if test "$module_upgrades" =3D "yes"; then echo "CONFIG_MODULE_UPGRADES=3Dy" >> $config_host_mak fi -if test "$pipe2" =3D "yes" ; then - echo "CONFIG_PIPE2=3Dy" >> $config_host_mak -fi -if test "$accept4" =3D "yes" ; then - echo "CONFIG_ACCEPT4=3Dy" >> $config_host_mak -fi -if test "$splice" =3D "yes" ; then - echo "CONFIG_SPLICE=3Dy" >> $config_host_mak -fi if test "$have_usbfs" =3D "yes" ; then echo "CONFIG_USBFS=3Dy" >> $config_host_mak fi -if test "$inotify" =3D "yes" ; then - echo "CONFIG_INOTIFY=3Dy" >> $config_host_mak -fi -if test "$inotify1" =3D "yes" ; then - echo "CONFIG_INOTIFY1=3Dy" >> $config_host_mak -fi if test "$gio" =3D "yes" ; then echo "CONFIG_GIO=3Dy" >> $config_host_mak echo "GIO_CFLAGS=3D$gio_cflags" >> $config_host_mak diff --git a/meson.build b/meson.build index e168e166ad..78fa30adbb 100644 --- a/meson.build +++ b/meson.build @@ -1271,6 +1271,7 @@ config_host_data.set('HAVE_SYS_DISK_H', cc.has_header= ('sys/disk.h')) config_host_data.set('HAVE_SYS_IOCCOM_H', cc.has_header('sys/ioccom.h')) config_host_data.set('HAVE_SYS_KCOV_H', cc.has_header('sys/kcov.h')) =20 +config_host_data.set('CONFIG_ACCEPT4', cc.has_function('accept4')) config_host_data.set('CONFIG_CLOCK_ADJTIME', cc.has_function('clock_adjtim= e')) config_host_data.set('CONFIG_DUP3', cc.has_function('dup3')) config_host_data.set('CONFIG_FALLOCATE', cc.has_function('fallocate')) @@ -1304,6 +1305,10 @@ config_host_data.set('CONFIG_FIEMAP', config_host_data.set('CONFIG_GETRANDOM', cc.has_function('getrandom') and cc.has_header_symbol('sys/random.h', 'GRND_NONBLOCK')) +config_host_data.set('CONFIG_INOTIFY', + cc.has_header_symbol('sys/inotify.h', 'inotify_init')) +config_host_data.set('CONFIG_INOTIFY1', + cc.has_header_symbol('sys/inotify.h', 'inotify_init1'= )) config_host_data.set('CONFIG_MACHINE_BSWAP_H', cc.has_header_symbol('machine/bswap.h', 'bswap32', prefix: '''#include @@ -1341,6 +1346,15 @@ config_host_data.set('CONFIG_MADVISE', cc.compiles('= '' config_host_data.set('CONFIG_MEMFD', cc.compiles(gnu_source_prefix + ''' #include int main(void) { return memfd_create("foo", MFD_ALLOW_SEALING); }''')) +config_host_data.set('CONFIG_PIPE2', cc.compiles(gnu_source_prefix + ''' + #include + #include + + int main(void) + { + int pipefd[2]; + return pipe2(pipefd, O_CLOEXEC); + }''')) config_host_data.set('CONFIG_POSIX_MADVISE', cc.compiles(gnu_source_prefix= + ''' #include #include @@ -1350,6 +1364,18 @@ config_host_data.set('CONFIG_SIGNALFD', cc.compiles(= ''' #include #include int main(void) { return syscall(SYS_signalfd, -1, NULL, _NSIG / 8); }'''= )) +config_host_data.set('CONFIG_SPLICE', cc.compiles(gnu_source_prefix + ''' + #include + #include + #include + + int main(void) + { + int len, fd =3D 0; + len =3D tee(STDIN_FILENO, STDOUT_FILENO, INT_MAX, SPLICE_F_NONBLOCK); + splice(STDIN_FILENO, NULL, fd, NULL, len, SPLICE_F_MOVE); + return 0; + }''')) config_host_data.set('CONFIG_STATIC_ASSERT', cc.compiles(''' _Static_assert(1, "success"); int main(void) { --=20 2.31.1 From nobody Thu May 2 11:25:17 2024 Delivered-To: importer2@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1623152823; cv=none; d=zohomail.com; s=zohoarc; b=V0w/D0s8m/dz9ql/T3yQ3P1VoDuJyrRuoPu/HHNVbfzznPWC0GgrAP6yCvv3GBqyVzrVlyGuu6qn77zZMrvwQ8Cye1fE2dMoTZVXJceiL1dxVVt/gnMMXum3JQ8DeU3BCHQhZN+ITLyMKmcg6LE1kPTZzH7pMsezryiLygu3mlY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1623152823; h=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=7c89X6ceGQ+YzSczkt0fKuFnS8XDOBKW4YUy0HKiJgM=; b=O2yxtYN+Tv/75qtCRLZje8HIK72V9EuoqLlj5o4CVmMnwPLgUN6pMofXGeIuN66bQMChDPo5cakafT309wSuKz4OyLkUNEibjmraV6Yw4AxfWQiG9rRgGAIVPyrFRglxhXAHUFzGIyMKHJeLkKvqXViWlNor/1tg7Y8Uks5e8o0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer2=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1623152823261307.7275459520548; Tue, 8 Jun 2021 04:47:03 -0700 (PDT) Received: from localhost ([::1]:39816 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lqaCE-0008Ml-27 for importer2@patchew.org; Tue, 08 Jun 2021 07:47:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43786) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lqZpR-00071Z-GG for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:32 -0400 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]:37662) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lqZpP-000891-Fz for qemu-devel@nongnu.org; Tue, 08 Jun 2021 07:23:28 -0400 Received: by mail-wm1-x32c.google.com with SMTP id f16-20020a05600c1550b02901b00c1be4abso1687776wmg.2 for ; Tue, 08 Jun 2021 04:23:27 -0700 (PDT) Received: from avogadro.lan ([2001:b07:6468:f312:5e2c:eb9a:a8b6:fd3e]) by smtp.gmail.com with ESMTPSA id i9sm15388621wrn.54.2021.06.08.04.23.25 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 04:23:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7c89X6ceGQ+YzSczkt0fKuFnS8XDOBKW4YUy0HKiJgM=; b=jYnbr8ZgCSri3wZ1IEqXqK8W8C/RlQ7VKm4oUCrTjA/FYQ7ogS7F0jwFGEK3jTL392 i9ljrQWl2quweC0fOMKVuejIzDPga2uvdQTwbe9vKlFquOzgQvILNmd5DHAmWRQnjWFN LCPhbweRrNlJ5DzLDhPHK2jQPtCpKbLyDmv8+Fi91UEJp78tLDPNEXA8cUosPs38rdwF Mddsg4TbSQ7LJLqO/apAkPyOhi1gg3LOL3rNNIC0cdh/A9/CJLFc9iH4hW3okj6XuAP1 RVTqoRdZ8mKGpdfM5/bROpvyBvs5bfokA4bpcbOxgn8VPPz+sLC8mzhymg7InXFhTHWq Xf5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=7c89X6ceGQ+YzSczkt0fKuFnS8XDOBKW4YUy0HKiJgM=; b=CAF2tWSPb0ZDUDC5KUKXnMd4SY9fPoRLBx6XuvOH43yFsgbClABVfePc7H06V6Gn5J a3PkE+rp9lE4FOEtqmyssrNLYKgz4jwH+lVCw9yWkEU0ktmw6QjQAtZxodsbziu04bT3 Z1m2d82O84CaArI6bV2s+6h2/PHRecQq0RYpSkk5+5TzTFVXZk12EMJ7Gh2St8d7xQmh qQsu3fyPME6VO/4/1jqAuW3yEXfb568362sIEsn4JaF6+S8PIk5ieX0UOYQZOZyY+44u 5NjEQRRCK6w9s071vYIq58PAp9EZIgAGlzaiZu9K/y3d3CBlQVEZaGMLTp90OFNwEv0F 6fzw== X-Gm-Message-State: AOAM531mpDeSgHBSinAkqo7XIPfmJAFyPHMx+wTzBXIzZj7ro9dcatOa pWHF/6GdmgQPmnt9ruZZp6T3UWfXoknrcg== X-Google-Smtp-Source: ABdhPJxdlLZVAamZr7g1wMo8KTZP/oTZV3yusxSxtO9CUO1IJpFWIr/dUTgSIfUbTj52fhZQnFsXSQ== X-Received: by 2002:a7b:c2f0:: with SMTP id e16mr20477930wmk.136.1623151406354; Tue, 08 Jun 2021 04:23:26 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PATCH 26/26] configure: convert compiler tests to meson, part 6 Date: Tue, 8 Jun 2021 13:23:01 +0200 Message-Id: <20210608112301.402434-27-pbonzini@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210608112301.402434-1-pbonzini@redhat.com> References: <20210608112301.402434-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32c; envelope-from=paolo.bonzini@gmail.com; helo=mail-wm1-x32c.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.248, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_NONE=-0.0001, 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.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Daniel P. Berrang=C3=A9 --- configure | 75 ----------------------------------------------------- meson.build | 11 ++++++++ 2 files changed, 11 insertions(+), 75 deletions(-) diff --git a/configure b/configure index 527a308470..271d5b0060 100755 --- a/configure +++ b/configure @@ -3763,65 +3763,6 @@ else # "$safe_stack" =3D "" fi fi =20 -########################################## -# check if we have open_by_handle_at - -open_by_handle_at=3Dno -cat > $TMPC << EOF -#include -#if !defined(AT_EMPTY_PATH) -# error missing definition -#else -int main(void) { struct file_handle fh; return open_by_handle_at(0, &fh, 0= ); } -#endif -EOF -if compile_prog "" "" ; then - open_by_handle_at=3Dyes -fi - -######################################## -# check if we have linux/magic.h - -linux_magic_h=3Dno -cat > $TMPC << EOF -#include -int main(void) { - return 0; -} -EOF -if compile_prog "" "" ; then - linux_magic_h=3Dyes -fi - -######################################## -# check if we have valgrind/valgrind.h - -valgrind_h=3Dno -cat > $TMPC << EOF -#include -int main(void) { - return 0; -} -EOF -if compile_prog "" "" ; then - valgrind_h=3Dyes -fi - -######################################## -# check if environ is declared - -has_environ=3Dno -cat > $TMPC << EOF -#include -int main(void) { - environ =3D 0; - return 0; -} -EOF -if compile_prog "" "" ; then - has_environ=3Dyes -fi - ######################################## # check if cpuid.h is usable. =20 @@ -4758,18 +4699,6 @@ if test "$crypto_afalg" =3D "yes" ; then echo "CONFIG_AF_ALG=3Dy" >> $config_host_mak fi =20 -if test "$open_by_handle_at" =3D "yes" ; then - echo "CONFIG_OPEN_BY_HANDLE=3Dy" >> $config_host_mak -fi - -if test "$linux_magic_h" =3D "yes" ; then - echo "CONFIG_LINUX_MAGIC_H=3Dy" >> $config_host_mak -fi - -if test "$valgrind_h" =3D "yes" ; then - echo "CONFIG_VALGRIND_H=3Dy" >> $config_host_mak -fi - if test "$have_asan_iface_fiber" =3D "yes" ; then echo "CONFIG_ASAN_IFACE_FIBER=3Dy" >> $config_host_mak fi @@ -4778,10 +4707,6 @@ if test "$have_tsan" =3D "yes" && test "$have_tsan_i= face_fiber" =3D "yes" ; then echo "CONFIG_TSAN=3Dy" >> $config_host_mak fi =20 -if test "$has_environ" =3D "yes" ; then - echo "CONFIG_HAS_ENVIRON=3Dy" >> $config_host_mak -fi - if test "$cpuid_h" =3D "yes" ; then echo "CONFIG_CPUID_H=3Dy" >> $config_host_mak fi diff --git a/meson.build b/meson.build index 78fa30adbb..e6ccca2d5c 100644 --- a/meson.build +++ b/meson.build @@ -1264,6 +1264,8 @@ config_host_data.set('QEMU_VERSION_MICRO', meson.proj= ect_version().split('.')[2] config_host_data.set('HAVE_HOST_BLOCK_DEVICE', have_host_block_device) =20 config_host_data.set('CONFIG_EPOLL', cc.has_header('sys/epoll.h')) +config_host_data.set('CONFIG_LINUX_MAGIC_H', cc.has_header('linux/magic.h'= )) +config_host_data.set('CONFIG_VALGRIND_H', cc.has_header('valgrind/valgrind= .h')) config_host_data.set('HAVE_BTRFS_H', cc.has_header('linux/btrfs.h')) config_host_data.set('HAVE_DRM_H', cc.has_header('libdrm/drm.h')) config_host_data.set('HAVE_PTY_H', cc.has_header('pty.h')) @@ -1294,6 +1296,8 @@ config_host_data.set('CONFIG_BYTESWAP_H', cc.has_header_symbol('byteswap.h', 'bswap_32')) config_host_data.set('CONFIG_EPOLL_CREATE1', cc.has_header_symbol('sys/epoll.h', 'epoll_create1')) +config_host_data.set('CONFIG_HAS_ENVIRON', + cc.has_header_symbol('unistd.h', 'environ', prefix: g= nu_source_prefix)) config_host_data.set('CONFIG_FALLOCATE_PUNCH_HOLE', cc.has_header_symbol('linux/falloc.h', 'FALLOC_FL_PUN= CH_HOLE') and cc.has_header_symbol('linux/falloc.h', 'FALLOC_FL_KEE= P_SIZE')) @@ -1346,6 +1350,13 @@ config_host_data.set('CONFIG_MADVISE', cc.compiles('= '' config_host_data.set('CONFIG_MEMFD', cc.compiles(gnu_source_prefix + ''' #include int main(void) { return memfd_create("foo", MFD_ALLOW_SEALING); }''')) +config_host_data.set('CONFIG_OPEN_BY_HANDLE', cc.compiles(gnu_source_prefi= x + ''' + #include + #if !defined(AT_EMPTY_PATH) + # error missing definition + #else + int main(void) { struct file_handle fh; return open_by_handle_at(0, &fh,= 0); } + #endif''')) config_host_data.set('CONFIG_PIPE2', cc.compiles(gnu_source_prefix + ''' #include #include --=20 2.31.1