setting up include path for muli-lib project

Andrew Skiba andrew_skiba at mail.ru
Wed Aug 21 13:44:09 BST 2002


Hello guys. 
 
--Brief question: 
What is the right way to specify the dependencies between subdirectories in 
projects, e.g. main needs lib1, lib2; lib1 needs lib2 ? This includes both 
linking and preprocessing stages. 
 
--Full question: 
I am an experienced VC++ developer trying to persuade the bosses to convert to 
linux. Porting my first project to KDevelop went pretty easy until I started to 
build components together. In VC++ the application had an executable and few 
dlls. In KDevelop I build the main with the first library - everything fine 
except that i had to change #include lines in the main program to have the 
subdirectory name, like #include "lib1/foo.h". 
Now I'm trying to add the second library, which uses the first one. I cannot 
change the include statements to take files from lib1 subdir, because the lib1 
headers include others from the same lib. I made a workaround - added 
 
INCLUDES = -I ../lib1 
 
to the end of Makefile.am in the lib2 subdir. This solved the include file 
problem, but the Makefile.am is not really a source file (it is altered by 
KDevelop and thus not stored in cvs by default). Is there a better place to 
specify include dirs for a subproject? 
 
Another issue is a shared libraries solution. If I want (and I do want) to 
build those libs as shared ones, how does the linker know what are the 
dependencies? In VC++ there was a Project|Dependencies dialog to specify them, 
is there a ready solution here? If not, what is a workaround? 
 
Appreciating any suggestions 
Best regards 
Andrew Skiba 


-
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