Hi,
Does anyone out there know how to access command-line arguments in
openmcl? I have a function that extract command line arguments from cmucl,
sbcl, clisp, gcl and acl, but I can't find any documentation for such
things in openmcl.
(defun get-argv ()
#+clisp *args*
#+cmu (nthcdr 5 lisp::lisp-command-line-list)
#+sbcl (cdr sb-ext:*posix-argv*)
#+gcl (nthcdr 3 si::*command-args*)
#+acl (system:command-line-arguments t)
)
In each case, I've invoked a saved lisp image with appropriate leading
command line arguments. The get-argv function extracts the remaining
arguments. In openmcl, I'm invoking my image as follows:
openmcl -I maxima.image foo bar baz
I would like get-argv to return ("foo" "bar" "baz").
Thanks for any help.
--Jim Amundson
James Amundson <········@users.sourceforge.net> writes:
> Hi,
>
> Does anyone out there know how to access command-line arguments in
> openmcl? I have a function that extract command line arguments from cmucl,
> sbcl, clisp, gcl and acl, but I can't find any documentation for such
> things in openmcl.
>
> (defun get-argv ()
> #+clisp *args*
It's wrong. It should be:
#+clisp ext:*args*
> #+cmu (nthcdr 5 lisp::lisp-command-line-list)
> #+sbcl (cdr sb-ext:*posix-argv*)
> #+gcl (nthcdr 3 si::*command-args*)
> #+acl (system:command-line-arguments t)
> )
--
__Pascal_Bourguignon__
http://www.informatimago.com/