Answer the question
In order to leave comments, you need to log in
How to connect a library for assembly in Xcode?
There is XCode.
And suppose two projects - the ABC application and the libABC library.
How to force XCode to link ABC with libABC?
Answer the question
In order to leave comments, you need to log in
In order to work properly with an external library, XCode needs the library file itself (the one that is .a) and the header file (.h) with the signatures of the functions you are going to call.
Add both files to the project, add the library file to Build Phases - Link binary with libraries, import the .h file where you call the functions from this library (#import "xxxxxx.h")
and it would be nice to chat with someone in Jabber/GTalk about the basics of working with XCode
there is not the library that I created in XCode (without installing)
recreated project abc - cl.ly/BRgs
main.cpp
#include void abc();
int main (int argc, const char * argv[])
{
abc();
// insert code here...
std::cout << "Hello, World!\n";
return 0;
}
libabc.c
#include <stdio.h>
#include <string.h>
void abc() {
printf("pizdec\n");
}
при сборке ошибка cl.ly/BRjr
if you just attach libabc.a, then there will be no error about an unknown type, but undefined symbols will remain
Those. won't it automatically build the project-library when building a project that depends on it?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question