From nobody Tue Nov 26 22:32:28 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=1704012775; cv=none; d=zohomail.com; s=zohoarc; b=C1opfeY5oYisar1yDJbR86ZO8OFTtI74lBnXfst2mRE8PtGXL7prqoq4QFNbJnv3R7u5h6zuKcy4rPwTy/1BfzcTLx8FHUm2o9V3SU8Wi3SF7pRuhpUDuuIJ5Vn0cF6hwu8RkWgenBRgIOMm7B/Y/XQPGeCmGB+wUYCgPuoRVyU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1704012775; h=Content-Type:Content-Transfer-Encoding:Cc:Cc: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; bh=rAOJp7xt3DdPjJzf26gwCcXBP8s3bHkzvNh9a0TuWkI=; b=CEC4d/Rca3YnmJJXRUbdeuKC3XPi2wsa9x4/lvFdJBn/7PlUvHovl823XkTaPhIuZrbUdCkvXG5B5h8yrfjJQzYrn/rae3MPTWlGUctFbJZ+HcxfnmLBa3h53+c0qlStFUjqk+vv5EBWGBtNMP4JifyqQ0v8/L34+e0mW8e/izw= 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 1704012775100365.43966616475075; Sun, 31 Dec 2023 00:52:55 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJrUx-0008FZ-NA; Sun, 31 Dec 2023 03:48:43 -0500 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 1rJrTN-0005XC-4M for qemu-devel@nongnu.org; Sun, 31 Dec 2023 03:47:07 -0500 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 1rJrTG-0000z2-EO for qemu-devel@nongnu.org; Sun, 31 Dec 2023 03:47:04 -0500 Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-622-tb8uKTISMyakcBMdy4oDIA-1; Sun, 31 Dec 2023 03:46:51 -0500 Received: by mail-wm1-f70.google.com with SMTP id 5b1f17b1804b1-40d5ab2fbc9so36806085e9.3 for ; Sun, 31 Dec 2023 00:46:50 -0800 (PST) Received: from [192.168.10.118] ([2001:b07:6468:f312:1c09:f536:3de6:228c]) by smtp.gmail.com with ESMTPSA id o20-20020a05600c4fd400b004094d4292aesm36571259wmq.18.2023.12.31.00.46.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 31 Dec 2023 00:46:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1704012417; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rAOJp7xt3DdPjJzf26gwCcXBP8s3bHkzvNh9a0TuWkI=; b=XHIvcA34w5FxUTOyUraXONClE3croelbWKZFGLc1pUjxO7RqEBIYdEU27vkhMRPeXFPnvw 9D0IEAGC/f78VGdGd6MDAzdVEPnqym1sAovMQKFyug5PM7SWPR+4rBDeZEQncNynWUYByP r9232gx6LhpMEsROtIwIAJR53DYxbf4= X-MC-Unique: tb8uKTISMyakcBMdy4oDIA-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704012409; x=1704617209; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=rAOJp7xt3DdPjJzf26gwCcXBP8s3bHkzvNh9a0TuWkI=; b=VQVq+IKzL2hqglI3gweZhsZHKy/AtuE2G7kOIxwWiheVpSo2la0xXl7NxJXhQC+Lf4 jbssxS+/SgTJ9hO8zRRMNHH6NiavkyHlB8g8+KzcF5UY90FwthTR84nlJ1YY+VK8E/hx bbMZw1xp0ATpsc88FYYiwsQ235/lcM7IbOsiJZ/XFuGis/jqevBIjFsx/3cOiCn7tXUO 2RnAm/nc1U8X3s/mXeyC5zIXXrDNAxbTrluX5NNOgyG/tdXmb0s89pj93eOolZc/piyV 8fyqa8VH72L14j5XKhYQT+KHHbLNQizoRTjY46WTH58rHK8QB/OzaAoeQbWBlNfQJmee P6pQ== X-Gm-Message-State: AOJu0Yx6pqG62Lr22SBoWMM0+Tvi/UioMgQy+yFNMuSapEyNNwxPzN1E O+iOKOuceXc9RQYz+OEyPBVMk8aQ5KFauZjOZWZDpo0idBN7rA69W8xrrDJsf7pHn/01tQCfjlg Vb6VGHnKvHeY7Zx29cS182G/tcwp4MZqV5I0obzDVQIqLpRbiA077vUyEmyE2AzZpgp2aRFioKh 1tY825d1Y= X-Received: by 2002:a05:600c:705:b0:40d:47b5:8e3 with SMTP id i5-20020a05600c070500b0040d47b508e3mr6841861wmn.31.1704012409170; Sun, 31 Dec 2023 00:46:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IHN0HmZ1IPJRYkM+EaGphJMQPx/JR7av4TNzHuJ4dQiUapZw7VEs9Ds4QeFXUbQMzujEKmbOg== X-Received: by 2002:a05:600c:705:b0:40d:47b5:8e3 with SMTP id i5-20020a05600c070500b0040d47b508e3mr6841856wmn.31.1704012408837; Sun, 31 Dec 2023 00:46:48 -0800 (PST) From: Paolo Bonzini To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 42/46] meson: remove config_targetos Date: Sun, 31 Dec 2023 09:44:58 +0100 Message-ID: <20231231084502.235366-43-pbonzini@redhat.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231231084502.235366-1-pbonzini@redhat.com> References: <20231231084502.235366-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Type: text/plain; charset=UTF-8 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: -47 X-Spam_score: -4.8 X-Spam_bar: ---- X-Spam_report: (-4.8 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.667, 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, T_SCC_BODY_TEXT_LINE=-0.01 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: 1704012775399100001 config_targetos is now empty and can be removed; its use in sourcesets that do not involve target-specific files can be replaced with an empty dictionary. In fact, at this point *all* sourcesets that do not involve target-specific files are just glorified mutable arrays. Enforce that they never test for symbols in "when:" by computing the set of files without "strict: false". Reviewed-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Paolo Bonzini --- chardev/meson.build | 2 +- gdbstub/meson.build | 4 ++-- meson.build | 24 ++++++++++-------------- qga/meson.build | 2 +- storage-daemon/meson.build | 2 +- tcg/meson.build | 2 +- tests/qtest/meson.build | 2 +- 7 files changed, 17 insertions(+), 21 deletions(-) diff --git a/chardev/meson.build b/chardev/meson.build index 9564ace868b..db6840b71af 100644 --- a/chardev/meson.build +++ b/chardev/meson.build @@ -28,7 +28,7 @@ else endif endif =20 -chardev_ss =3D chardev_ss.apply(config_targetos, strict: false) +chardev_ss =3D chardev_ss.apply({}) =20 system_ss.add(files( 'char-hmp-cmds.c', diff --git a/gdbstub/meson.build b/gdbstub/meson.build index e5bccba34e5..da5721d8452 100644 --- a/gdbstub/meson.build +++ b/gdbstub/meson.build @@ -14,8 +14,8 @@ gdb_system_ss =3D ss.source_set() gdb_user_ss.add(files('gdbstub.c', 'user.c')) gdb_system_ss.add(files('gdbstub.c', 'system.c')) =20 -gdb_user_ss =3D gdb_user_ss.apply(config_targetos, strict: false) -gdb_system_ss =3D gdb_system_ss.apply(config_targetos, strict: false) +gdb_user_ss =3D gdb_user_ss.apply({}) +gdb_system_ss =3D gdb_system_ss.apply({}) =20 libgdb_user =3D static_library('gdb_user', gdb_user_ss.sources() + genh, diff --git a/meson.build b/meson.build index e37ab286c23..7aa06dc7c1b 100644 --- a/meson.build +++ b/meson.build @@ -2885,7 +2885,6 @@ endif ######################## =20 minikconf =3D find_program('scripts/minikconf.py') -config_targetos =3D {} =20 config_all =3D {} config_all_devices =3D {} @@ -3084,7 +3083,6 @@ target_dirs =3D actual_target_dirs # pseudo symbol replaces it. =20 config_all +=3D config_all_devices -config_all +=3D config_targetos config_all +=3D config_all_disas config_all +=3D { 'CONFIG_XEN': xen.found(), @@ -3413,7 +3411,7 @@ if enable_modules modulecommon =3D declare_dependency(link_whole: libmodulecommon, compile= _args: '-DBUILD_DSO') endif =20 -qom_ss =3D qom_ss.apply(config_targetos, strict: false) +qom_ss =3D qom_ss.apply({}) libqom =3D static_library('qom', qom_ss.sources() + genh, dependencies: [qom_ss.dependencies()], name_suffix: 'fa', @@ -3428,10 +3426,10 @@ event_loop_base =3D static_library('event-loop-base= ', event_loop_base =3D declare_dependency(link_whole: event_loop_base, dependencies: [qom]) =20 -stub_ss =3D stub_ss.apply(config_all, strict: false) +stub_ss =3D stub_ss.apply({}) =20 util_ss.add_all(trace_ss) -util_ss =3D util_ss.apply(config_all, strict: false) +util_ss =3D util_ss.apply({}) libqemuutil =3D static_library('qemuutil', build_by_default: false, sources: util_ss.sources() + stub_ss.sources(= ) + genh, @@ -3594,7 +3592,6 @@ foreach d, list : target_modules foreach target : target_dirs if target.endswith('-softmmu') config_target =3D config_target_mak[target] - config_target +=3D config_targetos target_inc =3D [include_directories('target' / config_target['TA= RGET_BASE_ARCH'])] c_args =3D ['-DNEED_CPU_H', '-DCONFIG_TARGET=3D"@0@-config-target.h"'.format(targe= t), @@ -3655,7 +3652,7 @@ qemu_syms =3D custom_target('qemu.syms', output: 'qem= u.syms', capture: true, command: [undefsym, nm, '@INPUT@']) =20 -authz_ss =3D authz_ss.apply(config_targetos, strict: false) +authz_ss =3D authz_ss.apply({}) libauthz =3D static_library('authz', authz_ss.sources() + genh, dependencies: [authz_ss.dependencies()], name_suffix: 'fa', @@ -3664,7 +3661,7 @@ libauthz =3D static_library('authz', authz_ss.sources= () + genh, authz =3D declare_dependency(link_whole: libauthz, dependencies: qom) =20 -crypto_ss =3D crypto_ss.apply(config_targetos, strict: false) +crypto_ss =3D crypto_ss.apply({}) libcrypto =3D static_library('crypto', crypto_ss.sources() + genh, dependencies: [crypto_ss.dependencies()], name_suffix: 'fa', @@ -3673,7 +3670,7 @@ libcrypto =3D static_library('crypto', crypto_ss.sour= ces() + genh, crypto =3D declare_dependency(link_whole: libcrypto, dependencies: [authz, qom]) =20 -io_ss =3D io_ss.apply(config_targetos, strict: false) +io_ss =3D io_ss.apply({}) libio =3D static_library('io', io_ss.sources() + genh, dependencies: [io_ss.dependencies()], link_with: libqemuutil, @@ -3689,7 +3686,7 @@ migration =3D declare_dependency(link_with: libmigrat= ion, dependencies: [zlib, qom, io]) system_ss.add(migration) =20 -block_ss =3D block_ss.apply(config_targetos, strict: false) +block_ss =3D block_ss.apply({}) libblock =3D static_library('block', block_ss.sources() + genh, dependencies: block_ss.dependencies(), link_depends: block_syms, @@ -3700,7 +3697,7 @@ block =3D declare_dependency(link_whole: [libblock], link_args: '@block.syms', dependencies: [crypto, io]) =20 -blockdev_ss =3D blockdev_ss.apply(config_targetos, strict: false) +blockdev_ss =3D blockdev_ss.apply({}) libblockdev =3D static_library('blockdev', blockdev_ss.sources() + genh, dependencies: blockdev_ss.dependencies(), name_suffix: 'fa', @@ -3709,7 +3706,7 @@ libblockdev =3D static_library('blockdev', blockdev_s= s.sources() + genh, blockdev =3D declare_dependency(link_whole: [libblockdev], dependencies: [block, event_loop_base]) =20 -qmp_ss =3D qmp_ss.apply(config_targetos, strict: false) +qmp_ss =3D qmp_ss.apply({}) libqmp =3D static_library('qmp', qmp_ss.sources() + genh, dependencies: qmp_ss.dependencies(), name_suffix: 'fa', @@ -3724,7 +3721,7 @@ libchardev =3D static_library('chardev', chardev_ss.s= ources() + genh, =20 chardev =3D declare_dependency(link_whole: libchardev) =20 -hwcore_ss =3D hwcore_ss.apply(config_targetos, strict: false) +hwcore_ss =3D hwcore_ss.apply({}) libhwcore =3D static_library('hwcore', sources: hwcore_ss.sources() + genh, name_suffix: 'fa', build_by_default: false) @@ -3781,7 +3778,6 @@ foreach target : target_dirs '-DCONFIG_DEVICES=3D"@0@-config-devices.h"'.format(target)] link_args =3D emulator_link_args =20 - config_target +=3D config_targetos target_inc =3D [include_directories('target' / config_target['TARGET_BAS= E_ARCH'])] if targetos =3D=3D 'linux' target_inc +=3D include_directories('linux-headers', is_system: true) diff --git a/qga/meson.build b/qga/meson.build index 1113e7c7fae..66c0f1e56f8 100644 --- a/qga/meson.build +++ b/qga/meson.build @@ -87,7 +87,7 @@ else endif endif =20 -qga_ss =3D qga_ss.apply(config_targetos, strict: false) +qga_ss =3D qga_ss.apply({}) =20 gen_tlb =3D [] qga_libs =3D [] diff --git a/storage-daemon/meson.build b/storage-daemon/meson.build index 5e90cd32b40..46267b63e72 100644 --- a/storage-daemon/meson.build +++ b/storage-daemon/meson.build @@ -5,7 +5,7 @@ qsd_ss.add(blockdev, chardev, qmp, qom, qemuutil, gnutls) subdir('qapi') =20 if have_tools - qsd_ss =3D qsd_ss.apply(config_targetos, strict: false) + qsd_ss =3D qsd_ss.apply({}) qsd =3D executable('qemu-storage-daemon', qsd_ss.sources(), dependencies: qsd_ss.dependencies(), diff --git a/tcg/meson.build b/tcg/meson.build index 895a11d3fa2..5afdec1e1ae 100644 --- a/tcg/meson.build +++ b/tcg/meson.build @@ -22,7 +22,7 @@ if get_option('tcg_interpreter') tcg_ss.add(files('tci.c')) endif =20 -tcg_ss =3D tcg_ss.apply(config_targetos, strict: false) +tcg_ss =3D tcg_ss.apply({}) =20 libtcg_user =3D static_library('tcg_user', tcg_ss.sources() + genh, diff --git a/tests/qtest/meson.build b/tests/qtest/meson.build index 47dabf91d04..40a8bb043e4 100644 --- a/tests/qtest/meson.build +++ b/tests/qtest/meson.build @@ -310,7 +310,7 @@ qtests =3D { 'ivshmem-test': [rt, '../../contrib/ivshmem-server/ivshmem-server.c'], 'migration-test': migration_files, 'pxe-test': files('boot-sector.c'), - 'qos-test': [chardev, io, qos_test_ss.apply(config_targetos, strict: fal= se).sources()], + 'qos-test': [chardev, io, qos_test_ss.apply({}).sources()], 'tpm-crb-swtpm-test': [io, tpmemu_files], 'tpm-crb-test': [io, tpmemu_files], 'tpm-tis-swtpm-test': [io, tpmemu_files, 'tpm-tis-util.c'], --=20 2.43.0