From: Hans-Bernhard Broeker Newsgroups: comp.os.msdos.djgpp Subject: Re: Generic makefile! (Re: Reverse-compiler) Date: 5 Apr 2000 20:20:48 GMT Organization: Aachen University of Technology (RWTH) Lines: 21 Message-ID: <8cg770$mst$1@nets3.rz.RWTH-Aachen.DE> References: <8c3eae$j1l$1 AT news6 DOT svr DOT pol DOT co DOT uk> <8c457a$162$1 AT news7 DOT svr DOT pol DOT co DOT uk> <8caj5q$ii3$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE> <8cb2cm$t25$1 AT news6 DOT svr DOT pol DOT co DOT uk> <38EB7931 DOT C8B9E132 AT is DOT elta DOT co DOT il> <38EB8F1B DOT 16885EDC AT corel DOT com> NNTP-Posting-Host: acp3bf.physik.rwth-aachen.de X-Trace: nets3.rz.RWTH-Aachen.DE 954966048 23453 137.226.32.75 (5 Apr 2000 20:20:48 GMT) X-Complaints-To: abuse AT rwth-aachen DOT de NNTP-Posting-Date: 5 Apr 2000 20:20:48 GMT Originator: broeker@ To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Jonathan Meunier wrote: > Eli Zaretskii wrote: >> Damian Yerrick wrote: >> > >> > %.o: %.c $(HEADS) >> > gcc $(CFLAGS) -o $@ -c $< [...] > Make knows how to compile C files, but is there any easy way to make it > compile C++ files? Yes. Name them '.cc', and it'll recognize them as C++, and treat them as automatically as it already does C files. Or, failing that, write a rule like the above, with .c replaced by .cpp, somewhere in your makefile. It's all in that 'info make' documentation, see... -- Hans-Bernhard Broeker (broeker AT physik DOT rwth-aachen DOT de) Even if all the snow were burnt, ashes would remain.