This repository was archived by the owner on Sep 15, 2025. It is now read-only.
Filed for reference – Steps taken to experiment with SPM#738
Closed
Filed for reference – Steps taken to experiment with SPM#738
Conversation
Notice the commented out WPKitLog* calls.
Was hoping it helped by a `pod lib lint` error, but that wasn't the case
And as much as I want to know why, and worry it might be a systemic issue that'll bite us later, I also want to move on with the SPM setup work.
Collaborator
Generated by 🚫 Danger |
Contributor
Author
|
Closing. Unrelated developments in new internal tooling make investing in restructuring WordPressKit to be SPM compatible less attractive. |
mokagio
added a commit
that referenced
this pull request
Mar 21, 2024
The SPM-compatible folder structure was giving me trouble when trying to
validate the `podspec`.
At first, I thought it was simply because
`WordPressComRESTAPIInterfacing.h` was not in a path known to CocoaPods.
But even after updating the `podspec` to:
```diff
@@ -18,9 +18,10 @@ Pod::Spec.new do |s|
s.swift_version = '5.0'
s.source = { git: 'https://github.com/wordpress-mobile/WordPressKit-iOS.git', tag: s.version.to_s }
- s.source_files = 'WordPressKit/**/*.{h,m,swift}'
+
+ s.source_files = 'WordPressKit/**/*.{h,m,swift}', 'Sources/**/*.{h,m,swift}'
+ s.public_header_files = 'Sources/**/include/*.h', 'WordPressKit/**/.h', 'WordPressKit/WordPressKit.h'
s.private_header_files = 'WordPressKit/Private/*.h'
- s.header_dir = 'WordPressKit'
s.dependency 'NSObject-SafeExpectations', '~> 0.0.4'
s.dependency 'wpxmlrpc', '~> 0.10'
```
I still got errors:
```
- ERROR | xcodebuild: /var/folders/dq/cdqxvx3s5ps75564rpmb_dc00000gn/T/CocoaPods-Lint-20240321-63072-nntpgw-WordPressKit/DerivedData/App/Build/Products/Release-iphonesimulator/WordPressKit/WordPressKit.framework/Headers/WordPressKit.h:10:9: error: 'WordPressKit/ServiceRemoteWordPressComREST.h' file not found
```
In the proof of concept from
#738, the SPM
folder structure is compatible with CocoaPods. As such, I decided to
defer moving the files to when I can do it in one go.
mokagio
added a commit
that referenced
this pull request
Mar 22, 2024
The SPM-compatible folder structure was giving me trouble when trying to
validate the `podspec`.
At first, I thought it was simply because
`WordPressComRESTAPIInterfacing.h` was not in a path known to CocoaPods.
But even after updating the `podspec` to:
```diff
@@ -18,9 +18,10 @@ Pod::Spec.new do |s|
s.swift_version = '5.0'
s.source = { git: 'https://github.com/wordpress-mobile/WordPressKit-iOS.git', tag: s.version.to_s }
- s.source_files = 'WordPressKit/**/*.{h,m,swift}'
+
+ s.source_files = 'WordPressKit/**/*.{h,m,swift}', 'Sources/**/*.{h,m,swift}'
+ s.public_header_files = 'Sources/**/include/*.h', 'WordPressKit/**/.h', 'WordPressKit/WordPressKit.h'
s.private_header_files = 'WordPressKit/Private/*.h'
- s.header_dir = 'WordPressKit'
s.dependency 'NSObject-SafeExpectations', '~> 0.0.4'
s.dependency 'wpxmlrpc', '~> 0.10'
```
I still got errors:
```
- ERROR | xcodebuild: /var/folders/dq/cdqxvx3s5ps75564rpmb_dc00000gn/T/CocoaPods-Lint-20240321-63072-nntpgw-WordPressKit/DerivedData/App/Build/Products/Release-iphonesimulator/WordPressKit/WordPressKit.framework/Headers/WordPressKit.h:10:9: error: 'WordPressKit/ServiceRemoteWordPressComREST.h' file not found
```
In the proof of concept from
#738, the SPM
folder structure is compatible with CocoaPods. As such, I decided to
defer moving the files to when I can do it in one go.
This was referenced Mar 22, 2024
pmusolino
pushed a commit
to woocommerce/woocommerce-ios
that referenced
this pull request
Feb 5, 2025
The SPM-compatible folder structure was giving me trouble when trying to
validate the `podspec`.
At first, I thought it was simply because
`WordPressComRESTAPIInterfacing.h` was not in a path known to CocoaPods.
But even after updating the `podspec` to:
```diff
@@ -18,9 +18,10 @@ Pod::Spec.new do |s|
s.swift_version = '5.0'
s.source = { git: 'https://github.com/wordpress-mobile/WordPressKit-iOS.git', tag: s.version.to_s }
- s.source_files = 'WordPressKit/**/*.{h,m,swift}'
+
+ s.source_files = 'WordPressKit/**/*.{h,m,swift}', 'Sources/**/*.{h,m,swift}'
+ s.public_header_files = 'Sources/**/include/*.h', 'WordPressKit/**/.h', 'WordPressKit/WordPressKit.h'
s.private_header_files = 'WordPressKit/Private/*.h'
- s.header_dir = 'WordPressKit'
s.dependency 'NSObject-SafeExpectations', '~> 0.0.4'
s.dependency 'wpxmlrpc', '~> 0.10'
```
I still got errors:
```
- ERROR | xcodebuild: /var/folders/dq/cdqxvx3s5ps75564rpmb_dc00000gn/T/CocoaPods-Lint-20240321-63072-nntpgw-WordPressKit/DerivedData/App/Build/Products/Release-iphonesimulator/WordPressKit/WordPressKit.framework/Headers/WordPressKit.h:10:9: error: 'WordPressKit/ServiceRemoteWordPressComREST.h' file not found
```
In the proof of concept from
wordpress-mobile/WordPressKit-iOS#738, the SPM
folder structure is compatible with CocoaPods. As such, I decided to
defer moving the files to when I can do it in one go.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.