Skip to content

Fix musl build warning on sys/poll.h - #346

Merged
willco007 merged 1 commit into
libssh2:masterfrom
orivej:poll
May 8, 2019
Merged

willco007 merged 1 commit into
libssh2:masterfrom
orivej:poll

Conversation

@orivej

@orivej orivej commented Mar 28, 2019

Copy link
Copy Markdown
Contributor

musl prints redirecting incorrect #include <sys/poll.h> to <poll.h>
http://git.musl-libc.org/cgit/musl/commit/include/sys/poll.h?id=54446d730cfb17c5f7bcf57f139458678f5066cc

poll is defined by POSIX to be in poll.h:
http://pubs.opengroup.org/onlinepubs/7908799/xsh/poll.html


libssh2 configure does not check which header file provides poll, only that it is present in the libc. I think it is not necessary to add such a check because poll.h should work everywhere.

@willco007

Copy link
Copy Markdown
Member

There are other places in the code where <sys/*.h is referenced. Should those be updated as well? Is this going to cause problems on other OS'?

@orivej

orivej commented Apr 17, 2019

Copy link
Copy Markdown
Contributor Author

I'm not aware of any other issues with libssh2 includes. POSIX defines that poll is in poll.h, but it also defines that connect is in sys/socket.h, and many other functions are in sys/ headers.

@willco007
willco007 merged commit 1130615 into libssh2:master May 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants