Redefinition of 'hmac' as different kind of symbol on NetBSD
Since renaming hmacname
to hmac
in ffacf0ae BIND 9.19 won't build on NetBSD as this platform already defines hmac
in the /usr/include/stdlib.h
header:
CC dig.o
In file included from dig.c:45:
./dighost.h:262:24: error: redefinition of 'hmac' as different kind of symbol
extern dst_algorithm_t hmac;
^
/usr/include/stdlib.h:312:10: note: previous definition is here
ssize_t hmac(const char *, const void *, size_t, const void *, size_t, void *,
^
dig.c:2461:9: error: non-object type 'ssize_t (const char *, const void *, size_t, const void *, size_t, void *, size_t)' (aka 'long (const char *, const void *, unsigned long, const void *, unsigned long, void *, unsigned long)') is not assignable
hmac = DST_ALG_HMACMD5;
~~~~ ^
2 errors generated.
This erorr is on NetBSD 10.0 RC1 but hmac(3)
suggests this will fail on every NetBSD since v8:
NAME
hmac – compute a key-Hash Message Authentication Code
...
HISTORY
The hmac() function appeared in NetBSD 8.