Nokia Networks Home

Nokia nmake Product Builder

Quick Links

Related Products

Tool Repository

[ tool index ]


Reports information in HTML format about each makefile built.

Download makefiles.groovy


makefiles.groovy is a Groovy script that outputs an HTML document containing a table having a row for each makefile run during the build. The fields displayed in each row are make recursion level, directory relative to a specified root, and makefile execution start and end times. This is an example Groovy script from the Build Log Overview.


groovy. Groovy is a general purpose dynamic scripting language for the JVM that provides strong support for processing XML. Since Groovy runs on the JVM, scripts may be run on platforms supporting the JVM including Linux, Solaris, and Windows.


groovy targets.groovy filename.xml

Example Command Line

groovy makefiles.groovy makelog.xml

Example Output

See the Extended Example in the Build Log Overview for details and structure of the example build used.

    <title>Triggered makefiles</title>
    <h1>Triggered makefiles</h1>
        <th>start time</th>
        <th>end time</th>


The XML parsing and filtering steps are similar to those in targets.groovy. The HTML is generated using a Groovy MarkupBuilder. The Groovy builder mechanism provides an easy and elegant way to build nested structures without need for complex APIs. For example, the expression head() { title('Triggered makefiles') } creates an HTML head element containing a title element containing the textual content "Triggered makefiles". Since builder expressions are standard Groovy syntax, Groovy filtering and iteration constructs such as bl.'**'.grep{ == 'makelog'}.each { ... } may appear intermixed with literal HTML tag generation. This allows looping over input data structures to generate variable parts of the HTML document. See also the Build Log Overview.

def root = 'ex1/'
def bl = new XmlSlurper().parse(args[0])
def bldr = new groovy.xml.MarkupBuilder()
bldr.html {
	head() { title('Triggered makefiles') }
	body() {
		h1('Triggered makefiles')
		table() {
			tr() {
				th('start time')
				th('end time')
			bl.'**'.grep{ == 'makelog'}.each { ml ->
				tr() {
					td(ml.makeinfo.pwd.text().replaceFirst(~/.*$root/, ''))
Last Update: Friday,12-Aug-2016 12:16:39 EDT