Skip to content
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

Does not build for release with the Xcode 13 GM #175

Closed
jsorge opened this issue Sep 14, 2021 · 4 comments
Closed

Does not build for release with the Xcode 13 GM #175

jsorge opened this issue Sep 14, 2021 · 4 comments

Comments

@jsorge
Copy link
Contributor

jsorge commented Sep 14, 2021

I'm trying to build swift-sh using Xcode 13 GM and I get the following error:

/Users/q1214382/Developer/swift-sh/.build/checkouts/PathKit/Sources/PathKit.swift:583:12: error: value of optional type 'UnsafeMutablePointer<CChar>?' (aka 'Optional<UnsafeMutablePointer<Int8>>') must be unwrapped to a value of type 'UnsafeMutablePointer<CChar>' (aka 'UnsafeMutablePointer<Int8>')
      free(cPattern)
           ^
/Users/q1214382/Developer/swift-sh/.build/checkouts/PathKit/Sources/PathKit.swift:583:12: note: coalesce using '??' to provide a default when the optional value contains 'nil'
      free(cPattern)
           ^
                    ?? <#default value#>
/Users/q1214382/Developer/swift-sh/.build/checkouts/PathKit/Sources/PathKit.swift:583:12: note: force-unwrap using '!' to abort execution if the optional value contains 'nil'
      free(cPattern)
           ^
                   !
[3/10] Compiling PathKit PathKit.swift

The command I'm using is swift build -c release, and it's working just fine on Xcode 12.5.1. I'm wondering if something has changed in Swift 5.5 that's causing trouble.

@mxcl
Copy link
Owner

mxcl commented Sep 15, 2021

This should be reported to PathKit presumably.

You can just build swift-sh with swift build -c release --product swift-sh

@jsorge
Copy link
Contributor Author

jsorge commented Sep 15, 2021

Yeah I reported it there after here. Sorry for the panicked initial report and the workaround for my issue! 🙂

@mxcl
Copy link
Owner

mxcl commented Sep 15, 2021

Did swift build -c release --product swift-sh work? The swift-sh-edit binary is less useful anyway.

@jsorge
Copy link
Contributor Author

jsorge commented Sep 15, 2021

Yep that worked great

@mxcl mxcl closed this as completed Sep 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants