summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCayetano Santos <csantosb@inventati.org>2026-02-07 22:44:27 +0100
committerCayetano Santos <csantosb@inventati.org>2026-02-10 20:24:47 +0100
commit157e6aa38eaaa04ba83cbbabec7797e0d933edae (patch)
tree2df0918846e39ab97a6a7fd701cbddc1759008e1
parent0b17432decca0c8d10f5fd20f6e839db663f2616 (diff)
gnu: bigloo: Modernize.
* gnu/packages/scheme.scm (bigloo)[arguments]: Use G-Expressions. [inputs]: Remove emacs; add gmp. [propagated-inputs]: Remove gmp. [native-inputs]: Add emacs. Merges guix/guix!6219 Change-Id: I43d073d3aeb9348d56546004f006119f841f8c38
-rw-r--r--gnu/packages/scheme.scm113
1 files changed, 55 insertions, 58 deletions
diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index 9842eda6e09..0b886ca61ee 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -243,66 +243,63 @@ features an integrated Emacs-like editor and a large runtime library.")
243 ;; Remove bundled libraries. 243 ;; Remove bundled libraries.
244 (modules '((guix build utils))) 244 (modules '((guix build utils)))
245 (snippet 245 (snippet
246 '(begin 246 #~(begin
247 (for-each delete-file-recursively 247 (for-each delete-file-recursively
248 '("gc" "gmp" "libuv" "libunistring" "pcre")) 248 '("gc" "gmp" "libuv" "libunistring" "pcre"))))))
249 #t))))
250 (build-system gnu-build-system) 249 (build-system gnu-build-system)
251 (arguments 250 (arguments
252 `(#:test-target "test" 251 (list
253 #:phases 252 #:test-target "test"
254 (modify-phases %standard-phases 253 #:phases
255 (add-after 'unpack 'fix-gmp-detection 254 #~(modify-phases %standard-phases
256 (lambda _ 255 (add-after 'unpack 'fix-gmp-detection
257 (substitute* "configure" 256 (lambda _
258 (("gmpversion=`\\$autoconf gmp --lib=\\$gmplib`") 257 (substitute* "configure"
259 "gmpversion=`\\$autoconf gmp --lib=\"\\$gmplib\"`")))) 258 (("gmpversion=`\\$autoconf gmp --lib=\\$gmplib`")
260 (replace 'configure 259 "gmpversion=`\\$autoconf gmp --lib=\"\\$gmplib\"`"))))
261 (lambda* (#:key inputs outputs #:allow-other-keys) 260 (replace 'configure
261 (lambda _
262 262
263 (substitute* "configure" 263 (substitute* "configure"
264 (("^shell=.*$") 264 (("^shell=.*$")
265 (string-append "shell=" (which "bash") "\n")) 265 (string-append "shell=" (which "bash") "\n"))
266 (("`date`") "0")) 266 (("`date`") "0"))
267 (substitute* "autoconf/runtest.in" 267 (substitute* "autoconf/runtest.in"
268 ((", @DATE@") "")) 268 ((", @DATE@") ""))
269 (substitute* "autoconf/osversion" 269 (substitute* "autoconf/osversion"
270 (("^version.*$") "version=\"\"\n")) 270 (("^version.*$") "version=\"\"\n"))
271 (substitute* "comptime/Makefile" 271 (substitute* "comptime/Makefile"
272 (("\\$\\(LDCOMPLIBS\\)") 272 (("\\$\\(LDCOMPLIBS\\)")
273 "$(LDCOMPLIBS) $(LDFLAGS)")) 273 "$(LDCOMPLIBS) $(LDFLAGS)"))
274 274
275 ;; The `configure' script doesn't understand options 275 ;; The `configure' script doesn't understand options
276 ;; of those of Autoconf. 276 ;; of those of Autoconf.
277 (let ((out (assoc-ref outputs "out"))) 277 (invoke "./configure"
278 (invoke "./configure" 278 (string-append "--prefix=" #$output)
279 (string-append "--prefix=" out) 279 ;; use system libraries
280 ; use system libraries 280 "--customgc=no"
281 "--customgc=no" 281 "--enable-gmp"
282 "--enable-gmp" 282 "--customgmp=no"
283 "--customgmp=no" 283 "--customunistring=no"
284 "--customunistring=no" 284 "--customlibuv=no"
285 "--customlibuv=no" 285 (string-append"--mv=" (which "mv"))
286 (string-append"--mv=" (which "mv")) 286 (string-append "--rm=" (which "rm"))
287 (string-append "--rm=" (which "rm")) 287 "--cflags=-fPIC"
288 "--cflags=-fPIC" 288 (string-append "--ldflags=-Wl,-rpath=" #$output
289 (string-append "--ldflags=-Wl,-rpath=" 289 "/lib/bigloo/" #$version)
290 (assoc-ref outputs "out") 290 (string-append "--lispdir=" #$output
291 "/lib/bigloo/" ,upstream-version) 291 "/share/emacs/site-lisp")
292 (string-append "--lispdir=" out 292 "--sharedbde=yes"
293 "/share/emacs/site-lisp") 293 "--sharedcompiler=yes"
294 "--sharedbde=yes" 294 "--disable-patch")))
295 "--sharedcompiler=yes" 295 (add-after 'install 'install-emacs-modes
296 "--disable-patch")))) 296 (lambda _
297 (add-after 'install 'install-emacs-modes 297 (invoke "make" "-C" "bmacs" "all" "install"
298 (lambda* (#:key outputs #:allow-other-keys) 298 (string-append "EMACSBRAND=emacs25")
299 (let* ((out (assoc-ref outputs "out")) 299 (string-append "EMACSDIR="
300 (dir (string-append out "/share/emacs/site-lisp"))) 300 #$output "/share/emacs/site-lisp")))))))
301 (invoke "make" "-C" "bmacs" "all" "install"
302 (string-append "EMACSBRAND=emacs25")
303 (string-append "EMACSDIR=" dir))))))))
304 (inputs 301 (inputs
305 (list emacs ;UDE needs the X version of Emacs 302 (list gmp ;bigloo.h refers to gmp.h
306 (module-ref 303 (module-ref
307 (resolve-interface '(gnu packages debug)) 'libbacktrace) 304 (resolve-interface '(gnu packages debug)) 'libbacktrace)
308 libgc 305 libgc
@@ -316,9 +313,9 @@ features an integrated Emacs-like editor and a large runtime library.")
316 libphidget 313 libphidget
317 pcre)) 314 pcre))
318 (native-inputs 315 (native-inputs
319 (list pkg-config which)) 316 (list emacs ;UDE needs the X version of Emacs
320 (propagated-inputs 317 pkg-config
321 (list gmp)) ; bigloo.h refers to gmp.h 318 which))
322 (home-page "https://www-sop.inria.fr/indes/fp/Bigloo/") 319 (home-page "https://www-sop.inria.fr/indes/fp/Bigloo/")
323 (synopsis "Efficient Scheme compiler") 320 (synopsis "Efficient Scheme compiler")
324 (description 321 (description