summaryrefslogtreecommitdiff
path: root/guix/build-system
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2023-10-06 13:13:47 +0200
committerRicardo Wurmus <rekado@elephly.net>2023-10-06 16:37:16 +0200
commit9d4339afb16af0f057b8a8afe8da443c33fb63e1 (patch)
tree5904e275b8d067e8f43462abbdccc3a6bf0860d1 /guix/build-system
parentb19dfb9d3a78d020cd1c5d94f60e22702bf9a1e9 (diff)
build-system/minify: Use esbuild.
* guix/build-system/minify.scm (default-uglify-js): Replace this procedure... (default-esbuild): ...with this new procedure. (lower): Use it, and add "esbuild" to build inputs. * guix/build/minify-build-system.scm (minify): Invoke esbuild instead of setting up a pipe to uglifyjs. * gnu/packages/cran.scm (r-shiny)[native-inputs]: Replace node-uglify-js with esbuild. * gnu/packages/statistics.scm (r-dt)[native-inputs]: Same.
Diffstat (limited to 'guix/build-system')
-rw-r--r--guix/build-system/minify.scm12
1 files changed, 6 insertions, 6 deletions
diff --git a/guix/build-system/minify.scm b/guix/build-system/minify.scm
index 787235deeb..b377b506b5 100644
--- a/guix/build-system/minify.scm
+++ b/guix/build-system/minify.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
+;;; Copyright © 2017, 2018, 2023 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2021 Ludovic Courtès <ludo@gnu.org>
;;;
;;; This file is part of GNU Guix.
@@ -41,15 +41,15 @@
`((guix build minify-build-system)
,@%gnu-build-system-modules))
-(define (default-uglify-js)
+(define (default-esbuild)
"Return the default package to minify JavaScript source files."
;; Lazily resolve the binding to avoid a circular dependency.
- (let ((mod (resolve-interface '(gnu packages uglifyjs))))
- (module-ref mod 'uglifyjs)))
+ (let ((mod (resolve-interface '(gnu packages web))))
+ (module-ref mod 'esbuild)))
(define* (lower name
#:key source inputs native-inputs outputs system
- (uglify-js (default-uglify-js))
+ (esbuild (default-esbuild))
#:allow-other-keys
#:rest arguments)
"Return a bag for NAME."
@@ -64,7 +64,7 @@
'())
,@inputs
,@(standard-packages)))
- (build-inputs `(("uglify-js" ,uglify-js)
+ (build-inputs `(("esbuild" ,esbuild)
,@native-inputs))
(outputs outputs)
(build minify-build)