Closed odrobnik closed 11 years ago
How do I specify the linking of CoreData.framework for DTDownloadCache?
I think that the best solution would be to namespace DTDownloadChache
and DTBonjour
in the file system as well.
FYI you can check the validity of a podspec running:
$ pod spec lint DTFoundation.podspec --verbose
// this requires to temporarily remove the branch information from the source.
You can also inspect what CocoaPods sees by running:
$ pod spec lint DTFoundation.podspec --no-clean
$ open /tmp/CocoaPods/Lint/Pods/Pods.xcodeproj
i tried the lint thing, but it fails on my MacBook, something about include being unknown...
I know, I still need to split out DTDownloadCache which uses DoreData and a few other things
Also of course I still need to tag version 1.0.0, but I want to do that once the podspec is complete.
i tried the lint thing, but it fails on my MacBook, something about include being unknown...
spec.version.to_s
should have fixed it.
Awesome looks like we are getting closer to complete the podspec.
I also added a 1.0.0 tag. the podspec repo is having issues right now, so I cannot verify it.
I seem to have this problem when lint-ing the pod spec:
-> DTFoundation (1.0.0)
This file is part of the Core sub spec, why can pod not find the file?
@Cocoanetics When you run lint with the --no-clean
option and then inspect the Xcode project, like @irrationalfab suggested, can you see what the problem is?
I see that the NSString+DTPaths is indeed missing. Looks like this is wrong:
spec.subspec 'Core' do |ss|
ss.source_files = 'Core/Source/*.{h,m}'
ss.ios.source_files = 'Core/Source/iOS/*.{h,m}'
ss.osx.source_files = 'Core/Source/OSX/*.{h,m}'
end
How can I configure it correctly to have platform-dependent code in the iOS/OSX folders and platform-independent code in Core/Source
The non-cleaned Pods.xcodeproj only has the iOS source, all the ss.source_files are missing.
Try:
spec.subspec 'Core' do |ss|
ss.ios.source_files = 'Core/Source/*.{h,m}', 'Core/Source/iOS/*.{h,m}'
ss.osx.source_files = 'Core/Source/*.{h,m}', 'Core/Source/OSX/*.{h,m}'
end
Yes, that did the trick. After cleaning up a few other things I get a successful lint.
Now I have both DTFoundation and DTCoreText working, BUT I believe there to be a bug in CocoaPods: there are problems having dependencies on sub-specs from a larger project if these subspecs require a higher deployment target. I raised this issue: https://github.com/CocoaPods/CocoaPods/issues/745
Btw, this is a bug in CocoaPods which should be fixed in 0.17.
the previous comment refers to the source files issue
I am trying to further separate the things that need UIKIt and AppKit. These show up in pod search, but they don't get installed by pod install, even if I reference DTFoundation/UIKit. Why?
https://github.com/Cocoanetics/DTFoundation/blob/master/DTFoundation.podspec
I think I got it working now. Somehow pod was not updating an existing project as it should.
Where you running pod install
or pod update
?
I was trying both. Neither seemed to add the new UIKit subspec to the Pods project.
Oh, I see, you didn't change the version. This is an unimplemented feature. CocoaPods does't install all the Pods every-time but just the ones that changed. In the future we should check for the SHA1 of the podspec to see if an already installed version needs to be reinstalled. However for the time being the work around for this situations is to delete the folder of the Pod.
We need the spec file for DTFoundation so that it can be a dependency of DTCoreText. Also the elements that have their own static lib targets should be their own sub specs.