Skip to content

[Linux] Add missing glibc import for in_addr declaration #4598

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

Closed
wants to merge 1 commit into from

Conversation

bnbarham
Copy link
Contributor

@bnbarham bnbarham commented Jun 1, 2022

Rebranch is currently failing with:

swift-corelibs-foundation/Sources/FoundationNetworking/HTTPCookie.swift:626:17: error: cannot find 'in_addr' in scope
        var x = in_addr()
                ^~~~~~~

Import Glibc to grab the declaration.

@bnbarham bnbarham requested review from millenomi and compnerd June 1, 2022 19:27
@bnbarham
Copy link
Contributor Author

bnbarham commented Jun 1, 2022

@swift-ci please test

Copy link
Member

@compnerd compnerd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@bnbarham
Copy link
Contributor Author

bnbarham commented Jun 3, 2022

This isn't the issue - Foundation pulls in Glibc (and SwiftGlibc) so in_addr does exist, but it's also in CoreFoundation. The improper modularization is what's causing problems.

@bnbarham bnbarham closed this Jun 3, 2022
@bnbarham bnbarham deleted the fix-linux-inaddr-failure branch June 3, 2022 16:35
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