CocoaPods dependency only on debug/release build
Asked Answered
B

3

39

I'm using a pod as an internal library for my project.

I want to have some pods included only on release/debug builds, like Reveal/Sparkinspector.

Is there any way to define podspec dependencies depending on the currently selected build configuration (build/release)?

Berner answered 26/10, 2013 at 18:48 Comment(0)
B
102

With the recent release it's officially available now: http://blog.cocoapods.org/CocoaPods-0.34/

Use

pod 'Lookback', :configurations => ['Debug']
Berner answered 27/9, 2014 at 13:8 Comment(1)
Unfortunately - it does not work for me at least for cocoapods v.1.11.2 - the executable contains symbols from cocoapod. checked by cmd: nm upd: I found task about my issue: github.com/CocoaPods/CocoaPods/issues/9658Kelsiekelso
B
0

For anyone just finding this, this looks to be scheduled in the next release, per my answer here:

https://mcmap.net/q/409213/-cocoapods-for-development-only

Bozeman answered 3/9, 2014 at 20:55 Comment(0)
A
-6

see the multiple targets section here: https://github.com/CocoaPods/CocoaPods/wiki/A-Podfile

e.g.

target :debug do
    pod 'TestFlight'
end
Abdomen answered 26/10, 2013 at 19:4 Comment(1)
That's not the same, the idea was to simply define different pods for release/debug configuration. As far as I am concerned it is possible in Xcode but Pods do not support build configurations yet.Panoply

© 2022 - 2024 — McMap. All rights reserved.