configure: Check return type of strerror_r

Just checking for _GNU_SOURCE is not enough, because musl still returns
int even with _GNU_SOURCE, despite the musl header explicitly checking
for _GNU_SOURCE.