1
0
Fork 0
mirror of https://repo.or.cz/socat.git synced 2025-07-20 01:42:58 +00:00

Correction of getprotobynumber_r() variant detection (musl libc)

This commit is contained in:
Gerhard Rieger 2022-08-13 16:53:11 +02:00
parent ee23bccee7
commit 75cb44bc90
4 changed files with 14 additions and 6 deletions

View file

@ -137,13 +137,13 @@ AC_MSG_RESULT($sc_cv_have_prototype_hstrerror)
# getprotobynumber_r() is not standardized
AC_MSG_CHECKING(for getprotobynumber_r() variant)
AC_CACHE_VAL(sc_cv_getprotobynumber_r,
[AC_TRY_COMPILE([#include <stddef.h>
[AC_TRY_LINK([#include <stddef.h>
#include <netdb.h>],[getprotobynumber_r(1,NULL,NULL,1024,NULL);],
[sc_cv_getprotobynumber_r=1; tmp_bynum_variant=Linux],
[AC_TRY_COMPILE([#include <stddef.h>
[AC_TRY_LINK([#include <stddef.h>
#include <netdb.h>],[getprotobynumber_r(1,NULL,NULL,1024);],
[sc_cv_getprotobynumber_r=2; tmp_bynum_variant=Solaris],
[AC_TRY_COMPILE([#include <stddef.h>
[AC_TRY_LINK([#include <stddef.h>
#include <netdb.h>],[getprotobynumber_r(1,NULL,NULL);],
[sc_cv_getprotobynumber_r=3; tmp_bynum_variant=AIX],