Skip to content

SwiftBuildSupport: Revert patch required when we were using '#if canImport(SwiftBuild)' checks #8957

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

pmattos
Copy link
Contributor

@pmattos pmattos commented Jul 18, 2025

Motivation:

We couldn't call SwiftBuildSupport.PackagePIFBuilder from SwiftBuildSupport/BuildSystem.swift given the prior #if canImport(SwiftBuild) checks in former. This is no longer the case.

Modifications:

Provides a minor code cleanup in PackagePIFBuilder+Helpers.swift.

This is tracked by: rdar://139545019

@pmattos pmattos added the swift build Changes impacting `swift build` label Jul 18, 2025
@pmattos pmattos changed the title SwiftBuildSupport : Revert patch required when we were using '#if canImport(SwiftBuild)' checks SwiftBuildSupport: Revert patch required when we were using '#if canImport(SwiftBuild)' checks Jul 18, 2025
@pmattos
Copy link
Contributor Author

pmattos commented Jul 18, 2025

@swift-ci test

static func targetName(forProductName name: String, suffix: TargetSuffix? = nil) -> String {
return SwiftBuildSupport.targetName(forProductName: name, suffix: suffix?.rawValue)
let suffix = suffix?.rawValue ?? ""
return "\(name)\(suffix)-product"
Copy link
Contributor Author

@pmattos pmattos Jul 18, 2025

Choose a reason for hiding this comment

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

This is the main change! The rest is just some quick refactorings...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
swift build Changes impacting `swift build`
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant