Abort compilation if embryo_cc fails.
[redact.git] / lib / redact / app.rb
index d2b192390297aba44ee86305363bba4d99109c8c..7c5f39ee69334d8c2533712c142c95e7e32f1353 100644 (file)
@@ -1,5 +1,5 @@
 #--
-# $Id: app.rb 2 2005-03-26 19:16:37Z tilman $
+# $Id: app.rb 3 2005-03-26 19:21:15Z tilman $
 #
 # Copyright (c) 2005 Tilman Sauerbeck (tilman at code-monkey de)
 #
@@ -139,7 +139,9 @@ EOT
                                                c = "embryo_cc " +
                                                    "-i #{incl}/include " +
                                                    "-o #{tf_out.path} #{tf_in.path}"
-                                               system(c)
+                                               unless system(c)
+                                                       fail("Cannot compile Embryo code")
+                                               end
 
                                                ret[col.id] = tf_out.read
                                        end