I have a small proof of concept I'm trying to build.In the project's
super pom , I have a dependency to spring specified as

 <dependency>
     <groupId>oracle.ldap</groupId>
     <artifactId>ldapjclnt</artifactId>
     <version>1.0</version>
   </dependency>
   <dependency>
     <groupId>javax.j2ee</groupId>
     <artifactId>j2ee</artifactId>
     <version>1.3.0</version>
   </dependency>
  <dependency>
     <groupId>org.springframework</groupId>
     <artifactId>spring</artifactId>
     <version>1.2.3</version>
     <scope>test</scope>
   </dependency>
   <dependency>
     <groupId>org.apache.log4j</groupId>
     <artifactId>log4j</artifactId>
     <version>1.2.13</version>
     <scope>test</scope>
   </dependency>


However when I run the build I'm getting build failure due to failed
dependencies on the spring-1.2.3.jar and the log4j-1.2.13.jar  files.

A snippet of the log shows that these two jars are not being passed to
the maven-compiler-plugin 's classpath :

[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-compiler-plugin:2.0.1:compile' -->
[DEBUG]   (f) basedir =
C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal
[DEBUG]   (f) buildDirectory =
C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target
[DEBUG]   (f) classpathElements =
[C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target\classes,
D:\Documents and
Settings\mutonhj\.m2\repository\javax\j2ee\j2ee\1.3.0\j2ee-1.3.0.jar,
D:\Documents and
Settings\mutonhj\.m2\repository\oracle\ldap\ldapjclnt\1.0\ldapjclnt-1.0.jar]
[DEBUG]   (f) compileSourceRoots =
[C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src]
[DEBUG]   (f) compilerId = javac
[DEBUG]   (f) debug = true
[DEBUG]   (f) fork = false
[DEBUG]   (f) optimize = false
[DEBUG]   (f) outputDirectory =
C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target\classes
[DEBUG]   (f) outputFileName = dev-ep1x-eportal-1.0.0
[DEBUG]   (f) projectArtifact =
za.co.pragmaticus.dev-ep1x.eportal:dev-ep1x-eportal:ejb:1.0.0
[DEBUG]   (f) showDeprecation = false
[DEBUG]   (f) showWarnings = false
[DEBUG]   (f) staleMillis = 0
[DEBUG]   (f) verbose = false
[DEBUG] -- end configuration --
[INFO] [compiler:compile]
[DEBUG] Using compiler 'javac'.
[DEBUG] Source directories:
[C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src]
[DEBUG] Classpath:
[C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target\classes
D:\Documents and
Settings\mutonhj\.m2\repository\javax\j2ee\j2ee\1.3.0\j2ee-1.3.0.jar
D:\Documents and
Settings\mutonhj\.m2\repository\oracle\ldap\ldapjclnt\1.0\ldapjclnt-1.0.jar]
[DEBUG] Output directory:
C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target\classes
[DEBUG] Classpath:
[DEBUG]  
C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target\classes
[DEBUG]  D:\Documents and
Settings\mutonhj\.m2\repository\javax\j2ee\j2ee\1.3.0\j2ee-1.3.0.jar
[DEBUG]  D:\Documents and
Settings\mutonhj\.m2\repository\oracle\ldap\ldapjclnt\1.0\ldapjclnt-1.0.jar
[DEBUG] Source roots:
[DEBUG]  C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src
Compiling 392 source files to
C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\target\classes
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure

.........

C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src\za\co\pragmaticus\portal\controllers\ApplicationPDCRegistrationController.java:[5,24]
package org.apache.log4j does not exist

C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src\za\co\pragmaticus\portal\controllers\ApplicationPDCRegistrationController.java:[6,43]
package org.springframework.web.servlet.mvc does not exist

C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src\za\co\pragmaticus\portal\controllers\ApplicationPDCRegistrationController.java:[7,44]
package org.springframework.web.servlet.view does not exist

C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src\za\co\pragmaticus\portal\controllers\ApplicationPDCRegistrationController.java:[8,39]
package org.springframework.web.servlet does not exist

C:\pragmaticus-sea-ias\eclipse-3.1.2-workspaces\dev-ep1x\eportal\src\za\co\pragmaticus\portal\controllers\ApplicationPDCRegistrationController.java:[10,41]
package org.springframework.beans.factory does not exist


This does not seem to make any sense , because the other 2 jars in my
dependency configuration , namely  ldapjclnt-1.0.jar and
j2ee-1.3.0.jar , are included in the build classpath.

--

Jeff  Mutonho
Cape Town
South Africa

GoogleTalk : ejbengine
Skype        : ejbengine
Registered Linux user number 366042

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to