Re: Loading packages
- From: "justinhj" <justinhj@xxxxxxxxx>
- Date: 31 Jan 2006 14:08:32 -0800
Matt wrote:
> You guys, please help, I'm going nuts trying to write a lexer
> in Lisp and I can't take it anymore. I downloaded a package
> from, ah, the internet, Michael Parker to be exact, and I can't
> figure out how to load it into CLisp. It has three different
> packages that all have to be used together apparently, and they
> share file names, so I put them in three different folders:
> clawk, lexer and regex. I want to use the lexer package, but
> it needs the other two. The lexer package has these files:
>
> lexer.lisp
> lexer.system
> lexer.translations
> packages.lisp
>
> The other packages have similar files. They all have a file
> called "packages.lisp". Can anyone tell me what the deal is
> with these? What is packages.lisp and what are the .system
> and .translations files for? And what commands do I need to
> issue to use them? It keeps telling me that some package
> doesn't exist when I try to load them. I can't figure it out
> and there's no documentation or anything.
>
> Thanks!
> Matt
The book Practical Common Lisp has a nice introduction to packages
including what you would put in a packages.lisp file.
http://www.gigamonkeys.com/book/programming-in-the-large-packages-and-symbols.html
Personally I find the best way to understand packages is to create and
play with them on the REPL first.
You should be doing a defpackage for each package you want to use in
the packages.lisp, and then when you want to use the code use
in-package to say that this is the package you are now using.
Sounds like what you've done is put a couple of different packages.lisp
into one folder and lost one of them? You need to merge them rather
than overwrite them.
Justin
.
- References:
- Loading packages
- From: Matt
- Loading packages
- Prev by Date: Re: Common Lisp Application Builder news
- Previous by thread: Loading packages
- Index(es):
Relevant Pages
|