drmohundro / SWXMLHash

Simple XML parsing in Swift
MIT License
1.4k stars 203 forks source link

Support Swift Tools Version 5+ #241

Closed fgarciaDev closed 3 years ago

fgarciaDev commented 3 years ago

Is your feature request related to a problem? Please describe. The Package.swift specifies: // swift-tools-version:4.0 When creating Swift Package with out source code and only a XCFramework, with a dependency on this Swift Package, the generated swift interface files generate build errors when imported to a new project thru SPM: 'XMLIndexerDeserializable' is not a member type of 'SWXMLHash'

Describe the solution you'd like Support for swift tools 5+ in the Swift Package.

Describe alternatives you've considered Drop the supported swift tools version level in my own swift package to match, however, earlier version do not support XCFrameworks.

Additional context Full transparency, I've had a hard time finding documentation and support (e.g. stackoverflow) specific to Swift Packages made of XCFramework binaries with dependencies on other swift packages. It is possible this is not the reason for build issues I am experiencing, but I am hoping this package can still take that step forward to support new swift tools versions.

drmohundro commented 3 years ago

So, I'm not sure I'm following... the Package.swift file (see https://github.com/drmohundro/SWXMLHash/blob/main/Package.swift#L1) has // swift-tools-version:5.3 at the top, but your comment says it has 4.0 in it? Am I misunderstanding?

fgarciaDev commented 3 years ago

Well, that is embarrassing. I was looking at your latest tagged release. I see now it is in main. I guess I just need to wait for a new release. Apologies for the confusion. Looking at the releases, it seems as though that change should be in 5.0.1, but when I add that version to SPM, the config is still using swift-tools-version:4.0. Am I wrong thinking it should be available in your 5.0.1 release?

drmohundro commented 3 years ago

No, no worries. And maybe the issue you're seeing is that I just need to tag the latest commit on main. To be honest, thus far most usage of the library has been through CocoaPods or Carthage which I know takes the git tag into account; however, I'm honestly not sure if Swift Package Manager uses that or not. If it looks like it does, then I can pretty easily add in a new minor tag version to take that into account, though.

drmohundro commented 3 years ago

I pushed a 5.0.2 tag up in the hopes that it resolves this. Here's hoping!

drmohundro commented 3 years ago

I'm closing this... feel free to comment if there is still anything going on with this, though.