Re: Making module versions (Was: OFFTOPIC: binary modules, bad idea!)

Linux-Kernel Mail Account (kernel@whitestar.soark.net)
Sat, 20 Dec 1997 08:55:26 -0500 (EST)


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.
>
> Regards,
> Martin
>