[Tizen] Generate source-level debug information with dwarf version 4 (#347) accepted/tizen/unified/20231114.041326
author이형주/MDE Lab(SR)/삼성전자 <leee.lee@samsung.com>
Fri, 10 Nov 2023 08:49:44 +0000 (17:49 +0900)
committerGitHub Enterprise <noreply-CODE@samsung.com>
Fri, 10 Nov 2023 08:49:44 +0000 (17:49 +0900)
commitd546361102aab7b2a659a931c4184aee71af620b
treef38a44a5a428c56292d00135858daf2c8cb70d14
parent5872308e3d9000ba1288a17472dbc2f1354665e1
[Tizen] Generate source-level debug information with dwarf version 4 (#347)

* [Tizen] Generate source-level debug information with dwarf version 4

Tizen 9.0 uses Clang-15 while GDB is currently 8.3.1
Dwarf error occurs with this combination as Clang-15 generates dwarf5

```
(gdb) r
Starting program: /usr/bin/dotnet /opt/share/thread_priority.dll
warning: File "/usr/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add
        add-auto-load-safe-path /usr/lib/libthread_db-1.0.so
line to your configuration file "/root/.gdbinit".
To completely disable this security protection add
        set auto-load safe-path /
line to your configuration file "/root/.gdbinit".
For more information about this security protection see the
"Auto-loading safe path" section in the GDB manual.  E.g., run from the shell:
        info "(gdb)Auto-loading safe path"
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
Dwarf Error: Cannot handle DW_FORM_strx1 in DWARF reader [in module /usr/lib/debug/usr/share/dotnet/shared/Microsoft.NETCore.App/6.0.9/libcoreclr.so.debug]
Dwarf Error: Cannot handle DW_FORM_strx1 in DWARF reader [in module /usr/lib/debug/usr/share/dotnet/shared/Microsoft.NETCore.App/6.0.9/libcoreclrtraceptprovider.so.debug]
[New LWP 2262]
```

More details at https://discourse.llvm.org/t/gdb-10-1-cant-read-clangs-dwarf-v5/6035/12

* apply feedback
packaging/coreclr.spec