<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/81650>81650</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[CMake] Support package/install with LLVM_USE_SPLIT_DWARF
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
jsji
</td>
</tr>
</table>
<pre>
[MikeHolman](https://discourse.llvm.org/u/MikeHolman)
(https://discourse.llvm.org/t/rfc-turn-on-llvm-use-split-dwarf-by-default-for-linux-debug-build/76724/24?u=jsji)
How does this work with packages/installs? It has been a while since I looked at this, but I recall that the .dwo files do not get installed by the install target. Maybe they can just be copied over to the install directory, but I imagine there are pathing issues to sort out. Anyway, I think this is something to consider (and hopefully fix!) before changing the default.
[dblaikie](https://discourse.llvm.org/u/dblaikie)
(https://discourse.llvm.org/t/rfc-turn-on-llvm-use-split-dwarf-by-default-for-linux-debug-build/76724/25?u=jsji)
This proposal is only to change the defaults for Debug builds - presumably no one’s making a package installation from them.
but if they were, they’d need to build a .dwp file by merging all the .dwo files - I don’t think we have any build infrastructure/rules for doing that - **you can run a dwp tool (binutils dwp or llvm-dwp) in -e mode, passing it the executable, and it’ll read the skeleton units from the executable to find all the dwo paths - and merge those together into <binary>.dwp**
We should do call llvm-dwp and install dwp files when LLVM_USE_SPLIT_DWARF is on.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzEVU1v4zYQ_TX0ZSDDpuxEOvjgXa-wBjZA0Wy7x4ASRxJjiiPwI4r-fUHKcRJgD-2plwQWNU8z7715FM6pziAe2P4L259WIvie7OHZPatVTXKOzx_UBb-THoRh-xPjRe_96Fh-ZLxivJLKNRSsw7XWL8OabMd4FRivPpTxkm1ObHP8d8We8cq2TeaDNRmZLB5lwWHmRq18Jidh26yeM4mtCNpnLdlMKxNeM4l16LI6KC0Zr-7v7vmO8YrvWF4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