Hi! I’m trying to install RealmSwift on a watch application, but it seems I can’t get it to work. I’m following the standard tutorial:
I have created a new XCode project, selecting the Watch App template.
and have installed the SDK via cocoapods. I wasn’t sure for which target I should add the SDK, so I did it on all three, this is my Podfile:
# Uncomment the next line to define a global platform for your project
platform :ios, '12.0'
target 'watch_sync_test' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
pod 'RealmSwift', '~>10'
# Pods for watch_sync_test
end
target 'watch_sync_test WatchKit App' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
pod 'RealmSwift', '~>10'
# Pods for watch_sync_test WatchKit App
end
target 'watch_sync_test WatchKit Extension' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
pod 'RealmSwift', '~>10'
# Pods for watch_sync_test WatchKit Extension
end
Running pod install gives me a warning, but it doesn’t seem important:
[!] The `watch_sync_test WatchKit App [Debug]` target overrides the `ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES` build setting defined in `Pods/Target Support Files/Pods-watch_sync_test WatchKit App/Pods-watch_sync_test WatchKit App.debug.xcconfig'. This can lead to problems with the CocoaPods installation
- Use the `$(inherited)` flag, or
- Remove the build settings from the target.
However, opening the .xcworkspace file, when I try to import RealmSwift, I get
No such module 'RealmSwift'
Any idea of what I could be doing wrong?