[ 
https://issues.apache.org/jira/browse/PROTON-852?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15094423#comment-15094423
 ] 

Andrew Stitcher commented on PROTON-852:
----------------------------------------

What version of uclibc are you using? UClibs seems to have supported 
getaddrinfo and friends since 2002 (from the git records). Perhaps you could 
reconfigure your uclibc build to include these functions if they are not 
included?

I'm not dismissing this feature request, but on the whole we are targeting 
POSIX and Windows environments.  getaddinfo() and friends are now pretty 
universally available where a BSD sockets like interface is available.

If that really isn't possible (perhaps the uclibc build isn't under your 
control) this should be implemented by creating a new "platform" - cramming 
this into the "posix" platform is plain wrong since posix really does support 
the getaddrinfo etc. interfaces.

As a first cut call it something like "uclibc-minimal".

In this case it seems you could reuse the existing src/posix/ code but add a 
new directory src/uclibc-minimal/ for the extra code you need to implement 
getaddrinfo etc. Then detect/configure your specific configuration in cmake and 
add in the new file(s) to the build.

Incidentally I pretty sure you can't include <arpa/inet.h> in platform.h 
because this just defines the platform API but is not platform specific. 
arpa/int.h is only supported on POSIX.


> Implement pn_getaddrinfo,pn_getprotobyname for platforms that not support 
> getaddrinfo(),getprotobyname() 
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: PROTON-852
>                 URL: https://issues.apache.org/jira/browse/PROTON-852
>             Project: Qpid Proton
>          Issue Type: New Feature
>          Components: proton-c
>    Affects Versions: 0.9, 0.9.1, 0.10
>         Environment: uclinux m68k
>            Reporter: Tomasz Nowicki
>            Assignee: Andrew Stitcher
>              Labels: patch
>             Fix For: 0.12.0
>
>         Attachments: proton-c-GETADDRINFO.patch
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> We are using proton-c on a small ebedded system based on uclinux/uclibc.c On 
> this platform several required functions ex getaddrinfo(), getprotobyname() 
> are not implemented.We added support for this type of platform by wraping 
> with pn_getaddrinfo,pn_getprotobyname.  Relevant pn_freeaddrinfo is also 
> introduced. If GETADDRINFO_NOT_IMPL flag is not present, native 
> implementation is called. Changes apply for posix versions that use old lib.c 
> Specifically in some embedded versions "get host" is not present(ip address 
> is used instead).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to