LinkedInAttic / LayoutKit

LayoutKit is a fast view layout library for iOS, macOS, and tvOS.
http://layoutkit.org
Apache License 2.0
3.16k stars 267 forks source link

Add Cocoapods static_framework support #176

Open soniccat opened 6 years ago

soniccat commented 6 years ago

I see Cocoapods RC (1.4.0.rc.1) supports swift static frameworks. Added that to avoid creating a dynamic library. The latest Cocoapods RC can be installed using this command sudo gem install cocoapods --pre

staguer commented 6 years ago

Hi @soniccat ! Can you please link me to some documentation for this static_framework flag?

Also, is this something that should be determined by those entities that import LayoutKit rather than by LayoutKit itself?

soniccat commented 6 years ago

@staguer hi, here it is http://blog.cocoapods.org/CocoaPods-1.4.0/ I see they have written it recently

can't say about dependencies, need to read the doc, it seems setting the flag should be enough, at least I've tested that it works

nicksnyder commented 6 years ago

Lgtm based on reading doc. Any downsides?

chenxiao0228 commented 6 years ago

Enabling this will cause the binary to be linked statically.

If the pod consumer has multiple targets using LayoutKit, LayoutKit will be liked multiple times.

Agree with @staguer it might be more appropriate for the consumers to decide how it will be linked.

Cocoapods 1.5.0 is adding support for this use case, FYI.