1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-25 14:10:22 +02:00

Fix build bug, manifested as failure to find libguile-srfi-srfi-1-v-4

* module/ice-9/boot-9.scm (top-repl): This use of @ is not safe, because
  it will cause (system repl repl) to be loaded at expand time, which
  will eventually cause (srfi srfi-1) to be loaded, which won't work
  with a fresh build tree because the helper lib isn't compiled. Gross.
  (load): Add a note about why this use of @ is safe.
This commit is contained in:
Andy Wingo 2010-06-10 17:53:47 +02:00
parent d8e1bce4fc
commit 02fcbf78b2

View file

@ -1136,6 +1136,10 @@ If there is no handler at all, Guile prints an error and then exits."
(%load-should-autocompile (%load-should-autocompile
(%warn-autocompilation-enabled) (%warn-autocompilation-enabled)
(format (current-error-port) ";;; compiling ~a\n" name) (format (current-error-port) ";;; compiling ~a\n" name)
;; This use of @ is (ironically?) boot-safe, as modules have
;; not been booted yet, so the resolve-module call in psyntax
;; doesn't try to load a module, and compile-file will be
;; treated as a function, not a macro.
(let ((cfn ((@ (system base compile) compile-file) name (let ((cfn ((@ (system base compile) compile-file) name
#:env (current-module)))) #:env (current-module))))
(format (current-error-port) ";;; compiled ~a\n" cfn) (format (current-error-port) ";;; compiled ~a\n" cfn)
@ -3650,7 +3654,12 @@ module '(ice-9 q) '(make-q q-length))}."
;; scmsigs.c scm_sigaction_for_thread), so the handlers setup here have ;; scmsigs.c scm_sigaction_for_thread), so the handlers setup here have
;; no effect. ;; no effect.
(let ((old-handlers #f) (let ((old-handlers #f)
(start-repl (@ (system repl repl) start-repl)) ;; We can't use @ here, as modules have been booted, but in Guile's
;; build the srfi-1 helper lib hasn't been built yet, which will
;; result in an error when (system repl repl) is loaded at compile
;; time (to see if it is a macro or not).
(start-repl (module-ref (resolve-module '(system repl repl))
'start-repl))
(signals (if (provided? 'posix) (signals (if (provided? 'posix)
`((,SIGINT . "User interrupt") `((,SIGINT . "User interrupt")
(,SIGFPE . "Arithmetic error") (,SIGFPE . "Arithmetic error")