diff --git a/doc/chibi.scrbl b/doc/chibi.scrbl index e832b481..1b6ff8a4 100755 --- a/doc/chibi.scrbl +++ b/doc/chibi.scrbl @@ -1630,15 +1630,16 @@ conventions, you can thus simply run \scheme{snow-chibi package \subsubsection{Other Implementations} Although the command is called \scheme{snow-chibi}, it supports -several other R7RS implementations. The \scheme{implementations} -command tells you which you currently have installed. The following -are currently supported: +several other R7RS implementations and generic installation of libraries. +The \scheme{implementations} command tells you which you currently have +installed. The following are currently supported: \itemlist[ \item{chibi - version >= 0.7.3} \item{chicken - version >= 4.9.0 with the \scheme{r7rs} egg} \item{cyclone - version >= 0.5.3} \item{foment - version >= 0.4} +\item{generic} \item{gauche - version >= 0.9.4} \item{kawa - version >= 2.0; you need to add the install dir to the search path, e.g. \scheme{-Dkawa.import.path=/usr/local/share/kawa}} \item{larceny - version 0.98; you need to add "lib/Snow" to the paths in startup.sch} diff --git a/lib/chibi/snow/commands.scm b/lib/chibi/snow/commands.scm index 4ea4736b..de83b3ce 100644 --- a/lib/chibi/snow/commands.scm +++ b/lib/chibi/snow/commands.scm @@ -25,8 +25,9 @@ (warn msg) #f)))))) (and confirm? - (yes-or-no? cfg "Implementation " (car spec) " does not " - " seem to be available, install anyway?")))) + (or (equal? (car spec) 'generic) + (yes-or-no? cfg "Implementation " (car spec) " does not " + " seem to be available, install anyway?"))))) (define (conf-selected-implementations cfg) (let ((requested (conf-get-list cfg 'implementations '(chibi)))) @@ -1370,6 +1371,10 @@ (string-trim (process->string '(icyc -p "(Cyc-installation-dir 'sld)")) char-whitespace?))))) (list (or dir "/usr/local/share/cyclone/")))) + ((generic) + (list (make-path (string-append (or (conf-get cfg 'install-prefix) + "/usr/local") + "/lib/snow")))) ((gauche) (list (let ((dir (string-trim @@ -1679,6 +1684,7 @@ (cond ((eq? impl 'chicken) (get-install-library-dir impl cfg)) ((eq? impl 'cyclone) (get-install-library-dir impl cfg)) + ((eq? impl 'generic) (get-install-library-dir impl cfg)) ((eq? impl 'guile) (get-guile-site-dir)) ((conf-get cfg 'install-source-dir)) ((conf-get cfg 'install-prefix) @@ -1689,6 +1695,7 @@ (cond ((eq? impl 'chicken) (get-install-library-dir impl cfg)) ((eq? impl 'cyclone) (get-install-library-dir impl cfg)) + ((eq? impl 'generic) (get-install-library-dir impl cfg)) ((conf-get cfg 'install-data-dir)) ((conf-get cfg 'install-prefix) => (lambda (prefix) (make-path prefix "share/snow" impl))) @@ -1704,6 +1711,8 @@ (get-chicken-binary-version cfg)))) (else (car (get-install-dirs impl cfg))))) + ((eq? impl 'generic) + (car (get-install-dirs impl cfg))) ((eq? impl 'cyclone) (car (get-install-dirs impl cfg))) ((eq? impl 'guile) diff --git a/lib/chibi/snow/utils.scm b/lib/chibi/snow/utils.scm index 9b8324e3..0ac39fbc 100644 --- a/lib/chibi/snow/utils.scm +++ b/lib/chibi/snow/utils.scm @@ -25,6 +25,10 @@ ,(delay (process->sexp '(foment -e "(write (features))")))) + (generic "generic" #f #f + ,(delay + (process->sexp + '(echo "generic")))) (gauche "gosh" (gosh -E "print (gauche-version)") "0.9.4" ,(delay (process->sexp