Carthage: static library scheme support

Created on 17 Jan 2019  路  4Comments  路  Source: Carthage/Carthage

  • carthage install method: [ ] .pkg, [x] homebrew, [ ] source
  • which carthage: /usr/local/bin/carthage
  • carthage version: 0.31.2
  • xcodebuild -version: Xcode 10.1 Build version 10B61
  • Are you using --no-build? no
  • Are you using --no-use-binaries? no
  • Are you using --use-submodules? no
  • Are you using --cache-builds? no
  • Are you using --new-resolver? no

Cartfile

github "google/EarlGrey" "earlgrey2"

Carthage Output

$ carthage update
*** Fetching EarlGrey
*** Checking out EarlGrey at "a4d0b3f0309910bc34a7543dd588f680e71f49db"
*** xcodebuild output can be found in /var/folders/14/h2zk5sx1315b__blzdt7hz1m4k0by8/T/carthage-xcodebuild.PKzH6q.log
*** Building scheme "AppFramework" in EarlGrey.xcodeproj

Actual outcome
Carthage did not build the static library schemes.

Expected outcome
Carthage should have built the static library schemes in addition to the framework scheme.

image

https://github.com/google/EarlGrey/pull/787

I found this in the readme:

Carthage does not currently support static library schemes, nor are there any plans to introduce their support in the future.

I'd like to understand why static library schemes are not supported. Let me know. Thanks!

question

Most helpful comment

Because static libraries add additional problems that must be solved: like how to expose the headers for the projects that use the dependency. Static frameworks support this nicely (it's basically a static library that's bundled with the headers), so there's no reason to support static libraries by themselves.

All 4 comments

Because static libraries add additional problems that must be solved: like how to expose the headers for the projects that use the dependency. Static frameworks support this nicely (it's basically a static library that's bundled with the headers), so there's no reason to support static libraries by themselves.

Thank you!

Can you explain "static framework" a bit more and how to generate this with Xcode? If I have a dependency that is a static library, but I do not expose the headers (hypothetically), would that not work?

For clarification from the Carthage folks -

If I provide a pre-compiled framework (dylib) which has static library dependencies, then there shouldn't be an issue with Carthage as the building is already done?

Was this page helpful?
0 / 5 - 0 ratings