*BSD News Article 7977


Return to BSD News archive

Newsgroups: comp.unix.bsd
Path: sserve!manuel.anu.edu.au!munnari.oz.au!spool.mu.edu!darwin.sura.net!bogus.sura.net!pandora.pix.com!stripes
From: stripes@pix.com (Josh Osborne)
Subject: Re: [386bsd] RCS + make
Message-ID: <By2KuH.DB2@pix.com>
Keywords: huh?
Sender: news@pix.com (The News Subsystem)
Nntp-Posting-Host: pandora.pix.com
Organization: Pix Technologies -- The company with no adult supervision
References: <By07vE.Fwt@news.cso.uiuc.edu>
Date: Sat, 21 Nov 1992 14:13:28 GMT
Lines: 44

In article <By07vE.Fwt@news.cso.uiuc.edu> rkb55989@dcl-nxt50 (Rafal Krzysztof Boni) writes:
>	Now, my question is this: Is there any way to automate the checkout
>	process on build?? I really don't want to have to check out all of 
>	the kernel tree before I decide to build it....

Many versions of make support a .DEFAULT target which is called when a
dependcy can not be satisfyed.  If the BSD make has it try something like:

..DEFAULT:
	co -u $<

(I think that's the right $thing)

This will not remove the stuff afterward.  To do that run "rcsclean" when
tjhe make is done (I am not sure ghhow to automate thatwithout editing all the
makefiles...)

Some make's have a .BEFORE and .AFTER, the .BEFORE will be called even if
the file exists, so you need to do something more like

..BEFORE:
	yes n | co -u $<

The "yes n|" will answer no to the question "Do you want to overwrite
existing file foo" if foo exists.  You could have .AFTER do a limited
form of rcsclean.

If the BSD make doesn't have either then you have to get messy.  Do NOT
make a RCS directory (which you SHOULD if you don't need to do this, it reduces
clutter).  Then instruct RCS to use a .suffix (I am assuming .rcs) rather
then the current ,v ot %v suffix.  Add some dot rules like:

..rcs.c:
	co -u $<
..rcs.s:
	co -u $<
and so on...
[...]
-- 
           stripes@pix.com              "Security for Unix is like
      Josh_Osborne@Real_World,The          Multitasking for MS-DOS"
      "The dyslexic porgramer"                  - Kevin Lockwood
We all agree on the necessity of compromise.  We just can't agree on
when it's necessary to compromise.       - Larry Wall