java.lang.NoClassDefFoundError: clojure/main

369 views
Skip to first unread message

Terrence Brannon

unread,
Feb 3, 2009, 10:17:43 PM2/3/09
to Clojure
Hello, I cannot get slime and clojure-mode up and running:

;;; inferior lisp output

(add-classpath "file:///c:/Documents and Settings/Administrator/
Application Data/emacs-contrib/swank-clojure/")

(require 'swank.swank)

(swank.swank/ignore-protocol-version "2009-01-30")

(swank.swank/start-server "c:/DOCUME~1/ADMINI~1/LOCALS~1/Temp/slime.
21424" :encoding "iso-latin-1-unix")

java.lang.NoClassDefFoundError: clojure/main
Caused by: java.lang.ClassNotFoundException: clojure.main
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: clojure.main. Program will exit.
Exception in thread "main"
Process inferior-lisp exited abnormally with code 1

;;; .emacs

;;; clojure-mode


;;; http://github.com/nablaone/slime/tree/master
(add-to-list 'load-path "~/emacs-contrib/slime")

;;; http://github.com/jochu/swank-clojure/tree/master
(add-to-list 'load-path "~/emacs-contrib/swank-clojure")

;;; http://github.com/jochu/clojure-mode/tree/master
(add-to-list 'load-path "~/emacs-contrib/clojure-mode")

(require 'slime)

(autoload 'slime "slime" "" t)
;(swank-clojure-config (setq swank-clojure-jar-path "~/src/clojure/
clojure.jar"))
(setq swank-clojure-jar-path "~/src/clojure/clojure.jar")

;(setq swank-clojure-extra-classpaths '("~/src/clojure-contrib/clojure-
contrib.jar"))

;; (setq swank-clojure-binary "clojure")
;(require 'clojure-auto)
(require 'swank-clojure-autoload)

(autoload 'clojure-mode "clojure-mode" "A major mode for Clojure" t)
(add-to-list 'auto-mode-alist '("\\.clj$" . clojure-mode))

Terrence Brannon

unread,
Feb 4, 2009, 7:26:47 AM2/4/09
to Clojure
well, I found technomancy's update of clojure mode... there was
something very odd though.

each time I would 'git clone' it, I would end up with the jochu source
code instead... even though .git/config pointed to technomancy's
github location!

I had to manually download the .zip file and unpack it!

My working .emacs config is here -
http://paste.lisp.org/display/74865

inlined for convenience -
;;; clojure-mode
;;; http://github.com/technomancy/clojure-mode/tree/master

(add-to-list 'load-path "c:/tmp/c/technomancy-clojure-mode")
(require 'clojure-mode)

(setq clojure-src-root "c:/tmp/c")
(clojure-slime-config)

(autoload 'clojure-mode "clojure-mode" "A major mode for Clojure" t)
(add-to-list 'auto-mode-alist '("\\.clj$" . clojure-mode))




Reply all
Reply to author
Forward
0 new messages