card.io-iOS-SDK icon indicating copy to clipboard operation
card.io-iOS-SDK copied to clipboard

Overwriting Search Path

Open FeeB opened this issue 10 years ago • 18 comments

When I'm trying to integrate CardIO with CocoaPods I get the error that it is overwriting the searchPath. When I'm than use the $(inherited) flag manually I can't import CardIO because the compiler says No such module.

Any suggestion how I can integrate CardIO?

FeeB avatar Aug 25 '15 17:08 FeeB

@FeeB our other CocoaPods users have not reported this searchPath error. Could you please copy/paste the full error message(s) here?

Note that if nothing works for you with CocoaPods, you can always integrate card.io manually as described in detail here.

dgoldman-pdx avatar Aug 25 '15 22:08 dgoldman-pdx

@dgoldman-ebay My Error State is this one:

[!] The `XXX [Release]` target overrides the `LIBRARY_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-XXX/Pods-XXX.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

After I integrate the $(inherited) flag it is still not able to find the header files.

But I think it is because of this issue: https://github.com/card-io/card.io-iOS-SDK/issues/115 Are you planning to solve this problem? Or will you wait until Cocoapods has fixed it?

Thanks a lot!

FeeB avatar Aug 26 '15 14:08 FeeB

Thanks for the additional information, @FeeB.

Yes, it sounds like we still need to resolve our CocoaPods-related issues. Unfortunately, I'm not sufficiently expert with CocoaPods to be helpful here.

@burnto do you have any time to take a look at this, #115, and https://github.com/card-io/card.io-iOS-SDK/pull/126?

dgoldman-pdx avatar Aug 26 '15 16:08 dgoldman-pdx

And if you don't have time, @burnto, it seems like we should just merge that PR and let the cocoa pods community send further cleanup as needed.

josharian avatar Aug 26 '15 17:08 josharian

I reviewed, tested, and merged #126

burnto avatar Aug 26 '15 18:08 burnto

Thanks, @burnto!

dgoldman-pdx avatar Aug 26 '15 19:08 dgoldman-pdx

@FeeB I've pushed the new podspec to CocoaPods trunk (as part of updating card.io to version 5.1.1). Try updating and let us know what happens!

dgoldman-pdx avatar Aug 26 '15 19:08 dgoldman-pdx

Oh, I see that you already pushed #126 to the podspec, so there would be no need to grab that commit file specifically, but I'm still getting the error: No such module 'CardIO'

any ideas?

jlubeck avatar Aug 28 '15 18:08 jlubeck

@jlubeck wild guess here, but any chance you're on an older version of CocoaPods? If so, try updating, cleaning, deleting derived data, killing xcode, and doing a pod install

You know, all the standard incantations.

burnto avatar Aug 28 '15 18:08 burnto

I had cocoapods 0.38.0. I updated to 0.38.2. Cleaned project, deleted derived data, killed xcode, restarted the computer, did pod install

Still getting No such module 'CardIO' :(

jlubeck avatar Aug 28 '15 19:08 jlubeck

This error seems to be generally associated with using frameworks. What does your Framework Search Paths value look like (in both your project and your target)?

burnto avatar Aug 28 '15 21:08 burnto

Project: http://prntscr.com/8a18ch

Target looks exactly the same...

How should it look like? All the other libraries I'm using work fine for what it's worth...

jlubeck avatar Aug 28 '15 21:08 jlubeck

@jlubeck OK I'm out out ideas for now, but I did verify that a vanilla project using CocoaPods can use card.io without the error you're seeing.

Here is the project I created (Xcode 6.4), which may be useful as a reference for you.

https://github.com/burnto/simple-card-io-use-frameworks-example

burnto avatar Aug 28 '15 22:08 burnto

Thanks @burnto I'm going to check it out and come back with any results...

jlubeck avatar Aug 28 '15 22:08 jlubeck

Hey @burnto I just saw the project you created, but that is an Objective-C project, not a Swift one.

I tried making a a brand new Swift project and still getting the same problem. Here is my project: https://github.com/jlubeck/CardIO-SwiftTest

But then again, maybe I'm on the wrong issue thread?

jlubeck avatar Sep 01 '15 15:09 jlubeck

Yeah, I'm definitely on the wrong issue. Issue was #115 and/or #126 which were supposed to be fixed by the pull request of #126, but it's still not working. At least not for me on that project I linked before. Sorry about messing with this issue. Do you want me to delete my comments here?

jlubeck avatar Sep 01 '15 15:09 jlubeck

@FeeB and I fixed this issue by removing this redundant part of our .xcodeproj file:

FRAMEWORK_SEARCH_PATHS = (
                    "$(inherited)",
                    "$(PROJECT_DIR)",
                    "$(PROJECT_DIR)/Frameworks",
                );

arielelkin avatar Sep 11 '15 15:09 arielelkin

I'm currently experiencing this with Cocoapods version 0.39 and the latest CardIO SDK release in a Swift project. I know very little about how Cocoapods works underneath the hood so it's hard for me to debug, but I'm sure it has something to do with my podfile: https://gist.github.com/mitchellporter/1a9db4fd256e34089d64

I can't explain all of the customizations to my podfile, but this is the "perfect" podfile setup right now for getting 99% of Pods to install properly when building Swift projects.

I would really prefer to install CardIO via Cocoapods instead of managing it manually, so hopefully someone has already figured this out.

Thanks.

mitchellporter avatar Nov 29 '15 21:11 mitchellporter