From nobody Mon Mar 2 08:46:22 2026 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=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1772146801; cv=none; d=zohomail.com; s=zohoarc; b=Y1fLBczGq7FxsZ5lxbPM5X2yJN6OmkuVUVY+2hJ0H6QfAvrgpNWhEyVgNZYHMEGRzsV7WDdYifLxxvtoW8lZ/FLwK3thV1nEIxTA+W4aLL4XUbO9QsMZyGIJMgubFhX2zy1IqFPTsc+h94HEq3fAg7CzALiz+71p/OUxqLi76DM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1772146801; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=IHZXkaVgViOohCapk16z4GZOnLF3Wy2PgK3udt46ano=; b=RH21LzHP8nnLRc/996jBg4cthbVKqsRP3ydh0R9HyJhN2If9LJv8G25egZhiyV+DuLK4PAoGFGtrCcXLjeiu/93RHVMmrsXON68HtlyTXsHtnKnxasZ3U/54KT2mcnivDmLAFZJ9aq6fEODTvLeEc4LozGXy4f+nzb4yRBcOYiM= 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 1772146801603250.10657583847842; Thu, 26 Feb 2026 15:00:01 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1vvkKc-0000tc-Uy; Thu, 26 Feb 2026 17:59:42 -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 1vvkKb-0000tL-KI for qemu-devel@nongnu.org; Thu, 26 Feb 2026 17:59:41 -0500 Received: from mail-wr1-x42f.google.com ([2a00:1450:4864:20::42f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1vvkKZ-0003sA-TZ for qemu-devel@nongnu.org; Thu, 26 Feb 2026 17:59:41 -0500 Received: by mail-wr1-x42f.google.com with SMTP id ffacd0b85a97d-43988056dc3so1407245f8f.3 for ; Thu, 26 Feb 2026 14:59:39 -0800 (PST) Received: from localhost.localdomain (88-187-86-199.subs.proxad.net. [88.187.86.199]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4399c6100b8sm2856955f8f.2.2026.02.26.14.59.36 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Thu, 26 Feb 2026 14:59:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1772146778; x=1772751578; darn=nongnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=IHZXkaVgViOohCapk16z4GZOnLF3Wy2PgK3udt46ano=; b=OjsCmkSv/oH/tjTyiUrzJ/f2w4HiDeHocwYs8gJVMyHjHvuexDXnYx+bmmw3UYWDIV rJ80xGFZfobZE/yIpUuundFeciyjZoO7WTbalRhjAUTx1g3t/kxhk1Y9mh9ROBU8VWjP UuuhipRA3cfPvlQK+nCJ9ZNG4ECb5wCrv9OgOPyHkWHP4nJolczN3jByq1aaZPvvBMik jUcgoLljGB5RrxPrnfTeTqlJJR4gatQdvzVrmcZ1h2zUcbk8KwTYcCwpa9Yr4U9vjSqI lM0cu78CV3hwTSBDujElJsdjk7qp/SfeVZiw8BAM6rjdFHy4nN0lfqmpHP45bODvY3cl GTkw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772146778; x=1772751578; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=IHZXkaVgViOohCapk16z4GZOnLF3Wy2PgK3udt46ano=; b=p10sr44BrGxNqjV7hBtdrPCf7i9cwHdEZSQBtorAOAEBjTmidpSWC8XP+X/kNhCY+L TBN4qewHi9hsl+liLa+kLEo7OnvR7aSPtho2q5F7jOjMqdbdcZbPZoRytb5nJC/JFMJ3 jEPNrwP9i65TNHozYZXjLk+qB7t++kUUZIaqlPA+Ka8rNssQ1P4LY/nx0yOYwJwmxdHs RWHfL9jhzwfPAgdtHfFuNTj2uF81pCjyj1VSLV/uS71pSs/b93Acus/en9Nm14WkhtKD KxeSgxKFIaMtrSFnxD3NjPVLuvuV6aT+Vz+OyQvDNBjj7FcIB9tXtu3/MpzkHoMxhQYM IMTg== X-Gm-Message-State: AOJu0YyUjFD3qunnrKiPs4Aq/XWn89wYMtI0k4FQFg6m74jxGR5fnKWD moU60wm1Qj3oPbWZLGB2W8Sb8uX3ZCwhZq//HKwgKQPB5mLQ5FgTAZyUs3Ow6qKV2/kmdihdutK tU/FsKu8= X-Gm-Gg: ATEYQzx8D88Pt8YNgy6xxKWb585/XFLx8KOnnpeFNPw0mwo8gSeFYeeF6DjE9zSgM5K nfwNF0MTm6bv5Q/CfTdU3XvTEHWUG4iX94O04Bu7DdgqbU0u3+qkmXxVZpIR2HodL86inFbkJc8 wug2lcNyDSY1J1AtLZWa3rR+/fiXboEpawZ5MpOfDVWfQFXomBXq/UoVdHWYXcLnhE5Zj8bXy1s kARIMQwDaW1DRKGHihK5xQWCCuIDBz9TTnyxLYMdUCHSDFsoEIm/WoJipGlxZMldJnQ7m7vtq1K vmOAnBlf6CjHePAu1MjhRGP5UQ0Ne3nFa+jjUeclO63+FL3qEq9v6AzmNKcWVzVbkw4bvH5Re1w Zgrset5Iv5jsfiSsqBRzQA+WUKKVNn+9V1Aediif+FxxXspNqxWDNDt81csUm8Xe+C24d0eteu7 T33O5ZszKeCnnrixjQ9n6ob20okaIUdFNPpIjEi3Oxs+jbSX4wo2OXADDnrPOV+b4HePqoaXlTn eLhqB6Tuig= X-Received: by 2002:a05:6000:250a:b0:439:5e4d:baa3 with SMTP id ffacd0b85a97d-4399de0b8b5mr925970f8f.11.1772146777800; Thu, 26 Feb 2026 14:59:37 -0800 (PST) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Paolo Bonzini , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , Pierrick Bouvier , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PATCH v2] gdbstub: Generate a single gdbstub-xml.c / gdb_static_features[] Date: Thu, 26 Feb 2026 23:59:36 +0100 Message-ID: <20260226225936.50725-1-philmd@linaro.org> X-Mailer: git-send-email 2.52.0 MIME-Version: 1.0 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=2a00:1450:4864:20::42f; envelope-from=philmd@linaro.org; helo=mail-wr1-x42f.google.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, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, 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: qemu development 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 @linaro.org) X-ZM-MESSAGEID: 1772146802974158500 gdb_static_features[] only contains strings, nothing target-specific. Instead of generating one file per target, generate a single file with a single gdb_static_features[] array. Remove the stub. Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- v2: Check array length --- meson.build | 27 +++++++++++++++++---------- stubs/gdbstub.c | 6 ------ stubs/meson.build | 2 -- 3 files changed, 17 insertions(+), 18 deletions(-) delete mode 100644 stubs/gdbstub.c diff --git a/meson.build b/meson.build index 451cb28149f..5d7abc5db8b 100644 --- a/meson.build +++ b/meson.build @@ -3867,6 +3867,23 @@ subdir('linux-user') subdir('tests/qtest/libqos') subdir('tests/qtest/fuzz') =20 +feature_to_c =3D find_program('scripts/feature_to_c.py') +gdbstub_xml =3D [] +foreach target : target_dirs + config_target =3D config_target_mak[target] + if 'TARGET_XML_FILES' in config_target + gdbstub_xml +=3D config_target['TARGET_XML_FILES'].split() + endif +endforeach +if gdbstub_xml.length() > 0 + gdbstub_xml =3D custom_target('gdbstub-xml.c', + output: 'gdbstub-xml.c', + input: files(gdbstub_xml), + command: [feature_to_c, '@INPUT@'], + capture: true) + common_ss.add(gdbstub_xml) +endif + ############################################## # Internal static_libraries and dependencies # ############################################## @@ -4218,7 +4235,6 @@ if have_rust endif =20 =20 -feature_to_c =3D find_program('scripts/feature_to_c.py') rust_root_crate =3D find_program('scripts/rust/rust_root_crate.sh') =20 if host_os =3D=3D 'darwin' @@ -4298,15 +4314,6 @@ foreach target : target_dirs endif endif =20 - if 'TARGET_XML_FILES' in config_target - gdbstub_xml =3D custom_target(target + '-gdbstub-xml.c', - output: target + '-gdbstub-xml.c', - input: files(config_target['TARGET_XML_FIL= ES'].split()), - command: [feature_to_c, '@INPUT@'], - capture: true) - arch_srcs +=3D gdbstub_xml - endif - if target in config_target_info arch_srcs +=3D config_target_info[target] else diff --git a/stubs/gdbstub.c b/stubs/gdbstub.c deleted file mode 100644 index 580e20702b2..00000000000 --- a/stubs/gdbstub.c +++ /dev/null @@ -1,6 +0,0 @@ -#include "qemu/osdep.h" -#include "exec/gdbstub.h" /* gdb_static_features */ - -const GDBFeature gdb_static_features[] =3D { - { NULL } -}; diff --git a/stubs/meson.build b/stubs/meson.build index 8a07059500d..1e0f6f47377 100644 --- a/stubs/meson.build +++ b/stubs/meson.build @@ -89,8 +89,6 @@ if have_system endif =20 if have_system or have_user - stub_ss.add(files('gdbstub.c')) - # Also included in have_system for --disable-tcg builds stub_ss.add(files('replay.c')) =20 --=20 2.52.0