Carthage: no shared framework schemes for iOS platform (for my own framework)
Asked Answered
E

5

27

I create a framework (called ProjectOne) built and tested it. I want to allow this framework to be used in Carthage. I edited my scheme and made the default "ProjectOne" scheme shared in XCODE. I did a carthage build and verified that the framework was build in Carthage/Build/iOS.

I then push to github and and create a release.

In another project, I'm using this framework. But, carthage reports "Dependency ProjectOne has no shared framework schemes for any of the platforms: iOS".

I'm pretty sure I shared the scheme in ProjectOne - does anyone know why this is happening?

Eliga answered 28/1, 2016 at 7:1 Comment(0)
E
49

The folks at Carthage helped me discover the issue - Xcode was not adding the schemes to git. Make sure that .xcodeproj/xcshareddata/xcschemes is added and pushed to github.

Eliga answered 31/1, 2016 at 7:46 Comment(6)
My scheme is Shared and is pushed to git, but unfortunately I still get the same error...Whitford
I'm not sure about your situation @Whitford but when I hit this issue, I thought my Shared scheme was pushed to git but it wasn't. I would look at your repo and see what is in .xcodeproj.Eliga
Yeah @Eliga it turned out it wasn't synchronising git properly. Thanks!Whitford
I used the following command and it worked: git add -A <ProjectName>.xcodeproj/Anglo
You might want to add variouse ignores to your .gitignore file so that only .xcscheme file is shared. A tip is to copy ignores from other github projects that use carthage like AlomofireSkellum
For those not seeing the xcshareddata folder within the project folder, a bug in Xcode currently exists where it won't be created until you go to Edit Schemes and untick and tick "Shared" at the bottom centre. It seems to be a bug that despite it being ticked it needs a reminder to create the folder.Epidermis
U
6

In my case the issue was due the way I've included repo url in my cartfile. I changed it from:

github "https://...UICore.git" == 1.0.0

to

git "https://... UICore.git" "master"

Unlawful answered 29/5, 2018 at 10:25 Comment(1)
This was also the case for me too, making sure the format is: git "githuburl.git" "branch"Huck
T
3

Click on Manage Schemes, and then un-flag and re-flag the “Shared” voice near "YourFramework". Go to terminal and now :

carthage build --no-skip-current
Therefore answered 9/4, 2021 at 0:53 Comment(1)
Too late to answer, but I have a hope, it would help others.Dishonorable
H
2

For me this was missing. I played around with scheme and pushed to GitHub PiAnimation.xcodeproj/xcshareddata/xcschemes/PiAnimation.xcscheme

Highness answered 28/10, 2019 at 20:7 Comment(0)
E
1

For me the problem was new version of Xcode. I've build project in newer Xcode version, but command line tool has been set to previous. To change it you should open Xcode -> Preferences -> Locations.

Elwaine answered 3/7, 2019 at 7:5 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.