ninjatool: use constant names for stamp files
commit8d60f377409bf3570bad4cc27a7fc6b2ca5818f0
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 1 Sep 2020 11:13:16 +0000 (1 07:13 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 8 Sep 2020 05:17:09 +0000 (8 07:17 +0200)
tree7e21aff2ba40da5c895ea5c51dd1e7ab460955ff
parente817851479f80622c70566740ac3cf020eb99f27
ninjatool: use constant names for stamp files

Numbering files according to rules causes confusion, because
CUSTOM_COMMAND3.stamp from a previous build might represent
completely different targets after Makefile.ninja is regenerated.
As a result, the new targets are not rebuilt and compilation
fails.

Use the targets to build a SHA1 hash; the chances for collision
are one in 2^24 even with a 12-character prefix of the hash.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
scripts/ninjatool.py