-
Notifications
You must be signed in to change notification settings - Fork 471
added a sys/queue.h implementation for Windows #368
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
We can't do that this isn't the proper license. @jrose-apple @jckarter @tkremenek what can we do here? @dplanitzer is there a way to get it from somewhere else? e.g. on linux we use libbsd as a way to get this header from the "SDK". |
Why can't we use libbsd? I've been building against libbsd for Windows. |
I've been working on adding Windows support to libbsd: https://gitlab.freedesktop.org/libbsd/libbsd/merge_requests/1 |
What precisely is the dependency here on libbsd? Is it just to get a header, or a link dependency? The license issue just needs to be reviewed (I can consult Apple's lawyers), but not necessarily a blocker. |
See my comment here. I can create an independent implementation of needed queue macros instead if that makes things simpler. |
@dplanitzer I get a 404 with that link |
@tkremenek sorry about that. Fixed it. It's the last comment on the page. |
@MadCoder @tkremenek I've updated the PR with an independent implementation of the relevant TAILQ macros. Libdispatch only uses a handful of them anyway. I've tested the implementation locally and verified that it works beautifully :) |
@swift-ci please test |
@dplanitzer was the relevant implementation of |
@tkremenek I did a new implementation from scratch based on the documentation in the man 3 queue page. It's a simple standard doubly-linked list implementation while the sys/queue.h thing does something more fancy to avoid a few if-then checks on list manipulation. |
@dplanitzer OK, perfect. |
I think we can merge this. |
added a sys/queue.h implementation for Windows Signed-off-by: Kim Topley <[email protected]>
Added a copy of the Apple / Darwin sys/queue.h and hooked things up such that we use that one when building on Windows because the Windows SDK doesn't come with a sys/queue.h header.