Unix Programming - makedepend question

This is Interesting: Free IT Magazines  
Home > Archive > Unix Programming > October 2006 > makedepend question





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author makedepend question
jithu

2006-10-17, 7:39 am

Hi
I am posting it here since, after searching in google for
Makefiles, i got lot of reference material on Makefile. But very few of
them specified on creating Makefiles for any directory structure. I
mean i got very few references for things like seperating object files
from sources files . The only useful thing i got was
http://make.paulandlesley.org/multi-arch.html which is too complex for
a newbie like me.So if you have some good material on makefile for
directory structures please post them as reply. Now if you have time
please answer my question.

I have 2 directories named "cppsrc" and "public" inside another
direcory PRJ_DIR. All the cpp source files are present inside the
"cppsrc" and all the header files are present in "public". My
"Makefile" is present in PRJ_DIR. I use "makedepend" in my makefile as
below.

SRC_FILE = cppsrc/main.cpp cppsrc/test.cpp
makedepend -f- -I public $(SRC_FILE) > .depend

But this create the the dependancy list as below
cppsrc/main.o: public/test.h
cppsrc/test.o: public/test.h

What i need is a list like
main.o: public/test.h
test.o: public/test.h.

How to create this list.Remeber my Makefile is in PRJ_DIR and
makedepend is invoked from it.

Thanks in Advance
Kiran.

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com