[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug binutils/29523] i686-w64-mingw32-objdump -WL returns incorrect file
From: |
ralf.habacker at freenet dot de |
Subject: |
[Bug binutils/29523] i686-w64-mingw32-objdump -WL returns incorrect file paths |
Date: |
Fri, 26 Aug 2022 18:55:34 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=29523
--- Comment #2 from Ralf Habacker <ralf.habacker at freenet dot de> ---
objdump -Wi ../output/test.exe dumps
<0><251a>: Abbrev Number: 9 (DW_TAG_compile_unit)
<251b> DW_AT_producer : GNU C17 12.1.0 -mtune=generic
-march=pentiumpro -g
<254e> DW_AT_language : 29 (C11)
<254f> DW_AT_name : (indirect line string, offset: 0x20c):
../test.c
<2553> DW_AT_comp_dir : (indirect line string, offset: 0x1e9):
/home/ralf/src/test-binutils/build
and objdump -Wl ../output/test.exe dumps
The Directory Table (offset 0x4ab, lines 3, columns 1):
Entry Name
0 (indirect line string, offset: 0x216): /home/<user>/test-binutils/build
1 (indirect line string, offset: 0x239): ..
2 (indirect line string, offset: 0x23c):
/usr/i686-w64-mingw32/sys-root/mingw/include
The File Name Table (offset 0x4bd, lines 4, columns 2):
Entry Dir Name
0 1 (indirect line string, offset: 0x269): test.c
1 2 (indirect line string, offset: 0x270): stdio.h
2 1 (indirect line string, offset: 0x278): test.c
3 2 (indirect line string, offset: 0x27f): vadefs.h
which shows that -Wl drops '../' from the file name generating an invalid path.
If the filename table really contains only the filename, the path with index 0
in the directory table should be '/home/<user>/test-binutils/build/...' ->
'/home/<user>/test-binutils'.
--
You are receiving this mail because:
You are on the CC list for the bug.