Summary: Pull Request resolved: https://github.com/facebook/flipper/pull/1016 YogaKit's version is compatible recent version of swift and also before the last release its swift version was not mentioned, which caused issues, but now there is no need to set the swift version. Reviewed By: passy Differential Revision: D21054723 fbshipit-source-id: 2210cf4beab86088533302028091e0bc44b9d232
54 lines
2.3 KiB
Ruby
54 lines
2.3 KiB
Ruby
project 'Sample.xcodeproj'
|
|
source 'https://github.com/facebook/Sonar.git'
|
|
source 'https://github.com/CocoaPods/Specs'
|
|
|
|
target 'Sample' do
|
|
platform :ios, '9.0'
|
|
pod 'FlipperKit', :path => '../../FlipperKit.podspec'
|
|
pod 'FlipperKit/FlipperKitLayoutComponentKitSupport', :path => '../../FlipperKit.podspec'
|
|
pod 'FlipperKit/SKIOSNetworkPlugin', :path => '../../FlipperKit.podspec'
|
|
pod 'FlipperKit/FlipperKitUserDefaultsPlugin', :path => '../../FlipperKit.podspec'
|
|
pod 'FlipperKit/FlipperKitExamplePlugin', :path => '../../FlipperKit.podspec'
|
|
pod 'FlipperKit/FlipperKitReactPlugin', :path => '../../FlipperKit.podspec'
|
|
pod 'Flipper', :path => '../../Flipper.podspec'
|
|
|
|
# If you use `use_frameworks!` in your Podfile,
|
|
# uncomment the below $static_framework array and also
|
|
# the pre_install section. This will cause Flipper and
|
|
# it's dependencies to be built as a static library and all other pods to
|
|
# be dynamic.
|
|
# $static_framework = ['FlipperKit', 'Flipper', 'Flipper-Folly',
|
|
# 'CocoaAsyncSocket', 'ComponentKit', 'DoubleConversion',
|
|
# 'glog', 'Flipper-PeerTalk', 'Flipper-RSocket', 'Yoga', 'YogaKit',
|
|
# 'CocoaLibEvent', 'OpenSSL-Universal', 'boost-for-react-native']
|
|
#
|
|
# pre_install do |installer|
|
|
# Pod::Installer::Xcode::TargetValidator.send(:define_method, :verify_no_static_framework_transitive_dependencies) {}
|
|
# installer.pod_targets.each do |pod|
|
|
# if $static_framework.include?(pod.name)
|
|
# def pod.build_type;
|
|
# Pod::Target::BuildType.static_library
|
|
# end
|
|
# end
|
|
# end
|
|
# end
|
|
|
|
# It also adds -DFB_SONARKIT_ENABLED=1 flag to OTHER_CFLAGS, necessary to build expose Flipper classes in the header files
|
|
post_install do |installer|
|
|
file_name = Dir.glob("*.xcodeproj")[0]
|
|
app_project = Xcodeproj::Project.open(file_name)
|
|
app_project.native_targets.each do |target|
|
|
target.build_configurations.each do |config|
|
|
cflags = config.build_settings['OTHER_CFLAGS'] || '$(inherited) '
|
|
unless cflags.include? '-DFB_SONARKIT_ENABLED=1'
|
|
puts 'Adding -DFB_SONARKIT_ENABLED=1 in OTHER_CFLAGS...'
|
|
cflags << '-DFB_SONARKIT_ENABLED=1'
|
|
end
|
|
config.build_settings['OTHER_CFLAGS'] = cflags
|
|
end
|
|
app_project.save
|
|
end
|
|
installer.pods_project.save
|
|
end
|
|
end
|