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 work with KMP 1.4.20 #8

Closed
sebarthel89 opened this issue Nov 27, 2020 · 4 comments · Fixed by #9
Closed

Does not work with KMP 1.4.20 #8

sebarthel89 opened this issue Nov 27, 2020 · 4 comments · Fixed by #9
Assignees
Labels
bug Something isn't working

Comments

@sebarthel89
Copy link

Hi,

thanks for this plugin, it looks exactly what I am looking for.

Unfortunately, I can't get the tasks run successfully with a fresh KMP project version 1.4.20.

My settings:

multiplatformSwiftPackage {
    swiftToolsVersion("5.3")
    targetPlatforms {
        iOS { v("13") }
    }
}

I get 2 errros:

  1. Package name is invalid: null
* What went wrong:
A problem occurred configuring root project 'centralized-key-value-library'.
> Could not create task ':createXCFramework'.
   > * Package name is invalid: null
       Either declare the base name of your frameworks or use a non-empty package name.

I can fix this by setting it manually:

multiplatformSwiftPackage {
    swiftToolsVersion("5.3")
    targetPlatforms {
        iOS { v("13") }
    }
    packageName(project.name)
}
  1. at least one framework or library must be specified.
> Task :createXCFramework FAILED
error: at least one framework or library must be specified

I could not fix this one on my own. Maybe some internal structure has been changed?

@ge-org
Copy link
Owner

ge-org commented Nov 27, 2020

Hi @sebarthel89,

could you share the entire build.gradle file? Or at least the parts where the KMP project is configured?

@sebarthel89
Copy link
Author

Sure, here is a minimal example:
https://github.com/sebarthel89/example-kmp-swift-package

@ge-org
Copy link
Owner

ge-org commented Nov 28, 2020

Hey @sebarthel89,

thanks again for the bug report and the sample project.

I published version 2.0.2 which contains a fix. This should also allow you to get rid of the packageName(project.name) config.

It will take a couple of hours for the release to show up on Maven Central. In the meantime you can use version 2.0.2-SNAPSHOT.

@sebarthel89
Copy link
Author

Works, very cool, thank you!

I will create another issue to target a fat framework issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants