-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Fix building and testing on FreeBSD; Add FreeBSD platform support #8193
base: main
Are you sure you want to change the base?
Changes from all commits
93679c2
5daa42a
f6d4064
4c728ce
d926944
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,11 +16,12 @@ public enum SystemPackageProviderDescription: Hashable, Codable, Sendable { | |
case apt([String]) | ||
case yum([String]) | ||
case nuget([String]) | ||
case pkg([String]) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is FreeBSD's
Here's some of my thoughts:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is also in my mind, originally I name this I'm not sure about OpenBSD tho, and currently the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, might be worth starting a Swift evolution thread on the naming. In the meantime you could land this behind an API availability of 999.0 |
||
} | ||
|
||
extension SystemPackageProviderDescription { | ||
private enum CodingKeys: String, CodingKey { | ||
case brew, apt, yum, nuget | ||
case brew, apt, yum, nuget, pkg | ||
} | ||
|
||
public func encode(to encoder: Encoder) throws { | ||
|
@@ -38,6 +39,9 @@ extension SystemPackageProviderDescription { | |
case let .nuget(a1): | ||
var unkeyedContainer = container.nestedUnkeyedContainer(forKey: .nuget) | ||
try unkeyedContainer.encode(a1) | ||
case let .pkg(a1): | ||
var unkeyedContainer = container.nestedUnkeyedContainer(forKey: .pkg) | ||
try unkeyedContainer.encode(a1) | ||
} | ||
} | ||
|
||
|
@@ -63,6 +67,10 @@ extension SystemPackageProviderDescription { | |
var unkeyedValues = try values.nestedUnkeyedContainer(forKey: key) | ||
let a1 = try unkeyedValues.decode([String].self) | ||
self = .nuget(a1) | ||
case .pkg: | ||
var unkeyedValues = try values.nestedUnkeyedContainer(forKey: key) | ||
let a1 = try unkeyedValues.decode([String].self) | ||
self = .pkg(a1) | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,6 +38,7 @@ public struct PlatformRegistry { | |
.macOS, | ||
.macCatalyst, | ||
.openbsd, | ||
.freebsd, | ||
.tvOS, | ||
.visionOS, | ||
.wasi, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great to see this port moving forward. 🥲
Have you tried using this SQLite package instead? The only reason most OSs above don't is that this is new: I switched my upcoming native 6.1 toolchain for Android over to using it and was able to remove the external libsqlite package dependency of this Swift toolchain as a result. I suggest you try the same, will require patching llbuild also.