Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4123758
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T23:39:10+00:00 2026-05-20T23:39:10+00:00

I have a plain project structure: Base Dir src ;; Pile of Clojure files

  • 0

I have a plain project structure:

Base Dir
   src ;; Pile of Clojure files
   lib ;; Jar files

To export the classpath:
$ export CLASSPATH=$CLASSPATH:src:lib/*

Trying to run a Clojure file:
java -cp $CLASSPATH -jar lib/clojure.jar src/wizard-game.clj
But I got:

Exception in thread “main” java.io.FileNotFoundException: Could not locate clojure/contrib/trace_init.class or clojure/contrib/trace.clj on classpath:
Caused by: java.io.FileNotFoundException: Could not locate clojure/contrib/trace
_init.class or clojure/contrib/trace.clj on classpath:

Ok, this is a classpath issue but what/where I’m doing wrong?

Is there a better way to try to run it?

UPDATE:
I tried this command:

java -classpath $CLASSPATH clojure.main src/wizard-game.clj

It runs ok now.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T23:39:10+00:00Added an answer on May 20, 2026 at 11:39 pm

    From the java man pages regarding the -jar option:

    When you use this option, the JAR file
    is the source of all user classes, and
    other user class path settings are
    ignored.

    So that’s a bit of a bummer, but the good news is that you can get around this by using a different launching syntax (referenced at clojure.org):

    java -cp $CLASSPATH clojure.main src/wizard-game.clj
    

    Alternatively, use a tool like Leiningen to manage your project’s classpath and dependencies for you!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I do have to deal with very large plain text files (over 10 gigabytes,
I have the following IntegrationTest project structure ... If i wish to use that
Preface: This is not much about how to structure code within files. I have
I got a plain spring3 web project set up and have a controller method
I have a GWT game project. I'd like to pull some of the base
I am working in a plain C (embedded project, little memory) and I have
I have a plain project with blank UIView . Later, when I'm get some
Imagine you have a PlayN game which uses Guice bindings in its core project:
I have a plain html web page with an embedded flash object. Based on
In an iPhone application, I have some plain C functions. Is it possible to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.