我們在葫蘆目標中集成CocoaPods時遇到了一些問題。無法將豆莢鏈接到葫蘆目標
目前,我們有4個目標:
應用:正常應用目標
AppTests:單元測試目標
的App-葫蘆:蠡目標
應用程序的API存根:特殊目標
我們希望分享App,App-Calabash和App之間的所有Pod -API存根。 另外,AppTests和App-Calabash必須包含其他庫。
這是我們的Podfile:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '7.0'
link_with 'App', 'App-Calabash', 'App-API-Stubs'
inhibit_all_warnings!
pod 'MagicalRecord', '~> 2.2'
pod 'AFNetworking', '~> 2.3.1'
pod 'ObjectiveSugar', '~> 1.1.0'
pod 'KZPropertyMapper', '~> 2.5.0'
pod 'FXBlurView', '~> 1.6.2'
pod 'OHHTTPStubs', '~> 3.1.5'
pod 'Google-Maps-iOS-SDK', '~> 1.8.1'
pod 'KVOController', '~> 1.0.1'
pod 'Braintree', '~> 3.3.1'
pod 'TTTAttributedLabel', '~> 1.10.1'
pod 'ObjectiveLuhn', '~> 1.0.0'
pod 'CrashlyticsFramework', '~> 2.2.1'
target 'App-Calabash', :exclusive => true do
pod 'Calabash', '~> 0.9.169'
end
target 'AppTests', :exclusive => true do
pod 'Specta', '~> 0.2.1'
pod 'Expecta', '~> 0.3.0'
pod 'OCMock', '~> 3.1.1'
end
所有目標構建和運行得很好,但在葫蘆之一。
它抱怨它無法找到Crashlytics/Crashlytics.h
。但是,即使我們暫時避免使用Crashlytics,它則抱怨在鏈接過程中的葫蘆庫:
ld: warning: directory not found for option '-L/Users/Marco/ios/App/Pods/build/Debug-iphoneos'
ld: file not found: -lPods-App-Calabash-Calabash
clang: error: linker command failed with exit code 1 (use -v to see invocation)
所以它似乎什麼都沒了可怕的錯誤莢整合到特定的目標。
我很確定我錯過了一些簡單的東西,但我無法弄清楚。
任何幫助真的很感激。謝謝!
如果您發現解決方案只是回來,我有一些相關的問題 – AsTeR 2014-10-30 16:58:18
我個人的問題是與我沒有注意到以下消息,'[!]從現在開始使用'的經驗。 xcworkspace',它只在第一個「pod安裝」後出現。 – AsTeR 2014-10-30 17:06:32