LadybirdBrowser / ladybird

Truly independent web browser
https://ladybird.dev
BSD 2-Clause "Simplified" License
4.36k stars 217 forks source link

AK+CMake: Use the find module to find the correct backtrace(3) header #277

Open ADKaster opened 6 days ago

ADKaster commented 6 days ago

As recommended by the CMake docs, let's tolerate systems or setups that don't have backtrace(3) in the <execinfo.h> header file, such as those using libbacktrace directly.

@sideeffect42 does this fix your issue in the same way that #274 does?

sideeffect42 commented 6 days ago

Thank you for implementing this, @ADKaster. This is clearly the better approach than shuffling parentheses in the distro list.

I tested it on my musl/ppc64 system and it built fine without backtraces. Unfortunately I couldn't test if backtraces work using libbacktrace, because Gentoo dropped its libbacktrace package some time ago.

I'll see whether I can manually build libbacktrace and link Ladybird against it in the coming days.