Linux is not synonymous with glibc. Alpine linux (among others) uses
libmusl as the standard C library. Alpine/libmusl doesn't have
backtrace, dladdr1, execinfo.h or error.h. It does have libunwind
and program_invocation_name and libdwarf and libelf are available as
packages.
This patch makes backward-cpp work on Alpine linux (and hopefully
others that rely on libmusl).
This patch makes dladdr1 dependent on the GLIBC pp-symbol
(rather than ANDROID).
It uses __has_include (protected by a defined()) rather than APPLE
to decide whether to include in _test_main.cpp.
Linux is not synonymous with glibc. Alpine linux (among others) uses libmusl as the standard C library. Alpine/libmusl doesn't have backtrace, dladdr1, execinfo.h or error.h. It does have libunwind and program_invocation_name and libdwarf and libelf are available as packages.
This patch makes backward-cpp work on Alpine linux (and hopefully others that rely on libmusl).
This patch makes dladdr1 dependent on the GLIBC pp-symbol (rather than ANDROID).
It uses __has_include (protected by a defined()) rather than APPLE to decide whether to include in _test_main.cpp.