swiftlang / swift-source-compat-suite

The infrastructure and project index comprising the Swift source compatibility suite.
Apache License 2.0
284 stars 150 forks source link

Support specification of compatibility with `--static-swift-stdlib` #881

Open MahdiBM opened 9 months ago

MahdiBM commented 9 months ago

As mentioned in issues such as https://github.com/apple/swift/pull/68671 and https://github.com/apple/swift/issues/65097, sometimes a Swift change is incompatible with --static-swift-stdlib (as in swift build -c release --static-swift-stdlib) but the problem is only discovered later on, after a Swift release. This is despite the fact that using --static-swift-stdlib is very common in Server-Side Swift apps, and reference files such as Vapor's template Dockerfile have been using this flag for a long time. All these while SE-0342 proposed --static-swift-stdlib to become the default behavior on platforms like Linux, which has yet to take effect.

So, the question is: should this repository support a JSON field to specify compatibility with --static-swift-stdlib (e.g. build_static_stdlib? That way, it might be easier for the Swift team to keep track of compatibility of Swift releases with projects that use the --static-swift-stdlib flag. Penny can be the first project to specify compatibility with that flag in the projects.json.