Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tools/host-mkdep Like the non-host mkdep don't print ./foo.h...



details:   https://anonhg.NetBSD.org/src/rev/dea51473ba07
branches:  trunk
changeset: 338138:dea51473ba07
user:      christos <christos%NetBSD.org@localhost>
date:      Tue May 12 00:04:34 2015 +0000

description:
Like the non-host mkdep don't print ./foo.h as a dependency, but simplify
it to foo.h. This was causing problems with:

.y.h: ${.TARGET:.h=.c}

where .h was ./cgram.h and the source became ./cgram.c confusing for example
/usr/src/tools/lint1 because make had both cgram.c and ./cgram.c in the list
of sources, trying to build both of them in parallel thinking that they were
different files. Since the regular mkdep does not produce such dependencies,
the regular build does not suffer from this issue.

diffstat:

 tools/host-mkdep/host-mkdep.in |  3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diffs (19 lines):

diff -r 5871d78d57d8 -r dea51473ba07 tools/host-mkdep/host-mkdep.in
--- a/tools/host-mkdep/host-mkdep.in    Tue May 12 00:00:35 2015 +0000
+++ b/tools/host-mkdep/host-mkdep.in    Tue May 12 00:04:34 2015 +0000
@@ -1,6 +1,6 @@
 #!@BSHELL@ -
 #
-#      $NetBSD: host-mkdep.in,v 1.30 2013/09/02 08:37:11 joerg Exp $
+#      $NetBSD: host-mkdep.in,v 1.31 2015/05/12 00:04:34 christos Exp $
 #
 # Copyright (c) 1991, 1993
 #      The Regents of the University of California.  All rights reserved.
@@ -243,6 +243,7 @@
                                sub(/^#(pragma).*/, "")
                                sub(/^<.*/, "")
                                sub(/\".*$/, "")
+                               sub(/^\.\//, "")
                                sub(/ [ 0-9]*$/, "")
 
                                if ($0 in seenfiles) next



Home | Main Index | Thread Index | Old Index