macOS: Fix linking statically

`__attribute__((constructor))` does not mark the symbol as used, so the linker ends up dead-stripping the symbol when linked statically.

Adding the `used` attribute fixes that.
This commit is contained in:
Mads Marquart 2024-05-15 21:09:45 +02:00 committed by GitHub
parent 5afff2e44e
commit 6a32893213
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -434,6 +434,7 @@ zone_promote(void) {
}
JEMALLOC_ATTR(constructor)
JEMALLOC_ATTR(used)
void
zone_register(void) {
/*