lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Exporting the real BSD socket API function names?


From: Mason
Subject: Re: [lwip-users] Exporting the real BSD socket API function names?
Date: Thu, 08 Mar 2012 14:03:42 +0100
User-agent: Mozilla/5.0 (Windows NT 5.1; rv:10.0.2) Gecko/20120216 Firefox/10.0.2 SeaMonkey/2.7.2

Simon Goldschmidt wrote:

> Mason wrote:
>
>> However, this was a red herring, and I'm still stuck building
>> libcurl. I think the main problem is that the lwip header
>> naming might not be 100% POSIX compliant, and libcurl can't
>> find a lot of network related declarations.
>>
>> I think I saw some discussion or bug reports concerning POSIX
>> compliance of headers, or am I mistaken?
> 
> There were discussions on one of the lists, but there are no bug
> reports. I don't personally see a pressing requirement to do so
> (mainly because I don't use lwIP sockets, I guess).
> 
> I do admit that lwIP does not conform to the posix standard, though,
> which probably makes using it in standard applications harder than it
> could be.
> 
> I'd love to see the headers changed to be posix conformant while
> a) being backwards-compatible for old lwIP applications and
> b) this must be optional to ensure lwIP doesn't produce compiler
> errors where the posix headers are already implemented (and
> included)
> 
> I guess it would be best to place these headers into a subdirectory
> of the default include directory. Adding a task at savannah might
> probably be a good idea -> done (task #11879). You're welcome to
> upload your files there if you happen to create them for your libcurl
> port.

I think the hardest problem will come from "generic" functions, i.e.
those that follow the UNIX philosophy that "everything is a file".

Namely: read, write, close, fcntl

These functions are typically used with actual files, but since
UNIX considers sockets as "files", one may use them with sockets.

So, my UNIX library provides "generic" functions that only
work with real files, and my network library provides the
same functions that only work with sockets.

And I have no idea (right now) how to convince the two libraries
to play nice! ;-)

Maybe I should try to convince libcurl to use the "lwip-"prefixed
function names. (But the configure script tries to link the raw
names anyway).

(sigh)

-- 
Regards.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]