checksum files not ^C safe

Geoffrey Keating geoffk@apple.com
Thu Sep 15 06:55:00 GMT 2005


On 14/09/2005, at 5:32 PM, Mike Stump wrote:

> These types of rules are not ^C safe:
>
> cc1-checksum.c : cc1-dummy$(exeext) build/genchecksum$(build_exeext)
>         build/genchecksum$(build_exeext) cc1-dummy$(exeext) > $@
>
> It is a general property that builds are ^C safe, the above changes  
> retard that feature.
>
> If you output to a temp file, and then mv them to the final file,  
> they will be (I think) safe.

 From the 'make' documentation, node 'Interrupts':

>    If `make' gets a fatal signal while a command is executing, it may
> delete the target file that the command was supposed to update.   
> This is
> done if the target file's last-modification time has changed since
> `make' first checked it.

So, I think this is safe.  The file will be deleted and then re-built  
next time you run 'make'.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2408 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20050915/60b6aea5/attachment.p7s>


More information about the Gcc mailing list