From nobody Wed Nov 27 18:49:33 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1697617848; cv=none; d=zohomail.com; s=zohoarc; b=Ivekxp07/GYEvVBrViwYGxqTB7tcymt2b8pNAUVFGfNf5i1XxB4FVWpWGxLM7BTqoEAR+Zkp5xeceCf0zVJbxEF/02yIYCtlLs6ffCJBDDl7FP5TUwDznC+8a3o1kF+b9iTr4Zd2YIQa5HGGXl8AaN8qs9AwXrmlHI9g1enTskc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1697617848; h=Content-Type:Content-Transfer-Encoding:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To:Cc; bh=E9rNqaVK84tFYCTSHv5gjYxAT3A3NUnYvaGZa77NGgM=; b=A+5W4HYVNo+2hoAbv6IcsE0Jsrfrfcz2gh1rauESP9jgrZwIRMIDNXIfDohFbP0/w+Xm+RwC5jb0vLkDt9BDZlxzJKVzyEQzYSqS+YbjCGUa6exq+U3VJ5XMdMtBjZzbp6QVOtA8MyIbX3Ugk2IiIOlgNsabd6d3/Be+y3bIvLU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1697617848121254.66424681686885; Wed, 18 Oct 2023 01:30:48 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qt1vF-0002F4-B7; Wed, 18 Oct 2023 04:28:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qt1vA-00022q-MU for qemu-devel@nongnu.org; Wed, 18 Oct 2023 04:28:52 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qt1v8-0003i2-W6 for qemu-devel@nongnu.org; Wed, 18 Oct 2023 04:28:52 -0400 Received: from mail-ej1-f72.google.com (mail-ej1-f72.google.com [209.85.218.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-470-KHEisyLdMzO-ByZJW6UtAw-1; Wed, 18 Oct 2023 04:28:49 -0400 Received: by mail-ej1-f72.google.com with SMTP id a640c23a62f3a-9b274cc9636so486269266b.0 for ; Wed, 18 Oct 2023 01:28:48 -0700 (PDT) Received: from [192.168.10.118] ([2001:b07:6468:f312:63a7:c72e:ea0e:6045]) by smtp.gmail.com with ESMTPSA id n27-20020a1709062bdb00b009829d2e892csm1217660ejg.15.2023.10.18.01.28.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 01:28:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1697617730; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=E9rNqaVK84tFYCTSHv5gjYxAT3A3NUnYvaGZa77NGgM=; b=Y8P2PaQl+drDSUc+rwJ8mg9i+QIdxHiDDuPJzqf3ZnikwYbgUybkEFvqI2gEL0PKCR+SDB kBAjLnW6buGs6HdYEMU3gyfOXJUgDA2wfbaNxk1zuYnDinosN/IOvkUpD2wkfNKQ5KKjik 8ONQhMicUQumsxPikPvtOhhAPEFS4z8= X-MC-Unique: KHEisyLdMzO-ByZJW6UtAw-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697617727; x=1698222527; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=E9rNqaVK84tFYCTSHv5gjYxAT3A3NUnYvaGZa77NGgM=; b=I0/MXHpFZCd4HcpGcpVtqlMG21+xtDTrxYy4XDENI0xNahuDrccBH47RT6qb3vrNqX RBL2+RRJ3MofI9WaZ+PyeJ7XSKuduKtxTVwcYtZw0fWTA4Y/cVVFn8WgDATW0pfgth1X egoFsKPGCGm9O7A1sUNrZGHMaBujEgCGh2KDAM7BZ3qZJ5Q80pcQSRy1+wDQpnh4Q71D S6RH04Zf95GooBq2YFUCrxscjrAYrxLZtpxxSBQf0fIY+kKTci/3ecPZogbXfsnQ3ZNc /eVe580jZ/CfO7R/SmU73nx1RppUnfZkXoil3Q5px2XOUb27pPqhZyWUdxFAxkvjVG9B dARw== X-Gm-Message-State: AOJu0YyaqtnOrzM0zy2oaW5UoTXTkR7sCRhFarIuDZutyBz7y0HtcZ2W NVXPwg1z8H8CAXUsw1wCTFQzWybrsCHbCNeobc5X6D33ZsUodFOxI5JeUZouyepSpQ/WyEOP41S 1AihVyAo4SpZrx6YaHHJKlBf1FvUY0rscoWJszouPr5i6Jm0kd7UGyAopCkbIM9JiG4IRQLjp37 k= X-Received: by 2002:a17:907:7d8c:b0:9a1:f81f:d0d5 with SMTP id oz12-20020a1709077d8c00b009a1f81fd0d5mr3362408ejc.54.1697617727488; Wed, 18 Oct 2023 01:28:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHMfwxXGsP1mGB/Ewn+1WASfg0h64QYlqOwwNV4RtXOy86kx/YX6TpUod4OoSzLxpkhAi//2g== X-Received: by 2002:a17:907:7d8c:b0:9a1:f81f:d0d5 with SMTP id oz12-20020a1709077d8c00b009a1f81fd0d5mr3362396ejc.54.1697617727128; Wed, 18 Oct 2023 01:28:47 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PULL 29/32] configure, meson: use command line options to configure qemu-ga Date: Wed, 18 Oct 2023 10:27:49 +0200 Message-ID: <20231018082752.322306-30-pbonzini@redhat.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20231018082752.322306-1-pbonzini@redhat.com> References: <20231018082752.322306-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+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=170.10.133.124; envelope-from=pbonzini@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1697617849286100003 Content-Type: text/plain; charset="utf-8" Preserve the functionality of the environment variables, but allow using the command line instead. Signed-off-by: Paolo Bonzini --- configure | 16 +++++++++------- meson_options.txt | 7 +++++++ qga/meson.build | 9 ++++++--- scripts/meson-buildoptions.sh | 9 +++++++++ 4 files changed, 31 insertions(+), 10 deletions(-) diff --git a/configure b/configure index 4b24c572d56..8827a29bf4c 100755 --- a/configure +++ b/configure @@ -1592,12 +1592,6 @@ echo >> $config_host_mak =20 echo all: >> $config_host_mak =20 -if test "$targetos" =3D "windows"; then - echo "QEMU_GA_MANUFACTURER=3D${QEMU_GA_MANUFACTURER-QEMU}" >> $config_ho= st_mak - echo "QEMU_GA_DISTRO=3D${QEMU_GA_DISTRO-Linux}" >> $config_host_mak - echo "QEMU_GA_VERSION=3D${QEMU_GA_VERSION-$(cat "$source_path"/VERSION)}= " >> $config_host_mak -fi - echo "SRC_PATH=3D$source_path" >> $config_host_mak echo "TARGET_DIRS=3D$target_list" >> $config_host_mak echo "GDB=3D$gdb_bin" >> $config_host_mak @@ -1724,6 +1718,15 @@ if test "$skip_meson" =3D no; then if test "$SMBD" !=3D ''; then echo "smbd =3D $(meson_quote "$SMBD")" >> $cross fi + if test "${QEMU_GA_MANUFACTURER}" !=3D ''; then + echo "qemu_ga_manufacturer =3D $(meson_quote "${QEMU_GA_MANUFACTURER}"= )" >> $cross + fi + if test "${QEMU_GA_DISTRO}" !=3D ''; then + echo "qemu_ga_distro =3D $(meson_quote "${QEMU_GA_DISTRO}")" >> $cross + fi + if test "${QEMU_GA_VERSION}" !=3D ''; then + echo "qemu_ga_version =3D $(meson_quote "${QEMU_GA_VERSION}")" >> $cro= ss + fi =20 echo >> $cross echo "[binaries]" >> $cross @@ -1775,7 +1778,6 @@ if test "$skip_meson" =3D no; then =20 rm -rf meson-private meson-info meson-logs =20 - # Built-in options test "$download" =3D "disabled" && meson_option_add "--wrap-mode=3Dnodow= nload" test "$default_feature" =3D no && meson_option_add -Dauto_features=3Ddis= abled test "$static" =3D yes && meson_option_add -Dprefer_static=3Dtrue diff --git a/meson_options.txt b/meson_options.txt index e237b268469..1b0c02b4a58 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -353,5 +353,12 @@ option('qom_cast_debug', type: 'boolean', value: true, option('slirp_smbd', type : 'feature', value : 'auto', description: 'use smbd (at path --smbd=3D*) in slirp networking') =20 +option('qemu_ga_manufacturer', type: 'string', value: 'QEMU', + description: '"manufacturer" name for qemu-ga registry entries') +option('qemu_ga_distro', type: 'string', value: 'Linux', + description: 'second path element in qemu-ga registry entries') +option('qemu_ga_version', type: 'string', value: '', + description: 'version number for qemu-ga installer') + option('hexagon_idef_parser', type : 'boolean', value : true, description: 'use idef-parser to automatically generate TCG code fo= r the Hexagon frontend') diff --git a/qga/meson.build b/qga/meson.build index 59cae0cc6ee..940a51d55db 100644 --- a/qga/meson.build +++ b/qga/meson.build @@ -145,6 +145,9 @@ if targetos =3D=3D 'windows' else libpcre =3D 'libpcre2' endif + qga_msi_version =3D get_option('qemu_ga_version') =3D=3D '' \ + ? project.version() \ + : get_option('qemu_ga_version') qga_msi =3D custom_target('QGA MSI', input: files('installer/qemu-ga.wxs'), output: 'qemu-ga-@0@.msi'.format(host_arch), @@ -155,9 +158,9 @@ if targetos =3D=3D 'windows' qemu_ga_msi_vss, '-D', 'BUILD_DIR=3D' + meson.project_build_r= oot(), '-D', 'BIN_DIR=3D' + glib_pc.get_variable('b= indir'), - '-D', 'QEMU_GA_VERSION=3D' + config_host['QE= MU_GA_VERSION'], - '-D', 'QEMU_GA_MANUFACTURER=3D' + config_hos= t['QEMU_GA_MANUFACTURER'], - '-D', 'QEMU_GA_DISTRO=3D' + config_host['QEM= U_GA_DISTRO'], + '-D', 'QEMU_GA_VERSION=3D' + qga_msi_version, + '-D', 'QEMU_GA_MANUFACTURER=3D' + get_option= ('qemu_ga_manufacturer'), + '-D', 'QEMU_GA_DISTRO=3D' + get_option('qemu= _ga_distro'), '-D', 'LIBPCRE=3D' + libpcre, ]) all_qga +=3D [qga_msi] diff --git a/scripts/meson-buildoptions.sh b/scripts/meson-buildoptions.sh index dec33820163..bda88993bd1 100644 --- a/scripts/meson-buildoptions.sh +++ b/scripts/meson-buildoptions.sh @@ -64,6 +64,12 @@ meson_options_help() { printf "%s\n" ' --localstatedir=3DVALUE Localstate data directory [/= var/local]' printf "%s\n" ' --mandir=3DVALUE Manual page directory [share= /man]' printf "%s\n" ' --prefix=3DVALUE Installation prefix [/usr/lo= cal]' + printf "%s\n" ' --qemu-ga-distro=3DVALUE second path element in qemu-= ga registry entries' + printf "%s\n" ' [Linux]' + printf "%s\n" ' --qemu-ga-manufacturer=3DVALUE' + printf "%s\n" ' "manufacturer" name for qemu-g= a registry entries' + printf "%s\n" ' [QEMU]' + printf "%s\n" ' --qemu-ga-version=3DVALUE version number for qemu-ga i= nstaller' printf "%s\n" ' --smbd=3DVALUE Path to smbd for slirp netwo= rking' printf "%s\n" ' --sysconfdir=3DVALUE Sysconf data directory [etc]' printf "%s\n" ' --tls-priority=3DVALUE Default TLS protocol/cipher = priority string' @@ -422,6 +428,9 @@ _meson_option_parse() { --enable-qed) printf "%s" -Dqed=3Denabled ;; --disable-qed) printf "%s" -Dqed=3Ddisabled ;; --firmwarepath=3D*) quote_sh "-Dqemu_firmwarepath=3D$(meson_option_bui= ld_array $2)" ;; + --qemu-ga-distro=3D*) quote_sh "-Dqemu_ga_distro=3D$2" ;; + --qemu-ga-manufacturer=3D*) quote_sh "-Dqemu_ga_manufacturer=3D$2" ;; + --qemu-ga-version=3D*) quote_sh "-Dqemu_ga_version=3D$2" ;; --with-suffix=3D*) quote_sh "-Dqemu_suffix=3D$2" ;; --enable-qga-vss) printf "%s" -Dqga_vss=3Denabled ;; --disable-qga-vss) printf "%s" -Dqga_vss=3Ddisabled ;; --=20 2.41.0