Date: Mon, 6 Jan 1997 16:53:58 +0200 (IST) From: Eli Zaretskii To: Alaric Dailey cc: djgpp AT delorie DOT com Subject: Re: GUILE port? In-Reply-To: <5aqh26$50s@nntp.novia.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On 6 Jan 1997, Alaric Dailey wrote: > : all_subdirs=`cat $srcdir/*/PLUGIN/REQ $srcdir/*/PLUGIN/OPT /dev/null | > : tsort | xargs echo` > > it looks like this is building a list of all the subdirectories under > $srcdir (whereever this is defined in the makefile) catting the files > (which will do the same thing as DOS "type" sorting the output making > sure there are no duplicate listings and then xargs will put the whole > damn shmear on a single line. FYI, you can do the same on MSDOS even if you don't have bash installed. If you use the port of Make 3.75, just replace the `..` with a call to the $(shell) built-in function, like so: subdir = $srcdir/*/PLUGIN all_subdirs = \ $(shell cat $subdir/REQ $subdir/OPT /dev/null | tsort | xargs echo) The difference between the two constructs is that in the last variant, the commands are run when all_subdirs is *defined*, while in the second they are run when all_subdirs is *used* (elsewhere in the Makefile).