Need to see if your shared folder is taking up space on your dropbox 👨‍💻? Find out how to check here.

Forum Discussion

Mr_K's avatar
Mr_K
Explorer | Level 3
9 years ago
Solved

Problems when migrating from API v1 to v2

When migrating my Objective C project for iOS from Dropbox API v1 to v2

I am changing my source code, replacing old

 

#import <DropboxSDK/DropboxSDK.h>

to new

#import <ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.h>

 

But when compiling the project I get an error:

 

'ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.h' file not found

 

Also in "Pods > Products" section in Xcode both "ObjectiveDropboxOfficial.framework" and "Pods_BASIC.framework" frameworks are marked in red color.

 

 

What settings are missing or what I am doing wrong?

 

  • Then I would recommend using Carthage, rather than CocoaPods, as it is less invasive. You can build the binaries with Carthage and then drage and drop them into each of your targets.

     

    This approach will work better, I think.

26 Replies

Replies have been turned off for this discussion
  • Stephen C.14's avatar
    Stephen C.14
    Icon for Dropbox Staff rankDropbox Staff
    9 years ago

    Strange. So am I. When I run `pod install` on the project you uploaded, and open the `xcworkspace` file, and build, it builds successfully.

     

    What's your output for `pod --version`?

     

    Mine is:

     

    ```

    scobbe-mbp:server scobbe$ pod --version
    1.2.0.beta.1

    ```

  • Mr_K's avatar
    Mr_K
    Explorer | Level 3
    9 years ago

    My pod version is 1.2.1

     

    It seems that 

    #import <ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.h>

    now raises no error, but when I compile that test project I get this error:

     

    Error: unable to read module map contents from 'Target Support Files/ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.modulemap': Error Domain=NSCocoaErrorDomain Code=260 "The file “ObjectiveDropboxOfficial.modulemap” couldn’t be opened because there is no such file." UserInfo={NSFilePath=/Users/kibernetik/Downloads/BASICcopy/Pods/Target Support Files/ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.modulemap, NSUnderlyingError=0x7fa1f005d630 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}}

     

     

  • Mr_K's avatar
    Mr_K
    Explorer | Level 3
    9 years ago

    No, this procedure and all other suggestions in that topic did not make missing file

     

    /Pods/Target Support Files/ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.modulemap

     

    to appear. Making "pod install" command also does not create it.

     

    Again I have "file not found" error concerning

    #import <ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.h>

     

     

  • Stephen C.14's avatar
    Stephen C.14
    Icon for Dropbox Staff rankDropbox Staff
    9 years ago

    Then I would recommend using Carthage, rather than CocoaPods, as it is less invasive. You can build the binaries with Carthage and then drage and drop them into each of your targets.

     

    This approach will work better, I think.

  • Mr_K's avatar
    Mr_K
    Explorer | Level 3
    9 years ago

    Thank you for your suggestion!

    I will try.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.

The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!