Le 25/11/2014 03:02, Joerg Sonnenberger a écrit :
On Tue, Nov 25, 2014 at 02:58:34AM +0100, Kamil Rytarowski wrote:Well... I see your point, on the other hand your variant doesn't solve my initial (and real) issue of code derived from OpenBSD -- unmodified code sharing.
Portable versions do reproduce specific APIs without requiring an import of functions that are specific to OpenBSD. OpenSSH comes to mind.
I do not know about libressl, but last time I read about it a compatibility library was discussed. Until now libressl remains "designed by OpenBSD for OpenBSD".
Why should we have to adopt questionable interfaces? "Because OpenBSD does it" alone is not a very good reason.
I tend to agree, however note that some ill-designed APIs do become used over time (sendfile{,64}, *at, ...). NetBSD has to cope with those too.
What about hiding these prototypes between __OPENBSD_COMPAT macros?I am against making them universally accessible without explicit flag though, especially if yet-another-project creates the same function but with a different prototype... That will become messy.
-- Jean-Yves Migeon