by fuhsnn · 4mo ago · 0 comments
The HAVE_/WITH_ defines are supposed to be dynamically probed to adapt to different toolchain environments, setting them manually like that[1][2][3] could only work well for specific targets and for specific versions.
[1] https://github.com/allyourcodebase/libxml2/blob/38fb69d375bc...
[2] https://github.com/allyourcodebase/rnnoise/blob/47db9c212d7e...
[3] https://github.com/allyourcodebase/wayland/blob/f992cd71e199...
that's a bygone practice from before compilers were widely capable.
musl libc specifically recommends using external feature detection a la autoconf, and is so opinionated about this that it refuses to add any identifying macros, like __GLIBC__.