From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id JzGiI1RXXmKKHwAAWB0awg (envelope-from ) for ; Tue, 19 Apr 2022 02:31:48 -0400 Received: by simark.ca (Postfix, from userid 112) id 7DA091F377; Tue, 19 Apr 2022 02:31:48 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_REPLYTO_END_DIGIT,MAILING_LIST_MULTI, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id E0C7D1E150 for ; Tue, 19 Apr 2022 02:31:47 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 593223857C4D for ; Tue, 19 Apr 2022 06:31:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 593223857C4D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1650349907; bh=UO//bey5LOz2scTSmmZVH5FntTxDFWJstHHDLRqkSsI=; h=References:In-Reply-To:Date:Subject:To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=iqT9N+d8Cl9pJrqTGOb5um+CwnVo3j8h5HqEx6vhXPquQTIDOpNqkPP8VML18d8Qb UvYWt/DhCfTKK2oUdO/E01hsIJooUDi5YaCZUrA8Fe5VIWurLO8PhW8DKphqYNEdaq 0TC7Y7oENJp89/IoeUG9+LeXHTMhMg6fbLio9osA= Received: from mail-yw1-x112d.google.com (mail-yw1-x112d.google.com [IPv6:2607:f8b0:4864:20::112d]) by sourceware.org (Postfix) with ESMTPS id 848483858C50 for ; Tue, 19 Apr 2022 06:31:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 848483858C50 Received: by mail-yw1-x112d.google.com with SMTP id 00721157ae682-2ef5380669cso144869937b3.9 for ; Mon, 18 Apr 2022 23:31:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=YTS1r6gGTCsw+OmTQAzECudv2hdd3jSlqqNeOZb6f2A=; b=YA2FULIrhW+dopT7v7YaZH5YD0zv2RsqWjA3mRUGljLRNFYw+UV8cwUrTzud8bAgDH 4dd+vuAWqdREQv6XVLHgNHFmCCnekLL9f3sYXT+eTaJ2dBXfcPoSF7uGki8p84z3Zg/A 4qWhjOQbmCrkBTmNKRKzxvpxqlBbgWZUNDZ/IDaPRgzII5F+agQEASuf8+6TRoS0vxzZ 70D5lv4QSjdM5KOTsnBFLBoxnxfOxDvRXEtZWQa3X4gT74STnQ6Er7UYSaXO0FmZAmRe 4IUBA5x9lOXZ5tQXvPNCJSLwDq6NoXdoZR2Pk3uhc1YHVnda30oGVWy65kg++KifiqpN I0Fw== X-Gm-Message-State: AOAM531S9FDb5faiqvZRpPIgKoGRD/CMU7AWjO+qFtfO84MbBe0frz4S oLlbWAI9WGBXnaKx+A6USjwVHR5wImrafJwFDcU= X-Google-Smtp-Source: ABdhPJwYfN7fxTgVFbuJ6fKBWcBA5F3oC0G0wg2D5SirSFTIQ4kzI08tMjrMSb7ok/slrPBHupompv9VVahbFV5V0lI= X-Received: by 2002:a0d:e4c2:0:b0:2f1:8bfd:61b3 with SMTP id n185-20020a0de4c2000000b002f18bfd61b3mr8435794ywe.6.1650349877764; Mon, 18 Apr 2022 23:31:17 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Tue, 19 Apr 2022 12:01:07 +0530 Message-ID: Subject: Re: native gdb To: Simon Marchi Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: gdb@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Mahesh Bodapati via Gdb Reply-To: Mahesh Bodapati Cc: gdb@sourceware.org Errors-To: gdb-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb" Thanks Simon, >I'm not 100% sure I understand your question, but I assume you want to >cross-compile GDB on an x86-64 build machine, so that GDB runs and >debugs natively on a Microblaze Linux system. build !=3D host =3D=3D target (=E2=80=9Ccross-native=E2=80=9D) native toolchain, as it targets the same machine as it runs on. But it is build on another machine. >GDB already supports Microblaze, see files gdb/microblaze* in the tree. >However, we didn't have contributions that touched those files for a >while, so it's possible these have bitrotted a little bit. I didn't see any issues while I compile cross-compile gdb which runs on x86 and I assume 'microblaze-linux-nat.c' has to be ported/added as similar to other target to make it run on a target natively and also files to be ported for MicroBlaze at " gdb/nat/" Am I correct here? Please help me understand in detail. On Mon, Apr 18, 2022 at 7:16 PM Simon Marchi wrote: > > > On 2022-04-18 02:07, Mahesh Bodapati via Gdb wrote: > > Hi All, > > Target-linux-nat.c is the file for supporting native gdb? > > for instance, I want to build a native gdb for MicroBlaze. > > > > '--host=3Dmicroblazeel-xilinx-linux-gnu' > > '--target=3Dmicroblazeel-xilinx-linux-gnu' > > > > > > 1. what are steps for building native gdb which are specific to > > configure and flags. > > I'm not 100% sure I understand your question, but I assume you want to > cross-compile GDB on an x86-64 build machine, so that GDB runs and > debugs natively on a Microblaze Linux system. > > At the simplest, it will be something like: > > .../configure --host=3Dmicroblazeel-xilinx-linu-gnu --sysroot=3D sysroot> > make > > But you will probably hit more problems that are typical of > cross-compilation (not specific to GDB), like making sure you have all > GDB dependencies built for Microblaze and installed in your sysroot. > > > 2. what files needs to be ported? and is there any guide for porting > > native gdb ? > > GDB already supports Microblaze, see files gdb/microblaze* in the tree. > However, we didn't have contributions that touched those files for a > while, so it's possible these have bitrotted a little bit. > > Simon >