crude Cygwin.setup;
authorwenzelm
Mon, 28 Dec 2009 22:58:25 +0100
changeset 34203 dd2f49d88b47
parent 34202 99241daf807d
child 34204 fd76bc33b89b
crude Cygwin.setup;
src/Pure/System/cygwin.scala
--- a/src/Pure/System/cygwin.scala	Mon Dec 28 22:57:37 2009 +0100
+++ b/src/Pure/System/cygwin.scala	Mon Dec 28 22:58:25 2009 +0100
@@ -94,5 +94,14 @@
     if (!ok) error("Bad Cygwin installation: " + root)
     root
   }
+
+  def setup(exe: String, root: String): Int =
+  {
+    val (output, rc) = Standard_System.process_output(
+    	Standard_System.raw_execute(null, true, exe, "-R", root, "-P", "perl,python", "-q", "-n"))
+    val root_dir = new File(root)
+    if (root_dir.isDirectory) Standard_System.write_file(new File(root, "setup.log"), output)
+    rc
+  }
 }