Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!tut.cis.ohio-state.edu!ICS.UCI.EDU!rfg From: rfg@ICS.UCI.EDU Newsgroups: gnu.gcc.bug Subject: gcc 01069001 bug+fix - cpp fails to recognize .C suffix for -M option Message-ID: <9001061420.aa06729@ICS.UCI.EDU> Date: 6 Jan 90 22:20:46 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 23 /* When the gnu C preprocessor (v 1.36) is used with g++ (1.36.1) and when the -M option is used, the filename suffixes .c and .cc are properly handled, but the .C suffix (also valid for c++ source files is not properly recognized. This results in invalid target names being printed. */ diff -rc2 1.36.1-/cccp.c 1.36.1+/cccp.c *** 1.36.1-/cccp.c Mon Sep 11 20:43:13 1989 --- 1.36.1+/cccp.c Thu Jan 4 23:39:02 1990 *************** *** 936,940 **** /* Output P, but remove known suffixes. */ len = strlen (p); ! if (p[len - 2] == '.' && p[len - 1] == 'c') deps_output (p, len - 2); else if (p[len - 3] == '.' --- 935,939 ---- /* Output P, but remove known suffixes. */ len = strlen (p); ! if (p[len - 2] == '.' && ((p[len - 1] == 'c') || (p[len - 1] == 'C'))) deps_output (p, len - 2); else if (p[len - 3] == '.'