Running Your Clojure Application Elsewhere

It is one thing to have a nice development environment for running Clojure — mine is Ubuntu Linux — and it is  another to set up other development environments so they will run Clojure. I was expecting the worst. One of my systems is running a Linux 2.4 kernel on Red Hat Enterprise Linux 3. The other systems are fairly up-to-date, and would only require porting the Clojure and related jar files.

After installing the latest java kit according to the directions, I got a strange warning, which disappeared after a reboot:

I had to change my Clojure shell script to point to the new Java directory, so the existing Java was not disturbed.



if [ "x$CLASSPATH" = "x" ] ; then

while true ; do
case "$1" in
-cp | -classpath)
shift 2 ;;
break ;;
break ;;

exec java -cp  /usr/share/java/jre1.6.0_21/jline.jar:/usr/share/java/jre1.6.0_21/clojure.jar:/usr/share/java/jre1.6.0_21/clojure-contrib.jar:/usr/share/java/jre1.6.0_21/commons-logging-1.1.1.jar:/home/cnorton/git_build/clj-http/clj-http-0.1.3.jar"$extra_classpath" clojure.main "$@"

All in all, the porting was much simpler than I expected. That is a good thing.


Leave a comment

Filed under Clojure

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s