-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[SourceKit] don't install libdispatch and libBlocksRuntime twice, outside of Mac/Windows #30096
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
…side of Mac/Windows
@benlangmuir, I think you added the first libdispatch install in #19921, let me know what you think. |
I did not add the install step, I fixed a missing dependency on it that was causing build issues. https://bugs.swift.org/browse/SR-8927 Maybe @compnerd knows better the intent. |
Btw @benlangmuir, I recently noticed that
|
@tachoknight, I just checked and saw that you copy both these and the libraries in @drodriguez, any feedback on this pull or the symbols I mentioned in the previous comment would be appreciated. |
@buttaface Is this in reference to requiring libBlocksRuntime for the build? A lot of what drives what I do is based on the user being able to install Hopefully that answers the question regarding libBlocksRuntime; I don't package libDispatch separately so that does need to be included in the swift-lang package. I'd ask that, if you don't want libDispatch in the Android version, you make it more explicit because I think this PR will break Ubuntu and Fedora. |
@buttaface we have an explicit exports list that only includes the sourcekitd-specific symbols, but it's only being applied on Darwin: https://github.com/apple/swift/blob/b58ea4bb377cd9978f9b056494c266db70faa80b/tools/SourceKit/cmake/modules/AddSwiftSourceKit.cmake#L2-L5 I don't know what the equivalent of |
No, I didn't even look at those.
No, I don't think you looked at the links in my original post: let me state the problem briefly. It always struck me as strange that the official Swift tarfile release for linux installs I haven't unpacked your final Fedora package to check, but based on your build script, my understanding is that you place one copy of these two libraries in Let me know if you actually need the former. @benlangmuir, thanks, I figured it was an oversight but wasn't sure. |
@buttaface Ah, sorry, yeah, I did look at the links and verified it against my installed copy. You're right in that's what I do; I'll have to check whether both are required. I did notice for the first time that the |
@compnerd: I think you will explain the reason of this double copy better than anyone. It would be good to have your comment here. @buttaface: please don't take my word as gospel, and let's wait for Saleem answers. I think there might be a confusion here. There might have been also changes over changes that might have modified the original intention of the change (specially with respect to rpaths and what libraries are linked against which libraries). The copy you don't want should only be installed if |
I've already removed these two libdispatch libraries from the Swift 5.1.4 for Android package script (see last link in my OP): I'm just submitting this back upstream so other packagers like Ron don't have to deal with this either and I can remove it from my local patches. As for not installing Btw, I just submitted a pull to get cross-compilation with the Android NDK working again, #30170, when using the updated commands from |
I don't think an answer is forthcoming, that linux rpath was already set before this install dependency was added. @benlangmuir, do you mind running the tests for this pull? I can also disable it for macOS if you think it's not needed there, just let me know. |
@swift-ci please test |
Alright, looks like this small cleanup doesn't break anything on linux/Android, and it changes nothing on mac/Windows (the Windows CI broke last week, long before this pull was tested, so a rerun of the Windows tests should work now), should be good to go. |
@swift-ci please test Windows platform |
Added in #19800, but unused on linux and Android, as their rpath uses the libdispatch.so in lib/swift/os. I don't know what happens on a mac, as I don't know what
@rpath
does, so I left it in for macOS.I've had to hack around this install before, but now I just patch it out for the Android package of Swift. Better to just not install it twice for platforms where it's not used, which may include macOS for all I know.