From patchwork Thu Jun 17 21:42:13 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Romain Naour X-Patchwork-Id: 1493974 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=RAtsoSrv; dkim-atps=neutral Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4G5bBB3cxcz9sRN for ; Fri, 18 Jun 2021 07:42:26 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 16D8482E05; Thu, 17 Jun 2021 21:42:24 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8CIOTg4DUP9U; Thu, 17 Jun 2021 21:42:23 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 6983F82DA1; Thu, 17 Jun 2021 21:42:22 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 906251C1190 for ; Thu, 17 Jun 2021 21:42:21 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 7EF93605E2 for ; Thu, 17 Jun 2021 21:42:21 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0tys29kFR5YQ for ; Thu, 17 Jun 2021 21:42:20 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) by smtp3.osuosl.org (Postfix) with ESMTPS id 56F92605E1 for ; Thu, 17 Jun 2021 21:42:20 +0000 (UTC) Received: by mail-wm1-x333.google.com with SMTP id t11-20020a1cc30b0000b02901cec841b6a0so4888311wmf.0 for ; Thu, 17 Jun 2021 14:42:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Q7EE5aX/ZrBoffVX7XTjeBUHl5HEtipEzL9n8L30z4Q=; b=RAtsoSrvPCdf1EUvV3/QqtwoLD6MlyAfx8qR1GvBoJzjdrGvpoyEzjjTIJS7Tvb9y1 tLQK//W5nPgc83/zf89cgi5I2/3zgJVojHGKibQimiNHYUX3NaDWau+zNM4VjZuOTxod WfgYhmaV/SXsjIW7lGWkD/yf+QELTcJS4nagDnezP6nBOvAKLKulWO1PRHwu8Ots83o7 osoAw1pbkPG1quMUMMLvV0/fZFeD1wdwDFOFILjFegLvhqHe/Ey0tZJtbzk9KPZSJhag DhiUcGJNAXRyeBQyHUn9B9PXjWw16PE3Ros6oAzZnFIQ/EA53eUw899bWX8gIYXpUIO2 MslA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Q7EE5aX/ZrBoffVX7XTjeBUHl5HEtipEzL9n8L30z4Q=; b=uTGCtriLHKh1Iho4GFUwICCLH8W3XB/qIi1ZlOgQs1gfF8qXgzO+OvG3zfKbsqXT3H ZBqxwH9eIeg9HlTuQ7aUx5WTvCeB1DizaGjLV7dw1UlzYH73Q56/VWvXE1RhKSEDvcEZ 6JCJ8K6VMRy6eSv11JSLoHyMlGXftlVVIWVBvcvwdMWJB/u8iHZowlRGZcePPDEq1B3m LoCC++9vr5wLub/nfn/ASZcUtF/9iucQCDaKT71AZ7h5lf8TqOoqt96z0mpVsvP1GjTR 1xId/48eoM82x/+r2AtKG6M1WkN3CenhoPvscqx+1MfRe0aQwS5b5y53ybfI/Mi0K/RW HPYg== X-Gm-Message-State: AOAM532l/CRZSmBqpMMH7zIHCMy1Ic1fuTdjKuLzT/445bQJGVkjWyXQ PQ2nyVMAKEqdB9MOxZQAEIvJfA0AtUw= X-Google-Smtp-Source: ABdhPJyzXdg6S7ZbzIztpFv8KjFRbKz4e9XV++vWF2hQzlXIzWMS4EcUQy9O5vSdUzaNh7koHbCXuA== X-Received: by 2002:a05:600c:198c:: with SMTP id t12mr7476067wmq.16.1623966138571; Thu, 17 Jun 2021 14:42:18 -0700 (PDT) Received: from localhost.localdomain (2a01cb058f8a180098814a9aef637f91.ipv6.abo.wanadoo.fr. [2a01:cb05:8f8a:1800:9881:4a9a:ef63:7f91]) by smtp.gmail.com with ESMTPSA id x1sm5427720wmc.31.2021.06.17.14.42.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Jun 2021 14:42:18 -0700 (PDT) From: Romain Naour To: buildroot@buildroot.org Date: Thu, 17 Jun 2021 23:42:13 +0200 Message-Id: <20210617214213.75840-1-romain.naour@gmail.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Subject: [Buildroot] [PATCHv2] package/gdb: enable gdbserver support for riscv X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Alistair Francis , Romain Naour Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" It turn out that gdbserver support for riscv is available since 10.1 release, since commit [1]. Restrict the gdb version choice for riscv to 10.1 for simplicity [2]. [1] https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=bf84f7066626c78884436e1c39fb60f04c665f21 [2] http://lists.busybox.net/pipermail/buildroot/2021-June/312681.html Signed-off-by: Romain Naour Cc: Arnout Vandecappelle (Essensium/Mind) Cc: Alistair Francis Reviewed-by: Alistair Francis --- git tag --contains bf84f7066626c78884436e1c39fb60f04c665f21 returns gdb-10.1-release tag as the oldest containing this commit. v2: restrict the version choice (Arnout) --- package/gdb/Config.in | 3 --- package/gdb/Config.in.host | 9 ++++++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/package/gdb/Config.in b/package/gdb/Config.in index 262740fc4c..246748131e 100644 --- a/package/gdb/Config.in +++ b/package/gdb/Config.in @@ -19,8 +19,6 @@ config BR2_PACKAGE_GDB depends on BR2_PACKAGE_GDB_ARCH_SUPPORTS depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 depends on BR2_INSTALL_LIBSTDCPP - # no gdbserver on riscv - select BR2_PACKAGE_GDB_DEBUGGER if BR2_riscv # When the external toolchain gdbserver is copied to the # target, we don't allow building a separate gdbserver. The # one from the external toolchain should be used. @@ -47,7 +45,6 @@ if BR2_PACKAGE_GDB config BR2_PACKAGE_GDB_SERVER bool "gdbserver" depends on !BR2_TOOLCHAIN_EXTERNAL_GDB_SERVER_COPY - depends on !BR2_riscv help Build the gdbserver stub to run on the target. A full gdb is needed to debug the progam. diff --git a/package/gdb/Config.in.host b/package/gdb/Config.in.host index 21e6b34caa..9814f3a79b 100644 --- a/package/gdb/Config.in.host +++ b/package/gdb/Config.in.host @@ -4,7 +4,6 @@ config BR2_PACKAGE_HOST_GDB_ARCH_SUPPORTS depends on !((BR2_arm || BR2_armeb) && BR2_BINFMT_FLAT) depends on !BR2_microblaze depends on !BR2_or1k - depends on !BR2_riscv depends on !BR2_nds32 comment "Host GDB Options" @@ -70,9 +69,13 @@ choice config BR2_GDB_VERSION_8_3 bool "gdb 8.3.x" + # gdbserver support missing + depends on !BR2_riscv config BR2_GDB_VERSION_9_2 bool "gdb 9.2.x" + # gdbserver support missing + depends on !BR2_riscv config BR2_GDB_VERSION_10 bool "gdb 10.x" @@ -87,6 +90,6 @@ config BR2_GDB_VERSION default "arc-2020.09-release-gdb" if BR2_arc default "4ecb98fbc2f94dbe01b69384afbc515107de73df" if BR2_csky default "8.3.1" if BR2_GDB_VERSION_8_3 - default "9.2" if BR2_GDB_VERSION_9_2 || !BR2_PACKAGE_HOST_GDB - default "10.1" if BR2_GDB_VERSION_10 + default "9.2" if BR2_GDB_VERSION_9_2 || (!BR2_PACKAGE_HOST_GDB && !BR2_riscv) + default "10.1" if BR2_GDB_VERSION_10 || (!BR2_PACKAGE_HOST_GDB && BR2_riscv) depends on BR2_PACKAGE_GDB || BR2_PACKAGE_HOST_GDB