mirror of
https://github.com/zhigang1992/facebook-ios-sdk.git
synced 2026-01-12 22:47:16 +08:00
Summary: Thanks for proposing a pull request! To help us review the request, please complete the following: - [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla) - [x] I've ensured that all existing tests pass and added tests (when/where necessary) - [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary) - [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes) ## Pull Request Details Added a `Package.swift` manifest. Updated imports to be non-modular for non-cocoapod setups. Updated dynamic framework loader to compile with arc. - This should be checked. Not 100% sure I did not cause a regression. Added a directory of symlinks to public header files - this was to get around a limitation in the SPM api where they will only accepts a path to header files (forces them to be located in the same directory) and not a list of header files. Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1073 Test Plan: **SPM:** `cd fbsource/fbobjc/ios-sdk` Initialize a new repository, add all the files and create a new commit on master. `git init` `git add .` `git commit -m "new commit"` Open the package itself with >= Xcode 11 by opening `Package.swift` instead of the usual project and verify that it builds Open a new project with >= Xcode 11 and add a new swift package. For the Package Repository field put the path to the sdk. `file:///Users/$whoami/fbsource/fbobjc/ios-sdk` then specify the branch as `master`. This sample project should build and you should be able to consume the kits with `import FBSDKCoreKit` or `FacebookCore` (for the Swift variant), `import FBSDKLoginKit` or `import FacebookLogin` and `import FBSDKShareKit` or `import FacebookShare`. Make sure that LoginKit and ShareKit also expose CoreKit symbols. **Xcode:** Can build all schemes as expected `BuildAllKits` `FBSDKTVOSKit-Universal` `FBSDKTVOSKit-Dynamic` `SwiftKits` **CocoaPods:** `cd fbsource/fbojbc/ios-sdk` `bundle exec pod lib lint FBSDKCoreKit.podspec` `bundle exec pod lib lint FBSDKLoginKit.podspec --include-podspecs=FBSDKCoreKit.podspec --allow-warnings` `bundle exec pod lib lint FBSDKShareKit.podspec --include-podspecs=FBSDKCoreKit.podspec --allow-warnings` **BUCK:** `cd fbsource/fbobjc/ios-sdk` `buck build ios-sdk:FBSDKCoreKit` `buck build ios-sdk:FBSDKLoginKit` `buck build ios-sdk:FBSDKShareKit` Also all of the other BUCK targets (will be covered by sandcastle) Reviewed By: dreamolight Differential Revision: D17879652 Pulled By: joesus fbshipit-source-id: d931140d0fb3b554f1e29e5c2af7e2173316670d
107 lines
6.4 KiB
Ruby
107 lines
6.4 KiB
Ruby
# Use the --use-libraries switch when pushing or linting this podspec
|
|
|
|
Pod::Spec.new do |s|
|
|
|
|
s.name = 'FBSDKShareKit'
|
|
s.version = '5.8.0'
|
|
s.summary = 'Official Facebook SDK for iOS to access Facebook Platform Sharing Features'
|
|
|
|
s.description = <<-DESC
|
|
The Facebook SDK for iOS ShareKit framework provides:
|
|
* Share content with Share Dialog and Message Dialog.
|
|
* Send Game Requests or App Invites to grow your app.
|
|
* Publish content and open graph stories with the Graph API
|
|
DESC
|
|
|
|
s.homepage = 'https://developers.facebook.com/docs/ios/'
|
|
s.license = { :type => 'Facebook Platform License', :file => 'LICENSE' }
|
|
s.author = 'Facebook'
|
|
|
|
s.platform = :ios, :tvos
|
|
s.ios.deployment_target = '8.0'
|
|
s.tvos.deployment_target = '10.0'
|
|
|
|
s.source = { :git => 'https://github.com/facebook/facebook-ios-sdk.git',
|
|
:tag => "v#{s.version}"
|
|
}
|
|
|
|
s.ios.weak_frameworks = 'Accounts', 'AudioToolbox', 'CoreGraphics', 'CoreLocation', 'Foundation', 'QuartzCore', 'Security', 'Social', 'UIKit'
|
|
s.tvos.weak_frameworks = 'AudioToolbox', 'CoreGraphics', 'CoreLocation', 'Foundation', 'QuartzCore', 'Security', 'UIKit'
|
|
|
|
s.requires_arc = true
|
|
|
|
s.default_subspecs = 'Share'
|
|
s.swift_version = '5.0'
|
|
|
|
s.header_dir = 'FBSDKShareKit'
|
|
|
|
s.subspec 'Share' do |ss|
|
|
ss.dependency 'FBSDKCoreKit', "~> 5.0"
|
|
|
|
ss.public_header_files = 'FBSDKShareKit/FBSDKShareKit/*.{h}'
|
|
ss.ios.source_files = 'FBSDKShareKit/FBSDKShareKit/**/*.{h,m}'
|
|
ss.ios.exclude_files = 'FBSDKShareKit/FBSDKShareKit/FBSDKDeviceShareButton.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKDeviceShareViewController.{h,m}'
|
|
ss.tvos.exclude_files = 'FBSDKShareKit/FBSDKShareKit/FBSDKAppGroupAddDialog.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKAppGroupContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKAppGroupJoinDialog.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKAppInviteContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKAppInviteDialog.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKCameraEffectArguments.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKCameraEffectTextures.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestDialog.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKLikeButton.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKLikeControl.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKLikeObjectType.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKLiking.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKMessageDialog.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSendButton.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareButton.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareCameraEffectContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareDialog.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareDialogMode.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharingButton.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharingScheme.{h,m}'
|
|
ss.tvos.source_files = 'FBSDKShareKit/FBSDKShareKit/FBSDKDeviceShareButton.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKDeviceShareViewController.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKHashtag.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareKit.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareAPI.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareConstants.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareConstants.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareLinkContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMediaContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareOpenGraphAction.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareOpenGraphContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareOpenGraphObject.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareOpenGraphValueContainer.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharePhoto.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharePhotoContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareVideo.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareVideoContent.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharing.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharingContent.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKSharingValidation.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMessengerActionButton.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMessengerGenericTemplateContent.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMessengerGenericTemplateElement.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMessengerMediaTemplateContent.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMessengerOpenGraphMusicTemplateContent.h',
|
|
'FBSDKShareKit/FBSDKShareKit/FBSDKShareMessengerURLActionButton.h',
|
|
'FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareDefines.h',
|
|
'FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareError.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareOpenGraphValueContainer+Internal.h',
|
|
'FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareUtility.{h,m}',
|
|
'FBSDKShareKit/FBSDKShareKit/Internal/FBSDKVideoUploader.{h,m}'
|
|
end
|
|
|
|
s.subspec 'Swift' do |ss|
|
|
ss.dependency 'FBSDKCoreKit/Swift', "~> #{s.version}"
|
|
ss.dependency 'FBSDKShareKit/Share'
|
|
ss.platform = :ios
|
|
ss.ios.source_files = 'FBSDKShareKit/FBSDKShareKit/Swift/*.{swift}'
|
|
ss.ios.exclude_files = 'FBSDKShareKit/FBSDKShareKit/Swift/Exports.swift'
|
|
end
|
|
end
|