lkml.org 
[lkml]   [1997]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Making module versions (Was: OFFTOPIC: binary modules, bad idea!)
From
Date
Martin von Loewis <martin@mira.isdn.cs.tu-berlin.de> writes:
> One-liners don't answer anything. If I just keep the .tmp around,
> make will still remake foo.ver, because it is still older than foo.c
>
> Linux-Kernel Mail Account wrote:
> > Use a cp-if-changed then, keep the .tmp around to prevent that...
> >
> > On Sat, 20 Dec 1997, Martin von Loewis wrote:
> >
> > > > I'm not sure if I'm reading this right but, would a mv_if_changed not do
> > > > the job? Ignoring the date and running a diff on the file...
> > >
> > > Exactly. If you have a rule saying
> > >
> > > foo.ver: foo.c
> > > produce foo.ver.tmp
> > > mv-if-changed foo.ver.tmp foo.ver
> > >
> > > then you are in trouble if foo.c is newer than foo.ver, but foo.ver
> > > is not updated. It will produce foo.ver.tmp every time you invoke make.

I guess he meant:

- make foo.ver.tmp depend on foo.c
- use cp-if-changed to get foo.ver
- things that depend on foo.ver still depend on it

To pull this off, foo.ver.tmp and foo.ver may have to be handled by
different make invocations.

- Hari
--
Raja R Harinath ------------------------------ harinath@cs.umn.edu
"When all else fails, read the instructions." -- Cahn's Axiom
"Our policy is, when in doubt, do the right thing." -- Roy L Ash

\
 
 \ /
  Last update: 2005-03-22 13:40    [W:0.029 / U:1.916 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site