meta_oodate even when missing-meta is true, we do not make a target in
.CURDIR out of date just because of a missing meta file. Also we can only be missing filemon data if we had a meta file.
This commit is contained in:
parent
3221c3ec32
commit
ec729b232b
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: meta.c,v 1.59 2016/06/03 01:21:59 sjg Exp $ */
|
||||
/* $NetBSD: meta.c,v 1.60 2016/06/04 22:17:14 sjg Exp $ */
|
||||
|
||||
/*
|
||||
* Implement 'meta' mode.
|
||||
|
@ -1451,18 +1451,27 @@ meta_oodate(GNode *gn, Boolean oodate)
|
|||
fname, (char *)Lst_Datum(Lst_First(missingFiles)));
|
||||
oodate = TRUE;
|
||||
}
|
||||
if (!oodate && !have_filemon && filemonMissing) {
|
||||
if (DEBUG(META))
|
||||
fprintf(debug_file, "%s: missing filemon data\n", fname);
|
||||
oodate = TRUE;
|
||||
}
|
||||
} else {
|
||||
if (writeMeta && metaMissing) {
|
||||
cp = NULL;
|
||||
|
||||
/* if target is in .CURDIR we do not need a meta file */
|
||||
if (gn->path && (cp = strrchr(gn->path, '/')) && cp > gn->path) {
|
||||
if (strncmp(curdir, gn->path, (cp - gn->path)) != 0) {
|
||||
cp = NULL; /* not in .CURDIR */
|
||||
}
|
||||
}
|
||||
if (!cp) {
|
||||
if (DEBUG(META))
|
||||
fprintf(debug_file, "%s: required but missing\n", fname);
|
||||
oodate = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
if (!oodate && !have_filemon && filemonMissing) {
|
||||
if (DEBUG(META))
|
||||
fprintf(debug_file, "%s: missing filemon data\n", fname);
|
||||
oodate = TRUE;
|
||||
}
|
||||
|
||||
Lst_Destroy(missingFiles, (FreeProc *)free);
|
||||
|
|
Loading…
Reference in New Issue