3 ms·
GNU make already has a number of functions for things like filtering a list for strings matching a pattern. There were many requests for additional functions. T
by opk 13y ago
GNU make already has a number of functions for things like filtering a list for strings matching a pattern. There were many requests for additional functions. There's some sense to integrating guile rather than going further down the path of extending the macro/function language that GNU make essentially has.
- mturmon 13y agoOne starting place for some of these functions is: http://www.gnu.org/software/make/manual/html_node/Functions.html http://www.gnu.org/software/make/manual/html_node/Functions.... (note "foreach", "call", "eval") and: http://www.gnu.org/software/make/manual/html_node/Multi_002dLine.html http://www.gnu.org/software/make/manual/html_node/Multi_002d... For instance, from the "call" documentation -- "The call function is unique in that it can be used to create new parameterized functions." Sometimes these types of functions are really important, and you have to be creative to use the builtins to set up the dependencies you want. For instance, by combining "foreach" with "call" or "eval", you can dynamically create sets of rules. This can be quite powerful. And you don't have to use make only for software compilation. You can use it to create more general-purpose data transformations. When you get a batch of new images, for example, you type "make", and it just recomputes all the derived data (but only what depends on the new stuff). I have done this, and it was very slick, but it tends to stress the existing function set.