[asterisk-bugs] [JIRA] (ASTERISK-29817) gethostbyname_r is misdetected on NetBSD and causes a build failure
Joshua C. Colp (JIRA)
noreply at issues.asterisk.org
Mon Dec 27 04:44:45 CST 2021
[ https://issues.asterisk.org/jira/browse/ASTERISK-29817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Work on ASTERISK-29817 started by Michał Górny.
> gethostbyname_r is misdetected on NetBSD and causes a build failure
> -------------------------------------------------------------------
>
> Key: ASTERISK-29817
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-29817
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: Core/BuildSystem
> Affects Versions: GIT
> Environment: NetBSD 9.2 (amd64)
> Reporter: Michał Górny
> Assignee: Michał Górny
>
> Building Asterisk on NetBSD currently fails as {{gethostbyname_r}} is incorrectly detected as being present:
> {code}
> utils.c: In function 'ast_gethostbyname':
> utils.c:234:11: warning: implicit declaration of function 'gethostbyname_r'; did you mean 'gethostbyname2'? [-Wimplicit-function-declaration]
> result = gethostbyname_r(host, &hp->hp, hp->buf, sizeof(hp->buf), &herrno);
> ^~~~~~~~~~~~~~~
> gethostbyname2
> utils.c:234:9: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
> result = gethostbyname_r(host, &hp->hp, hp->buf, sizeof(hp->buf), &herrno);
> ^
> {code}
> On NetBSD, {{gethostbyname_r}} is an internal libc symbol that is not exposed in system headers and that is incompatible with other implementations.
--
This message was sent by Atlassian JIRA
(v6.2#6252)
More information about the asterisk-bugs
mailing list