From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id gDNuKa0WHWDlGgAAWB0awg (envelope-from ) for ; Fri, 05 Feb 2021 04:58:05 -0500 Received: by simark.ca (Postfix, from userid 112) id A71301EFCB; Fri, 5 Feb 2021 04:58:05 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=0.3 required=5.0 tests=MAILING_LIST_MULTI,RDNS_NONE, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.2 Received: from sourceware.org (unknown [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 5A07D1E939 for ; Fri, 5 Feb 2021 04:58:05 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 20D0739F0810; Fri, 5 Feb 2021 09:58:05 +0000 (GMT) Received: from mailex.trusted-objects.com (mailex.trusted-objects.com [149.202.244.204]) by sourceware.org (Postfix) with ESMTPS id 912F139F080F for ; Fri, 5 Feb 2021 09:58:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 912F139F080F Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=trusted-objects.com Authentication-Results: sourceware.org; spf=none smtp.mailfrom=v.dupaquis@trusted-objects.com Received: from [192.170.0.219] (88.127.245.42) by S76918.EX76918.lan (2001:41d0:117:dd00::95ca:f4cc) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P521) id 15.1.2176.2; Fri, 5 Feb 2021 10:58:01 +0100 To: From: vincent Dupaquis Subject: Getting access to environement variables Message-ID: <83736f95-5415-5963-12e7-36466185cef4@trusted-objects.com> Date: Fri, 5 Feb 2021 10:58:00 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Content-Language: fr-FR X-Originating-IP: [88.127.245.42] X-ClientProxiedBy: S76918.EX76918.lan (2001:41d0:117:dd00::95ca:f4cc) To S76918.EX76918.lan (2001:41d0:117:dd00::95ca:f4cc) 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: , Errors-To: gdb-bounces@sourceware.org Sender: "Gdb"     Hello,     I would like to point-out a possibly missing feature, which is the possibility of accessing ENV variables in GDB commands.     Currently, if I want my command scripts to work on a remote target or another, the only way I've found to parametrize the target/port is to generate a command file in the calling script, and to include it into the executed script.     Something like : #!/bin/bash GDBPORT=(GDBPORT:=1234) echo "target remote localhost:${GDBPORT}" > connect.cmd     And then in the gdb script include connect.cmd ...     Is there a better way, or is it the way it is intended top be done ?     Else, I wanted to thank/copngratulate everyone who contributed to GDB for their fantastic work building probably the most powerfull debugger ever (not the most user friendly, still :) ).     Best regards,         Vincent. -- *Vincent Dupaquis* Software security & Cryptography expert 06 24 58 17 05 /Europarc de Pichaury Bâtiment B8 1330 rue Guillibert Gautier de la Lauzière 13290 Aix-en-Provence/ www.trusted-objects.com