Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
    Bookmark Topic Watch Topic
  • New Topic

Help, I kept getting compilation error "package javax.ejb does not exist"

 
L. Wei
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Report post to moderator
I am a newbie to EJB and now reading EJB3 in Action. I am trying to run the example of Chapter1. I am setting up JBoss AS 5.1.0.GA and Ant on Mac OSX. I downloaded sample zip file from the book website, and tried to compile the 1st chapter. However, I kept getting the compilation error "package javax.ejb does not exist" while using ant. I tried to modify the build.xml file under the chapter1 folder, but still couldn't get it compiled. I couldn't find any solution in the sample instruction pdf file. Where is the jar file should I include for package javax.ejb? so frustrated...

Here is the build.xml file.


Here is my env setup


I did setup JBOSS_HOME and added ant in the PATH. What did I miss in the setup? Please help...
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Report post to moderator
Your ant script is using the common.j2ee.class.path property to define where the J2EE jars are. I guess it is defined in the imported ../common.xml. Can you show the content of common.xml ?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Report post to moderator
Do not duplicate threads. You're wasting other people's time by doing so. Continue the discussion there.
 
It is sorta covered in the JavaRanch Style Guide.
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!