[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
CVS automake: depcomp/gcc3 doesn't propagate errors?
From: |
Raja R Harinath |
Subject: |
CVS automake: depcomp/gcc3 doesn't propagate errors? |
Date: |
09 Feb 2001 17:21:38 -0600 |
User-agent: |
Gnus/5.090001 (Oort Gnus v0.01) Emacs/21.0.97 |
Hi,
It appears that 'depcomp' doesn't propagate errors with the new 'gcc3'
style.
The code looks like:
case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay!
if "$@" -MT "$object" -MF "$depfile" -MD -MP; then
exit $?
fi
;;
[snip]
esac
exit 0
If the compiler succeeds (return 0), then exit $? i.e., exit 0.
Otherwise, fall off the case statement and exit 0. (Do tell me if I'm
missing something obvious).
Here's a possible fix. It seems the right thing to do even for the
detection code in depend.m4.
from Raja R Harinath <address@hidden>
* depcomp (gcc3): Propagate exit code.
Index: depcomp
===================================================================
RCS file: /cvs/automake/automake/depcomp,v
retrieving revision 1.16
diff -u -p -u -r1.16 depcomp
--- depcomp 2001/02/04 23:31:46 1.16
+++ depcomp 2001/02/09 23:18:42
@@ -51,9 +51,7 @@ case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay!
- if "$@" -MT "$object" -MF "$depfile" -MD -MP; then
- exit $?
- fi
+ exec "$@" -MT "$object" -MF "$depfile" -MD -MP
;;
gcc)
- Hari
--
Raja R Harinath ------------------------------ address@hidden
"When all else fails, read the instructions." -- Cahn's Axiom
"Our policy is, when in doubt, do the right thing." -- Roy L Ash
- CVS automake: depcomp/gcc3 doesn't propagate errors?,
Raja R Harinath <=