[racket] copy-shared-files and different platforms

From: Jens Axel Søgaard (jensaxel at soegaard.net)
Date: Tue Aug 26 11:55:03 EDT 2014

2014-08-26 17:04 GMT+02:00 Matthew Flatt <mflatt at cs.utah.edu>:
> Another detail for Windows is that you need to explicitly load a DLL X
> is that referenced by a DLL Y before loading Y.

Thanks for the hint!

I suppose libffi doesn't indicate in the error number whether loading
failed due to a missing dependency or a missing lib?

> That load-before-reference issue is partly why you see a list of DLLs
> at
>
> https://github.com/plt/racket/blob/master/pkgs/draw-pkgs/draw-lib/racket/draw/unsafe/cairo-lib.rkt

I'll copy the method.

> Another reason for the list of libraries there (and why it shows up for
> Mac OS X, too) is to ensure that shared libraries are pulled along for
> stand-alone executables. The `define-runtime-lib` macro expands to
> `define-runtime-path-list` as well as `ffi-lib`.

Good point.

Thanks,
Jens Axel

Posted on the users mailing list.