diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d93c00d006a101bd6e19bab8ee207f3f2e95df1c..adc1772d330ff5064f67bbb47883c0053927622a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,7 @@
 2002-07-28  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
 
+	* Makefile.in (gengtype-lex.c): Fix error in last change.
+
 	* alpha/freebsd.h (TARGET_OS_CPP_BUILTINS): Add missing
 	backslash.
 
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index 9f4b1c6de34744a37f03b95b016e2862e8756d1f..e256187dd34c57c2fc0b88d94952d2ae62fecc4e 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -2038,7 +2038,7 @@ gengtype-yacc.o : gengtype-yacc.c gengtype.h $(HCONFIG_H) $(SYSTEM_H)
 # The sed command works around a bug in flex-2.5.4.
 $(srcdir)/gengtype-lex.c : $(srcdir)/gengtype-lex.l
 	cd $(srcdir) && \
-	$(FLEX) $(FLEXFLAGS) -t -o$@ $(srcdir)/gengtype-lex.l | \
+	$(FLEX) $(FLEXFLAGS) -t -o$@ gengtype-lex.l | \
 	  sed 's/^\(char msg\[\];\)/yyconst \1/' > g-$$$$ ; \
 	if test $$? -eq 0 ; then \
 	  mv -f g-$$$$ gengtype-lex.c ; \