Skip to content

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...

@pmattos pmattos merged commit f19d08c into main Jul 21, 2025
6 checks passed
@pmattos pmattos deleted the canImport-SwiftBuild-cleanup branch July 21, 2025 22:30
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.

2 participants