Skip to content

[PackageGraph/Build] Remove BuildTriple and its remaining uses #7896

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

Merged
merged 3 commits into from
Aug 21, 2024

Conversation

xedin
Copy link
Contributor

@xedin xedin commented Aug 20, 2024

Motivation:

Last uses of BuildTriple have been removed which means that there are no more recursive graph updates or duplicate targets.

Modifications:

  • Removes BuildTriple type
  • Removes buildTriple properties from Resolved{Product, Module} types and all of the recursive update logic associated with them
  • Updates BuildOperation to detect destination for products and modules if one wasn't provided by the caller. Only ambiguity here are tests but the rule is clear - direct macro dependencies cause all tests to be build for the "host".
  • Updates tests to use product/module build description destination where appropriate.

Result:

Hasta la vista, BuildTriple.

@xedin
Copy link
Contributor Author

xedin commented Aug 20, 2024

@swift-ci please test

@xedin
Copy link
Contributor Author

xedin commented Aug 20, 2024

Looks like the logic that select a destination for test products is not quiet right, I'll look into that tomorrow.

xedin added 2 commits August 20, 2024 11:48
Update tests to remove `BuildTriple` use and replace it with `BuildParameters.Destination`
…oduct to infer destination

When there are multiple packages involved, they are going to introduce
mutliple `<package-name>PackageTests` products. While inferring a destination
for a module we need to find the product it belongs to and infer based
on whether that product has any direct macro dependencies or not.
@xedin xedin force-pushed the hasta-la-vista-buildTriple branch from 55212c6 to e81a40f Compare August 20, 2024 20:05
@xedin
Copy link
Contributor Author

xedin commented Aug 20, 2024

@swift-ci please test

@xedin
Copy link
Contributor Author

xedin commented Aug 20, 2024

@swift-ci please test Windows platform

@xedin
Copy link
Contributor Author

xedin commented Aug 21, 2024

@swift-ci please test macOS

@xedin xedin merged commit 7ea21e1 into swiftlang:main Aug 21, 2024
5 checks passed
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