Xref: utzoo gnu.g++.help:480 comp.lang.c++:11700 Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!spool.mu.edu!uunet!brunix!sdm From: sdm@cs.brown.edu (Scott Meyers) Newsgroups: gnu.g++.help,comp.lang.c++ Subject: genclass and makefiles Message-ID: <65384@brunix.UUCP> Date: 18 Feb 91 22:58:04 GMT Sender: news@brunix.UUCP Reply-To: sdm@cs.brown.edu (Scott Meyers) Organization: Brown University Department of Computer Science Lines: 24 I know I can use the genclass facility that comes with g++ to generate .h and .cc files from .hP and .ccP files, respectively, but I'd like to know how to write rules for Gnu make so that .h and .cc files are dependent on their respective .hP and .ccP files. A prototype file List.hP will generate int.List.h and double.List.h after the commands genclass int ref List genclass double ref List so I need some way to say that both int.List.h and double.List.h are dependent on List.hP, and the way to make a .h file from the corresponding .hP file is to run genclass. I'd like to say something like %1.%2.h: %2.hP genclass %1 ref %2 but that's not legal syntax. Can anybody help? Scott ------------------------------------------------------------------------------- What do you say to a convicted felon in Providence? "Hello, Mr. Mayor."