Commit 398b3deb by DJ Delorie Committed by DJ Delorie

Makefile.in: Convert to ./ throughout.

* Makefile.in: Convert to ./ throughout.  Rebuild dependencies
with explicit build rules.
(VPATH): Remove.
(.c.o): Poison.
* configure.ac (pexecute, LIBOBJS): Add ./ .
* maint-tool: Build dependencies with explicit rules.

From-SVN: r76366
parent 7bff636b
2004-01-22 DJ Delorie <dj@redhat.com>
* Makefile.in: Convert to ./ throughout. Rebuild dependencies
with explicit build rules.
(VPATH): Remove.
(.c.o): Poison.
* configure.ac (pexecute, LIBOBJS): Add ./ .
* maint-tool: Build dependencies with explicit rules.
2004-01-15 Kazu Hirata <kazu@cs.umass.edu> 2004-01-15 Kazu Hirata <kazu@cs.umass.edu>
* strdup.c (strdup): Constify the argument. * strdup.c (strdup): Constify the argument.
......
...@@ -477,11 +477,11 @@ fi ...@@ -477,11 +477,11 @@ fi
# Figure out which version of pexecute to use. # Figure out which version of pexecute to use.
case "${host}" in case "${host}" in
*-*-mingw* | *-*-winnt*) pexecute=pex-win32.o ;; *-*-mingw* | *-*-winnt*) pexecute=./pex-win32.o ;;
*-*-msdosdjgpp*) pexecute=pex-djgpp.o ;; *-*-msdosdjgpp*) pexecute=./pex-djgpp.o ;;
*-*-msdos*) pexecute=pex-msdos.o ;; *-*-msdos*) pexecute=./pex-msdos.o ;;
*-*-os2-emx*) pexecute=pex-os2.o ;; *-*-os2-emx*) pexecute=./pex-os2.o ;;
*) pexecute=pex-unix.o ;; *) pexecute=./pex-unix.o ;;
esac esac
AC_SUBST(pexecute) AC_SUBST(pexecute)
...@@ -496,6 +496,15 @@ else ...@@ -496,6 +496,15 @@ else
fi fi
AC_SUBST(INSTALL_DEST) AC_SUBST(INSTALL_DEST)
L=""
for l in x $LIBOBJS; do
case $l in
x) ;;
*) L="$L ./$l" ;;
esac
done
LIBOBJS="$L"
# We need multilib support, but only if configuring for the target. # We need multilib support, but only if configuring for the target.
AC_OUTPUT(Makefile testsuite/Makefile, AC_OUTPUT(Makefile testsuite/Makefile,
[test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h [test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
......
...@@ -35,6 +35,9 @@ extern int errno; ...@@ -35,6 +35,9 @@ extern int errno;
#if HAVE_SYS_STAT_H #if HAVE_SYS_STAT_H
#include <sys/stat.h> #include <sys/stat.h>
#endif #endif
#if HAVE_LIMITS_H
#include <limits.h>
#endif
/* Prototype these in case the system headers don't provide them. */ /* Prototype these in case the system headers don't provide them. */
extern char *getpwd (); extern char *getpwd ();
......
...@@ -213,6 +213,12 @@ sub locals_first { ...@@ -213,6 +213,12 @@ sub locals_first {
sub deps { sub deps {
$crule = "\tif [ x\"\$(PICFLAG)\" != x ]; then \\\n";
$crule .= "\t \$(COMPILE.c) \$(PICFLAG) \$< -o pic/\$@; \\\n";
$crule .= "\telse true; fi\n";
$crule .= "\t\$(COMPILE.c) \$< \$(OUTPUT_OPTION)\n";
$crule .= "\n";
$incdir = shift @ARGV; $incdir = shift @ARGV;
opendir(INC, $incdir); opendir(INC, $incdir);
...@@ -260,10 +266,10 @@ sub deps { ...@@ -260,10 +266,10 @@ sub deps {
@deps = sort { &locals_first($a,$b) } keys %scanned; @deps = sort { &locals_first($a,$b) } keys %scanned;
$obj = $f; $obj = $f;
$obj =~ s/\.c$/.o/; $obj =~ s/\.c$/.o/;
$obj = "$obj:"; $obj = "./$obj:";
if ($#deps >= 0) { if ($#deps >= 0) {
print OUT $obj; print OUT "$obj \$(srcdir)/$f";
$len = length($obj); $len = length("$obj $f");
for $dt (@deps) { for $dt (@deps) {
$d = $mine{$dt}; $d = $mine{$dt};
if ($len + length($d) > 70) { if ($len + length($d) > 70) {
...@@ -275,7 +281,12 @@ sub deps { ...@@ -275,7 +281,12 @@ sub deps {
} }
} }
print OUT "\n"; print OUT "\n";
} else {
print OUT "$obj \$(srcdir)/$f\n";
} }
$c = $crule;
$c =~ s@\$\<@\$\(srcdir\)\/$f@g;
print OUT $c;
} }
} }
closedir(S); closedir(S);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment