[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference smurf::buildhelp

Title:USG buildhelp questions/answers
Moderator:SMURF::FILTER
Created:Mon Apr 26 1993
Last Modified:Mon Jan 20 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2763
Total number of notes:5802

1786.0. "is there a better way to..." by AOSG::FILTER (Automatic Posting Software - mail to flume::puck) Thu Aug 31 1995 16:49

Date Of Receipt: 	31-AUG-1995 15:43:50.67
From: 	SMURF::ALPHA::frank "Douglas Frank USG  31-Aug-1995 1542"
To: 	odehelp@DEC:.zko.alpha
CC: 	
Subj: 	is there a better way to...

Hi,

To make a short story boring, I needed a function that did >*foo*<, and
it turned out that I didn't need to write it from scratch; someone else
had faced the same need a while back, so all I had to do was clone their
source file into my own little empire.

Now that I have the time, I'd like to get rid of the clone and use the
original source-- no sense having duplicate files around, right?  I made
a sym link to the original, and it seems to work, but I was wondering if
there's some more elegant way to do this via the Makefile.

OFILES = mystuff.o foo.o  <-- this works when foo.c is a sym link to
../../../blah/foo.c

OFILES = mystuff.o ../../../blah/foo.o  <-- this compiles the .o's but
puts foo.o in the current directory, not in ../../../blah, so it breaks
'ar'.  Is there a way to make this work?

thanks

--Doug

T.RTitleUserPersonal
Name
DateLines
1786.1Re: is there a better way to...AOSG::FILTERAutomatic Posting Software - mail to flume::puckThu Aug 31 1995 17:5911
Date Of Receipt: 	31-AUG-1995 16:09:25.85
From: 	SMURF::FLUME::jmcg "Jim McGinness"
To: 	frank@DEC:.zko.flume
CC: 	buildhelp@DEC:.zko.flume
Subj: 	Re:  is there a better way to...

It sounds like you just need a VPATH directive so files in ../../../blah
can be referred to with simple names.

S -- jmcg

1786.2Re: is there a better way to...AOSG::FILTERAutomatic Posting Software - mail to flume::puckThu Aug 31 1995 19:0527
Date Of Receipt: 	31-AUG-1995 17:15:13.17
From: 	SMURF::FLUME::jmcg "Jim McGinness"
To: 	frank@DEC:.zko.flume
CC: 	buildhelp@DEC:.zko.flume
Subj: 	Re: is there a better way to...

That particular question is answered on the make(1) manpage if you know
where to look.  I think there's also an example in template.mk.  The
buildhelp alias gets a wide range of questions and they're all logged
to the AOSG::BUILDHELP notesfile.  I don't know how easy that is to
use or even if people still remember it's out there.  Most of the
time, it's fastest to just ask the list.

 -- jmcg

 >  To: Jim McGinness <jmcg>
 >  Subject: Re: is there a better way to...  
 >  Date: Thu, 31 Aug 95 16:38:31 -0400
 >  From: frank
 > 
 >     It sounds like you just need a VPATH directive so files in ../../../blah
 >     can be referred to with simple names.
 > 
 > Yup, that did the trick, thanks.  It there a reference somewhere
 > for questions like this?
 >