Hello, sorry for the noob question, but I'm just starting out with ECL,
and I can't quite find a solution for the following problem: some
packages in the CL ecosystem seem to assume, that the toplevel is only
evaluated during development / compilation, so by the time the final
executable will have been launched all toplevel defparameters and
defvars already have their precomputed values.

One such example is this bit of code:
https://github.com/sabracrolleton/uax-15/blob/v0.1.3/src/precomputed-tables.lisp#L12
which gets pulled in by postmodern, for example. It reads some text
files from the module's source directory and stores the result in a
global variable. For image-based implementations this is not a problem,
but in ECL the evaluation of this code is deferred until runtime, and
ultimately fails, if executed on a different computer, where the source
code of the module is not available.

Which prompts the question: is it possible to instruct ECL to precompute
top-level variables before translating them to C code? If not, what's
the general strategy of dealing with such modules, short of patching
each dependency that has this problem?

Reply via email to