how to add dynamic library?

Andreas Pakulat apaku at gmx.de
Tue Mar 8 16:53:37 GMT 2005


On 08.Mär 2005 - 21:04:40, Muhammad Rizwan Khan wrote:
> Hello.
> 
> I guess this question is not directly related to kdevelop. I am asking this question here, bczuse i am sure that there are lot of C++ gurs, who can solve this problem easily.
> I have created .so from kdevelop project (libuser.so) and copied this .so file in /usr/lib/. Now when i tried to include the header of this .so (i.e. user.h) in some other project created in kdevelop, the new project dont recognizes this "#include "user.h"".

user.h needs to be in the source folder of the new project for this to
work. Get a C++ book and lookup the difference between 

#include "header.h" and
#include <header.h>

You probably want to copy the needed header files to use the lib to
/usr/local/include. Also I'd suggest not copying any libs to /usr/lib,
those directories are reserved for the distribution tools so
installing an app via distro-tools might overwrite your lib. You
better copy the lib into /usr/local/lib. 

> Although i have executed the ldconfig as well. Any idea what is missing here.
> Another thing is that, is it possible to call one .so from some other .so....

You're not "calling" the lib, your linking the 2nd lib against the
first one. I guess you'd like to ask google for unix shared library
tutorials and libtool... kdevelop has support for all this (AFAIK).

Andreas

-- 
Avoid reality at all costs.

-
to unsubscribe from this list send an email to kdevelop-request at kdevelop.org with the following body:
unsubscribe »your-email-address«



More information about the KDevelop mailing list