Skip to content
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

Add support for new Android overlay (import Android) #7615

Merged
merged 1 commit into from
Jun 20, 2024

Conversation

finagolfin
Copy link
Member

This adds the overlay to four of the six files that currently import Glibc, with those last two showing no difference if this wasn't added, like PackageDescription.swift.

@finagolfin
Copy link
Member Author

Updated to remove the libc imports altogether from those two files where not adding the Android overlay didn't matter, and found that everything worked fine on linux x86_64 too. Let's run the CI and see if it makes a difference on any platform, as I suppose this may be handled differently on Darwin or Windows.

@kateinoigakukun, would you run the CI on this now?

@finagolfin
Copy link
Member Author

@MaxDesiatov, need a CI run here.

@kateinoigakukun
Copy link
Member

@swift-ci test

@finagolfin finagolfin marked this pull request as ready for review June 10, 2024 10:02
@finagolfin
Copy link
Member Author

All CI passed except for Windows, so I put back that one Windows import alone. I can restore all those libc imports, if there's concern they might be needed in other compilation scenarios. I have no idea when these libc imports are needed, so just going off compilation failures now.

Another CI run and this should be ready for review.

@kateinoigakukun
Copy link
Member

@swift-ci test

Also, remove most libc imports for one file and one test where they weren't needed.
@finagolfin
Copy link
Member Author

Sigh, I thought I could quickly fix some of those @_implementationOnly deprecation warnings, but it looks like that requires fixing other files too, so reverted the part of this pull where I added internal imports.

Another CI run and we can see if this passes now.

@kateinoigakukun
Copy link
Member

@swift-ci test

import Musl
#elseif os(Windows)
import MSVCRT
import WinSDK
Copy link
Member Author

Choose a reason for hiding this comment

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

@hyp, the Windows CI passed but I notice it doesn't run the SPM tests, just builds the source? Let me know if this change is okay on Windows.

@finagolfin
Copy link
Member Author

@xedin, maybe you can review?

@finagolfin
Copy link
Member Author

@bnbarham, looking for review on this tiny pull, as I currently have to manually patch the swift-package executable on my Android CI because it generates the wrong test file for the current trunk stdlib that uses this new Android overlay.

@bnbarham
Copy link
Contributor

@swift-ci please test Windows platform

@MaxDesiatov MaxDesiatov changed the title Add support for new Android overlay being worked on in apple/swift#72634 Add support for new Android overlay Jun 20, 2024
@MaxDesiatov MaxDesiatov changed the title Add support for new Android overlay Add support for new Android overlay (import Android) Jun 20, 2024
@MaxDesiatov MaxDesiatov merged commit 71d4407 into swiftlang:main Jun 20, 2024
5 checks passed
@finagolfin finagolfin deleted the droid branch June 21, 2024 10:18
finagolfin added a commit to finagolfin/swift-package-manager that referenced this pull request Jul 3, 2024
This adds the overlay to four of the six files that currently `import
Glibc`, with those last two showing no difference if this _wasn't_
added, like `PackageDescription.swift`.
finagolfin added a commit to finagolfin/swift-package-manager that referenced this pull request Jul 9, 2024
This adds the overlay to four of the six files that currently `import
Glibc`, with those last two showing no difference if this _wasn't_
added, like `PackageDescription.swift`.
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.

4 participants