Eric Schulte <
schult...@gmail.com> writes:
> Hi,
>
> I've noticed that with SBCL 1.1.1 I am unable to supply both the -script
> and -dynamic-space-size flags. Specifically, the presence of
> -dynamic-space-size causes an invocation with script to drop into the
> REPL and ignore the file.
>
> The net effect is that I'm unable to run sbcl scripts which require
> large heaps. Are these flags fundamentally incompatible, or is this
> something that may be changed at some point?
>
> This isn't really causing problems for me, but thought I'd mention it.
It's not an SBCL problem, it's a linux problem, execve(2) is unable to
pass more than one argument to shebang scripts (it actually passes all
the arguments as a single one). So, there are several solutions:
a) make a wrapper script
b) save an executable core from an SBCL which was started with a correct
--dynamic-space-size and a :save-runtime-options t option for
save-lisp-and-die
c) make the script look like a shell script, then run sbcl from it
#!/bin/sh
#|
exec sbcl --script --dynamic-space-size $@
|#
d) build SBCL with ./make.sh --dynamic-space-size=SIZE, that's similar to
the b) option, but possibly less hassle
--
With best regards, Stas.