X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=libiberty%2Fmaint-tool;h=f100dd4a0d7bb05c8553cb50cc001d9ffed73ec1;hb=202e762b322444344827acbf98162fcb2910e0dd;hp=a460b5570e5c42e9c3c5b69bd23881453cc373a5;hpb=a590e8e71dc8bfbf1dd27fff13d3440c3bf4b27f;p=deliverable%2Fbinutils-gdb.git diff --git a/libiberty/maint-tool b/libiberty/maint-tool index a460b5570e..f100dd4a0d 100644 --- a/libiberty/maint-tool +++ b/libiberty/maint-tool @@ -1,8 +1,7 @@ #!/usr/bin/perl # -*- perl -*- -# Copyright (C) 2001, 2007 -# Free Software Foundation +# Copyright (C) 2001-2019 Free Software Foundation, Inc. # # This file is part of the libiberty library. # Libiberty is free software; you can redistribute it and/or @@ -76,7 +75,7 @@ sub missing { for $f (sort keys %listed) { if ($f =~ /(.*)\.c$/) { $base = $1; - if (! $listed{"$base.o"}) { + if (! $listed{"./$base.o"}) { print "O $f\n"; } } @@ -215,6 +214,9 @@ sub deps { $crule = "\tif [ x\"\$(PICFLAG)\" != x ]; then \\\n"; $crule .= "\t \$(COMPILE.c) \$(PICFLAG) \$< -o pic/\$@; \\\n"; $crule .= "\telse true; fi\n"; + $crule .= "\tif [ x\"\$(NOASANFLAG)\" != x ]; then \\\n"; + $crule .= "\t \$(COMPILE.c) \$(PICFLAG) \$(NOASANFLAG) \$< -o noasan/\$@; \\\n"; + $crule .= "\telse true; fi\n"; $crule .= "\t\$(COMPILE.c) \$< \$(OUTPUT_OPTION)\n"; $crule .= "\n"; @@ -222,10 +224,11 @@ sub deps { opendir(INC, $incdir); while ($f = readdir INC) { - next unless $f =~ /\.h$/; + next unless $f =~ /\.h$/ || $f =~ /\.def$/; $mine{$f} = "\$(INCDIR)/$f"; $deps{$f} = join(' ', &deps_for("$incdir/$f")); } + $mine{'config.h'} = "config.h"; opendir(INC, $srcdir); while ($f = readdir INC) { @@ -233,8 +236,7 @@ sub deps { $mine{$f} = "\$(srcdir)/$f"; $deps{$f} = join(' ', &deps_for("$srcdir/$f")); } - - $mine{'config.h'} = "stamp-h"; + $mine{'config.h'} = "config.h"; open(IN, "$srcdir/Makefile.in"); open(OUT, ">$srcdir/Makefile.tmp"); @@ -264,7 +266,7 @@ sub deps { } @deps = sort { &locals_first($a,$b) } keys %scanned; $obj = $f; - $obj =~ s/\.c$/.o/; + $obj =~ s/\.c$/.\$(objext)/; $obj = "./$obj:"; if ($#deps >= 0) { print OUT "$obj \$(srcdir)/$f";