-
Notifications
You must be signed in to change notification settings - Fork 469
Port transform and use libbsd #13
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
Port transform and use libbsd #13
Conversation
Looks interesting, I don't have a linux setup (yet?) so @dgrove-oss (or any other people involved with the linux port) should have a look that it works for them. |
I can take a look and verify whether or not it builds for me. The main question I have is whether or not we want to add libbsd as a pre-req for libdispatch. It would make somethings simpler and maybe is expedient. But it is one more thing to install. Any guidance? |
To successfully link and run a test program, I had to put back in the stub definitions for mach_error_string and mach_task_self in shims/linux_stubs.c. With that tweak, it seems fine. On a previous pull request, Daniel had requested we use #ifdef APPLE instead of #if HAVE_MACH. Not sure if that also applies to this pull request too or if HAVE_MACH is ok to use in these files. |
void _dispatch_runloop_queue_dispose() { LINUX_PORT_ERROR(); } | ||
char* mach_error_string(mach_msg_return_t x) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to leave mach_error_string stubbed out to get a test program to link.
the libbsd-dev thing makes sense to me, it's available on all platforms, else you will have to redo what it does in dispatch which sounds like a waste. The argument against would be performance but I don't think strlcpy() and getprogname() are worth considering this. linux distro package systems will handle the rdeps for you just fine. |
…se-libbsd Fix src/Makefile.am
I fixed what @dgrove-oss asked for, and merged master to fix the libdispatch_la_LIBADD variable that was touched in two places now. |
…bbsd Port transform and use libbsd
…bbsd Port transform and use libbsd Signed-off-by: Daniel A. Steffen <dsteffen@apple.com>
Rebased branch
Just tackling some very low hanging fruits without understanding much yet :)