Xcode cannot import tapku or kal library

前端 未结 2 1140
名媛妹妹
名媛妹妹 2021-01-07 00:05

I am having trouble importing the tapku library (to use the calendar api it provides). I\'ve also tried Kal with the same problem. Here\'s what I do to import it (please tel

2条回答
  •  醉梦人生
    2021-01-07 00:46

    Using the same numbers for the steps you listed:

    1) Correct - do not copy the project.

    2) I don't normally have to do this for included libraries but perhaps you need this for this framework (I assume you've been told to do this)

    3) The header search path has to be the same string you would use from the shell to get from the directory your project is in to the top level folder (directory) of the think you want to find. In your case, it is a folder TapkuLibrary. Your path can be relative to the directory the project is in:

    ./../../../Foo/Goop/TapkuLibrary
    

    or it can be an absolute path:

    /Users/jfk/Desktop/TapuLibrary
    

    So figure out the string you think is correct, then open Terminal, cd to the directory where your project file is, then type "ls " and see if it lists the contents of the directory. If not, then figure out what you did wrong.

    Its probably a good idea to set the "recursive" flag - if you double click on Header Search Paths, you can select the box on the left (or you can type in a "/**" postfix to the path).

    4) Do not use:

    #import 
    

    That is telling Xcode that this is a System folder (in /usr/include), etc. In the manner you are using this it should be a user folder:

    #import "TapkuLibrary/TapkuLibrary.h"
    

提交回复
热议问题