109 val download = new File(root, "download") |
109 val download = new File(root, "download") |
110 if (!download.mkdir) error("Failed to create download directory: " + download) |
110 if (!download.mkdir) error("Failed to create download directory: " + download) |
111 |
111 |
112 val setup_exe = new File(root, "setup.exe") |
112 val setup_exe = new File(root, "setup.exe") |
113 |
113 |
114 try { Download.file(parent, new URL("http://www.cygwin.com/setup.exe"), setup_exe) } |
114 try { |
|
115 Download.file(parent, "Downloading", new URL("http://www.cygwin.com/setup.exe"), setup_exe) |
|
116 } |
115 catch { case _: RuntimeException => error("Failed to download Cygwin setup program") } |
117 catch { case _: RuntimeException => error("Failed to download Cygwin setup program") } |
116 |
118 |
117 val (_, rc) = Standard_System.raw_exec(root, null, true, |
119 val (_, rc) = Standard_System.raw_exec(root, null, true, |
118 setup_exe.toString, "-R", root.toString, "-l", download.toString, |
120 setup_exe.toString, "-R", root.toString, "-l", download.toString, |
119 "-P", "make,perl,python", "-q", "-n") |
121 "-P", "make,perl,python", "-q", "-n") |