[plt-scheme] Problem with compiled file dependencies

From: Paulo J. Matos (pocm at soton.ac.uk)
Date: Sat Mar 10 07:07:47 EST 2007

Hello all,

I have the following:
(module foo mzscheme
  (require "bar.scm")
  (provide foo-test)

  (define (foo-test x) (bar x)))

(module bar mzscheme

  (provide bar)

  (define (bar x)
    (* 2 x)))

Now in interactions:
> (require (lib "compile.ss"))
> (compile-file "test/foo.scm")
> (dynamic-require "test/compiled/foo.zo" 'foo-test)
. open-input-file: cannot open input file:
"/home/pmatos/test/compiled/bar.scm" (No such file or directory;

I understand that bar.scm is not in the same dir as the compiled file.
I could just compile the file to the same dir as the bar.scm but I
would like to know about other solutions. Any suggestions?

Paulo Jorge Matos - pocm at soton.ac.uk
PhD Student @ ECS
University of Southampton, UK

Posted on the users mailing list.