You were right, it was a classpath problem. But since I'm new to
classpaths it took me some time to get it right.

Thanks again, emacs+cdt makes development a lot easier :D

And, in case anyone needs to solve the same problems, these are the
steps to get cdt running for a leiningen-based project:

Suppose the project-root is in /my-home/my-project

First set up the target vm like this:
1. Start a new emacs session
2. M-x shell
3. cd /my-home/my-project
4. java -
agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=8021 -
client -cp /path/to/clojure-contrib.jar:/path/to/clojure.jar:src
clojure.main --repl
5. (use 'my-project.my-source)
The thing to note is the "src" that has been added to the classpath in
step 4

Next set up the debug vm like this:
1. Start a new emacs session
2. M-x cdt
3. port: 8021
4. (set-source-path (str @source-path "/my-home/my-project/src:"))
5. (set-bp my-project.my-source/my-function)

Now invoke the function in the target vm:
(my-function args)

On Oct 6, 3:16 am, George Jahad <cloj...@blackbirdsystems.net> wrote:
> hmmm, it's not really different from setting your classpath.
>
> From thecdt-repl, enter:
> @source-path
>
> and see if that gives you any hints.  if not, send me the output of
> that command, and the full path and namespace of one of your source
> files, I'll see if I can see anything you are missing.
>
> g
>
> On Oct 5, 6:40 am, Walter van der Laan <waltervanderl...@gmail.com>
> wrote:
>
>
>
> > Thanks George, this is great. I tried the screencast instructions and
> > it all works, but I can't get it to work with my own source. I tried
> > several settings for (set-source-path) but I must be doing something
> > wrong. Can you perhaps give an example?
>
> > On Oct 1, 10:32 pm, George Jahad <cloj...@blackbirdsystems.net> wrote:
>
> > > For your delectation:http://www.vimeo.com/15462015

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to