2002-07-09 Tom Tromey <tromey@redhat.com>
+ * lib/am/depend2.am: Reworked syntax to avoid parsing problem.
+
* lib/am/depend2.am: Search in srcdir and builddir for %SOURCE%
before passing to cygpath. Partial fix for PR automake/334.
?!GENERIC?%OBJOBJ%: %SOURCE%
if %FASTDEP%
## In fast-dep mode, we can always use -o.
- file="`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%"; \
if %COMPILE% -MT %OBJOBJ% -MD -MP -MF "%DEPBASE%.Tpo" \
- %-c% -o %OBJOBJ% `cygpath -w "$$file"`; \
+## Ugly invocation here; using a variable fails due to a parsing
+## problem in automake.
+ %-c% -o %OBJOBJ% `if test -f '%SOURCE%'; then cygpath -w '%SOURCE%'; else cygpath -w '$(srcdir)/%SOURCE%'`; \
then mv "%DEPBASE%.Tpo" "%DEPBASE%.Po"; \
else rm -f "%DEPBASE%.Tpo"; exit 1; \
fi
else !%FASTDEP%
- file="`test -f '%SOURCE%' || echo '$(srcdir)/'`%SOURCE%"; \
if %AMDEP%
source='%SOURCE%' object='%OBJOBJ%' libtool=no @AMDEPBACKSLASH@
depfile='%DEPBASE%.Po' tmpdepfile='%DEPBASE%.TPo' @AMDEPBACKSLASH@
$(%FPFX%DEPMODE) $(depcomp) @AMDEPBACKSLASH@
endif %AMDEP%
-?-o? %COMPILE% %-c% %-o% %OBJOBJ% `cygpath -w "$$file"`
-?!-o? %COMPILE% %-c% `cygpath -w "$$file"`
+?-o? %COMPILE% %-c% %-o% %OBJOBJ% `if test -f '%SOURCE%'; then cygpath -w '%SOURCE%'; else cygpath -w '$(srcdir)/%SOURCE%'`
+?!-o? %COMPILE% %-c% `if test -f '%SOURCE%'; then cygpath -w '%SOURCE%'; else cygpath -w '$(srcdir)/%SOURCE%'`
endif !%FASTDEP%
if %?LIBTOOL%