Carthage: Code signing is required for product type 'Framework' in SDK 'iOS 10.0'

Created on 30 Jun 2016  路  11Comments  路  Source: Carthage/Carthage

Hi,
I try to build a project with Xcode 8. This project manage multiple frameworks with Carthage.
On the main project I include xcodeproj of all frameworks as a sub-projects. Like this I can put a break point on the source if it's need it.
When I open this project with Xcode 8 for all frameworks I have this error:

Signing for <framework> requires a development team. Select a development team in the Target Editor.
Code signing is required for product type 'Framework' in SDK 'iOS 10.0'

For my framework it's ok I can define a development team. But for others they are public frameworks they don't have to define a team.
How we can manage this case? With Carthage do we have an option like --team to force a team on each framework? Do we have to sign binary framework for close source framework?

question

Most helpful comment

An error is occurring in this case, I have embedded frameworks generated by Carthage Build into my project and it is not able to archive and upload to iTunes because of the error:

Code signing "CocoaAsyncSocket.framework" failed.

image

This can be avoided if I just link the framework using Copy-Framework script and not embed into project but in that case i am getting Build Invalid Mail from Itunes.

Invalid Bundle - One or more dynamic libraries that are referenced by your app are not present in the dylib search path.

All 11 comments

Frameworks do need to be signed, but they don't need to be signed at compile team because they'll be re-signed when you include them in your app.

Carthage completely disables code signing when it builds frameworks because of this.

Yes, there should be no problem for building frameworks by carthage update/build. But if you are integrating checked out projects into your project, some code signing related build settings should be modified in the frameworks' project to completely disable code signing, as seen in https://github.com/ikesyo/Himotoki/pull/130.

@ikesyo For sure I can change the setting of the projects locally but I can not commit this change. The projects on the checkout folder are not my projects. Each time I will do a git clone or even a carthage update I will be obliged to change the setting again 馃槬

Carthage can not control the project settings neither when you use manual integration. So you should change the settings at a forked repository and submit a pll request to its upstream (or directly use the forked repo in your Cartfile).

@ikesyo Even if I uncheck Automatically manage signing on a sub-project I still have the message:

Signing for <framework> requires a development team. Select a development team in the Target Editor.
Code signing is required for product type 'Framework' in SDK 'iOS 10.0'

Submit a pull request for the project with uncheck Automatically manage signing setting will not help.
Include project framework as sub-project is very useful to debug unexpected behavior of a framework or to develop our frameworks.
I know is not Carthage issue more an issue with Xcode 8

Please see https://github.com/ikesyo/Himotoki/pull/130 as an example. You should add CODE_SIGNING_REQUIRED=NO user-defined setting and set CODE_SIGN_IDENTITY= (select Don't Code Sign for Code Signing Identity setting). Automatically manage signing is not the point.

I know is not Carthage issue more an issue with Xcode 8

Exactly. This is not related to Carthage. You would have the same issue even if you don't use Carthage and use submodules manually instead.

Please see ikesyo/Himotoki#130 as an example

OK I'll take a look. Thanks @ikesyo :)

An error is occurring in this case, I have embedded frameworks generated by Carthage Build into my project and it is not able to archive and upload to iTunes because of the error:

Code signing "CocoaAsyncSocket.framework" failed.

image

This can be avoided if I just link the framework using Copy-Framework script and not embed into project but in that case i am getting Build Invalid Mail from Itunes.

Invalid Bundle - One or more dynamic libraries that are referenced by your app are not present in the dylib search path.

Hi @TheMrugraj

Did you manage to find a solution for this code signing problem?

@ardalahmet @TheMrugraj Check out this solution https://stackoverflow.com/a/41416964/4654659

They've updated the README for Xcode 11 yesterday. Following the not-embed and copy-frameworks procedure fixed it for me. Super happy about the timing 馃槂

Was this page helpful?
0 / 5 - 0 ratings