-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Fix compilation issues with HAS_DISPATCH on Linux #257
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
@@ -850,9 +850,6 @@ CF_INLINE const char *CFPathRelativeToAppleFrameworksRoot(const char *path, Bool | |||
#if (DEPLOYMENT_TARGET_MACOSX || DEPLOYMENT_TARGET_EMBEDDED || DEPLOYMENT_TARGET_EMBEDDED_MINI || DEPLOYMENT_TARGET_LINUX) | |||
#if __HAS_DISPATCH__ | |||
|
|||
#include <dispatch/dispatch.h> | |||
#include <dispatch/private.h> |
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.
why don't we have /usr/local/include/dispatch/private.h? can we just pass across private header paths if it isn't installed into a staging sysroot?
and I am not certain that /usr/include/dispatch/dispatch.h missing is a good thing. If that is not actually missing then perhaps we should just move the private.h out only.
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.
We don't have a dispatch/private.h on Linux so it needs to be removed (at least for now). There's also no direct need to reference dispatch/dispatch.h from CFInternal.h, but I'll, update to retain the reference.
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.
There's a workaround for dispatch/private.h in the pending overlay pull requests. Basically it exploits the symlink that is made by configure from
Sorry, I realised I'd created the pull request from and old working branch in my repo. I've updated the PR with the correct changes. The reference to |
Thanks @dgrove-oss . Given that the reference to private.h is still protected under |
@phausler Changes made and commits squashed in place. Could you take another look? |
looks good to me |
Fix compilation issues with HAS_DISPATCH on Linux
Thanks @phausler ! |
[build-script] Remove hard-coded install prefix of /usr and pass it in instead
[pull] swiftwasm from main
As part of the prep work I'm doing with @dgrove-oss to enable Dispatch, I've done some testing of compiling swift-corelibs-foundation with
__HAS_DISPATCH__
enabled. That's highlighted a number of compile errors which this PR resolves.Enabling
__HAS_DISPATCH__
will still result in linker errors, which we'll look to resolve once we have the Dispatch overlay built into lib dispatch on Linux (libdispatch PR #43, and made the necessary modifications to the foundation build scripts.