tuist / tuist

Tuist's CLI
https://tuist.dev
MIT License
4.65k stars 566 forks source link

Dependencies.swift SPM BinaryTarget’s xcframework are not available in artifacts folder #3269

Closed apps4everyone closed 3 years ago

apps4everyone commented 3 years ago

When using the new Dependencies.swift (build from feature/dependencies/spm/container) SPM external dependencies with BinaryTargets the xcframework's are not available in the artifacts folder.

I get the error: Couldn’t find xcframework at ...project/Tuist/Dependencies/SwiftPackageManager/artifacts/XYZSDK/ZYX.xcframework

danieleformichelli commented 3 years ago

Hi @apps4everyone, could you add a real case example? Using the project attached in this issue the Firebase artifacts get correctly downloaded in the artifacts folder

apps4everyone commented 3 years ago

hey, thx tested your example and it worked. Unfortunately it is an internal swift package with:

.binaryTarget( name: "ZYX", path: "frameworks/ZYX.xcframework" ),

inside the package. The difference I can see here is Firebase is using zip with url and hash not path.

danieleformichelli commented 3 years ago

Is the artifact used in any of the products of that package? If not, it's probably the reason why SPM doesn't download it.

apps4everyone commented 3 years ago

it is used inside of the Package.

danieleformichelli commented 3 years ago

As discussed with @apps4everyone , there is a missing mapping for SPM packages with local binary dependencies (while remote ones work fine). He will open a PR to fix the problem