slib-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Slib-discuss] Windows XP + PLT Scheme 4.1 + SLIB 3b1: Loading mzscheme.


From: Elena Garrulo
Subject: [Slib-discuss] Windows XP + PLT Scheme 4.1 + SLIB 3b1: Loading mzscheme.init fails.
Date: Fri, 3 Oct 2008 09:37:05 +0000

Hi,

loading SLIB inizialization file for PLT Scheme (mzscheme.init) fails with error:

> mzscheme.init:302:3: compile: unbound variable in module in: slib:require

The offending sexp:

> (define (defmacro:expand* x)
>  (slib:require 'defmacroexpand) (apply defmacro:expand* x '()))


Here are the steps I've followed:

1) Downloaded and run slib-3b1-1.exe.

2) According to installation instructions, you should customize mzscheme.init:
- setting environment variables SCHEME_LIBRARY_PATH, MZSCHEME_IMPLEMENTATION_PATH;
- checking software-type, scheme-implementation-version, implementation-vicinity, and library-vicinity.

Here are my environment variables (all SLIB's *.scm files are in "%HOME%\my\scheme\slib\slib_3b1-1\slib")

> set HOME=C:\Documents and Settings\me
> set SLIB_HOME=%HOME%\my\scheme\slib\slib_3b1-1\slib\
> set PLTHOME=C:\Programmi\PLT-Scheme
> set PLT_HOME=%PLTHOME%
> set PLT_VERSION=4.1
> set PLTCOLLECTS=%PLT_HOME%\collects;%SLIB_HOME%

> set MZSCHEME_IMPLEMENTATION_PATH=%PLT_HOME%
> set SCHEME_LIBRARY_PATH=%SLIB_HOME%

I've also tried:

- without trailing "\":

> set SLIB_HOME=%HOME%\my\scheme\slib\slib_3b1-1\slib

- without trailing "slib":

> set SLIB_HOME=%HOME%\my\scheme\slib\slib_3b1-1\

- without trailing "\slib\":

> set SLIB_HOME=%HOME%\my\scheme\slib\slib_3b1-1


"software-type" looks correct:

> ;;@ (software-type) should be set to the generic operating system type.
> ;;; unix, vms, macos, amiga and ms-dos are supported.
> (define (software-type)
>   (case (system-type)
>     [(unix macosx) 'unix]
>     [(windows) 'ms-dos] ;; <<== OK
>     [(macos) 'macos]
>     [else (system-type)]))

Customized "scheme-implementation-version":

> ;;@ (scheme-implementation-version) should return a string describing
> ;;; the version the scheme implementation loading this file.
> (define scheme-implementation-version (string->number (getenv "PLT_VERSION")))


"implementation-vicinity" looks correct:

> ;;@ (implementation-vicinity) should be defined to be the pathname of
> ;;; the directory where any auxillary files to your Scheme
> ;;; implementation reside.
> (define implementation-vicinity
>   (let ([path
>      (or (getenv "MZSCHEME_IMPLEMENTATION_PATH")  <<== OK
[remainder skipped]

library-vicinity looks correct:

> ;;@ (library-vicinity) should be defined to be the pathname of the
> ;;; directory where files of Scheme library functions reside.
> (define library-vicinity
>   (let ((library-path
>          (or
>           ;; Use this getenv if your implementation supports it.
>           (getenv "SCHEME_LIBRARY_PATH") ;; <<== OK, MzScheme supports "getenv"
[remainder skipped]

   
3) I've added this lines on top of mzscheme.init to fix compilation errors ("if without else" and "unbound variable in module in: find-seconds":

> #lang mzscheme
> (require scheme/date)


What I'm missing?
Thanks


reply via email to

[Prev in Thread] Current Thread [Next in Thread]