From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 50A5D3870C1F; Wed, 29 Nov 2023 17:07:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 50A5D3870C1F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1701277647; bh=MlkYo8UEKwqnoF1owHjkcaRGKRXVXMqCJXZW5t6Uv6Q=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Orxit+4BXUO0hE58CylqeWrjaGyYQ89vH54+8Qhd6nGLRHOokHgGuY7B9fYvvzUt+ 4Q7M8SlbC8KvgEzTYMU5MsZgusPzEj6ESGvvVy9epp5uOnMWFUk+csKpDzSmXuvN/h x1sLLorDwE9ioRJWiZf4ObBGvbzpBliwhAu9+XfQ= From: "mark at klomp dot org" To: gdb-prs@sourceware.org Subject: [Bug gdb/31088] gdb requires build directories to exist Date: Wed, 29 Nov 2023 17:07:26 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: gdb X-Bugzilla-Version: 12.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mark at klomp dot org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D31088 --- Comment #2 from Mark Wielaard --- In particular the latest draft (note draft! can still change!) https://snapshots.sourceware.org/dwarfstd/dwarf-spec/latest/ says: --- DRAFT --- A DW_AT_comp_dir attribute whose value is a null-terminated string containi= ng the current working directory of the compilation command that produced this compilation unit in whatever form makes sense for the host system. If a relative path is used in DW_AT_comp_dir, it will be relative to the location of the linked image containing the DW_AT_comp_dir entry. In some cases a producer may allow the user to specify a relative path for DW_AT_comp_dir. There are a few cases in which this is useful, but in gener= al using a relative path for DW_AT_comp_dir is discouraged as it will not work well in many cases including the following: different relative paths are us= ed within the same build; the build system creates multiple linked images in different directories; the =EF=AC=81nal linked image is moved before being = debugged; .o =EF=AC=81les that need to be debugged directly. --- DRAFT --- So that seems to imply that you really shouldn't use relative paths (like "= ."), unless you can make sure that when the image or source files are moved (or = the DWARF is put into a separate .debug file) like when doing make install, all= the relative are updated/resolved/rewritten. --=20 You are receiving this mail because: You are on the CC list for the bug.=