Incorrect _NetBSD__ macro inside execmem.c
defined(_NetBSD__)
should be probably defined(__NetBSD__)
(two underscores)
https://gitlab.freedesktop.org/mesa/mesa/-/blob/master/src/mesa/main/execmem.c#L40
and
https://gitlab.freedesktop.org/mesa/mesa/-/blob/master/src/mapi/u_execmem.c#L49