[Omake] BUILD_SUMMARY

Nathaniel Gray n8gray at caltech.edu
Tue Mar 27 21:50:26 PDT 2007


At some point recently the contents of the $(BUILD_SUMMARY) file  
changed.  I've got this rule in my .omakerc:

     .BUILD_FAILURE:
         cat "$(BUILD_SUMMARY)" | growlnotify -p 2 -n OMake OMake

The growlnotify command pops up a notification.  This used to give me  
a message that was cluttered, but did contain the error output of the  
build commands.  Now all I get is something like:

*** omake: targets were not rebuilt because of errors:
    example/hello.cmi
       depends on: example/hello.ml
    example/hello.cmx
       depends on: example/hello.ml
    example/hello.o
       depends on: example/hello.ml

I've also tried using $(find-build-targets Failed), taking an  
element, and examining the output-file field, but it's always false.   
I'm using "-o 1" as my output mode, though I've tried some other  
options and it doesn't seem to make any difference.

So once again I'm wondering, how can I get the error messages from a  
build command in a .BUILD_FAILURE rule?

I wonder, would it make sense to be able to specify failure actions  
on a more fine-grained basis?  I don't know how it should look, but  
maybe something like:

.FAILURE: %.o: %.c
	do-something-interesting($(failure-output),$<)

OTOH, it probably makes more sense to handle failures based on the  
program that failed, not the target or source type:

.FAILURE: $(CC)
	do-something-interesting($(failure-output),$(failed-target))

Thanks,
-n8

--
 >>>-- Nathaniel Gray -- Caltech Computer Science ------>
 >>>-- Mojave Project -- http://mojave.cs.caltech.edu -->




More information about the Omake mailing list