You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildr.apache.org by bo...@apache.org on 2008/02/03 01:28:38 UTC

svn commit: r617934 - /incubator/buildr/trunk/lib/java/compilers.rb

Author: boisvert
Date: Sat Feb  2 16:28:36 2008
New Revision: 617934

URL: http://svn.apache.org/viewvc?rev=617934&view=rev
Log:
Fail build if fsc compile fails

Modified:
    incubator/buildr/trunk/lib/java/compilers.rb

Modified: incubator/buildr/trunk/lib/java/compilers.rb
URL: http://svn.apache.org/viewvc/incubator/buildr/trunk/lib/java/compilers.rb?rev=617934&r1=617933&r2=617934&view=diff
==============================================================================
--- incubator/buildr/trunk/lib/java/compilers.rb (original)
+++ incubator/buildr/trunk/lib/java/compilers.rb Sat Feb  2 16:28:36 2008
@@ -104,7 +104,7 @@
       end
 
       OPTIONS = [:warnings, :deprecation, :optimise, :source, :target, :debug, :other]
-      Java.classpath << dependencies unless use_fsc
+      Java.classpath << dependencies unless Scalac.use_fsc
 
       specify :language=>:scala, :target=>'classes', :target_ext=>'class', :packaging=>:jar
 
@@ -131,7 +131,8 @@
           Scalac.scala_home or fail 'Are we forgetting something? SCALA_HOME not set.'
           puts (['scalac'] + cmd_args).join(' ') if Rake.application.options.trace
           if Scalac.use_fsc
-            system(([File.expand_path('bin/fsc', Scalac.scala_home)] + cmd_args).join(' '))
+            system(([File.expand_path('bin/fsc', Scalac.scala_home)] + cmd_args).join(' ')) or
+              fail 'Failed to compile, see errors above'
           else
             Java.load
             Java.scala.tools.nsc.Main.main(cmd_args.to_java(Java.java.lang.String)) == 0 or