Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1a 12/4/83; site rlgvax.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxl!houxm!houxz!vax135!floyd!cmcl2!seismo!rlgvax!guy From: guy@rlgvax.UUCP (Guy Harris) Newsgroups: net.unix,net.sources Subject: Re: file include follower - "cpp" does nicely Message-ID: <1962@rlgvax.UUCP> Date: Wed, 30-May-84 01:27:45 EDT Article-I.D.: rlgvax.1962 Posted: Wed May 30 01:27:45 1984 Date-Received: Fri, 1-Jun-84 08:37:09 EDT References: <855@ulysses.UUCP> Organization: CCI Office Systems Group, Reston, VA Lines: 14 A Makefile generator (the most common use of an include follower) was posted to "net.sources" by somebody a while ago. It used "cpp" to follow the include files - this has the advantage that it even understands "ifdef"s and the like. An example of this advantage, which crops up here a fair bit, is Makefiles for programs which provide a full-screen user interface. Such programs need an "#ifdef" for the V7/BSD tty driver vs. the USG tty driver; depending on the define, it will include or . That Makefile generator was one of the cleverer uses of "cpp" I've seen - all you do is "cc -E" the source and grab "# " lines as they go by. Guy Harris {seismo,ihnp4,allegra}!rlgvax!guy