diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2019-05-16 17:06:18 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2019-05-16 17:06:18 +0200 |
| commit | 9da2dd90e2e8db8cfb922eb0c064876c146070dd (patch) | |
| tree | c28af71eef5ce5ead9ce9e9508279bea673ae0ae | |
| parent | 9c64080dce9fa3e77c48ae962ff1edc5d0863c6a (diff) | |
gnu: js-mathjax: Avoid "Too many open files" error while building.
* gnu/packages/javascript.scm (js-mathjax)[arguments]: Add call to
'close-pipe'. Previously builds would sometimes fail with EMFILE (this
was non-deterministic as it depends on GC activity.)
| -rw-r--r-- | gnu/packages/javascript.scm | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index 8731a44927a..e7dcd7962d7 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm | |||
| @@ -117,7 +117,11 @@ | |||
| 117 | (let ((minified (open-pipe* OPEN_READ "uglify-js" file))) | 117 | (let ((minified (open-pipe* OPEN_READ "uglify-js" file))) |
| 118 | (call-with-output-file installed | 118 | (call-with-output-file installed |
| 119 | (lambda (port) | 119 | (lambda (port) |
| 120 | (dump-port minified port))))) | 120 | (dump-port minified port))) |
| 121 | |||
| 122 | (let ((exit (close-pipe minified))) | ||
| 123 | (unless (zero? exit) | ||
| 124 | (error "dear, uglify-js failed" exit))))) | ||
| 121 | (else | 125 | (else |
| 122 | (install-file file (dirname installed)))))) | 126 | (install-file file (dirname installed)))))) |
| 123 | (find-files ".")) | 127 | (find-files ".")) |
