Skip to content

Commit ddf748a

Browse files
Add Swift extension as a separate pod
Summary: Adds swift extension file as a separate subspec, as it is not required for the objc projects. Also this fixes the current issue where the flipper sample app fails to build on xcode 11, as it fails to link the Swift specific literals. Fixes this too #565 Reviewed By: SidharthGuglani Differential Revision: D18373993 fbshipit-source-id: 0c058886a837c7ceafcd0167f878b3e0f7763aa1
1 parent 4d16ee4 commit ddf748a

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

YogaKit.podspec

+14-5
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
podspec = Pod::Spec.new do |spec|
77
spec.name = 'YogaKit'
8-
spec.version = '1.14.0'
8+
spec.version = '1.17.0'
99
spec.license = { :type => 'MIT', :file => "LICENSE" }
1010
spec.homepage = 'https://facebook.github.io/yoga/'
1111
spec.documentation_url = 'https://facebook.github.io/yoga/docs/'
@@ -22,11 +22,20 @@ podspec = Pod::Spec.new do |spec|
2222
spec.platform = :ios
2323
spec.ios.deployment_target = '8.0'
2424
spec.ios.frameworks = 'UIKit'
25+
spec.default_subspec = "Core"
2526
spec.dependency 'Yoga', '~> 1.14'
26-
spec.source_files = 'YogaKit/Source/*.{h,m,swift}'
27-
spec.public_header_files = 'YogaKit/Source/{YGLayout,UIView+Yoga}.h'
28-
spec.private_header_files = 'YogaKit/Source/YGLayout+Private.h'
29-
spec.swift_version = '4.0'
27+
spec.module_name = 'YogaKit'
28+
29+
spec.subspec "Core" do |ss|
30+
ss.source_files = 'YogaKit/Source/*.{h,m}'
31+
ss.public_header_files = 'YogaKit/Source/{YGLayout,UIView+Yoga}.h'
32+
ss.private_header_files = 'YogaKit/Source/YGLayout+Private.h'
33+
end
34+
35+
spec.subspec 'SwiftExtension' do |ss|
36+
ss.source_files = 'YogaKit/Source/*.{swift}'
37+
end
38+
3039
end
3140

3241
# See https://github.com/facebook/yoga/pull/366

0 commit comments

Comments
 (0)