Sid, Find first, in which jar, not found class is and then include that jar in dependency. You can use jarbrowser to find not found class's jar file. Vijay
________________________________ From: SiD <tourment> [mailto:[EMAIL PROTECTED] Sent: Fri 4/14/2006 10:48 AM To: Maven Users List Subject: [M2] Strange Compile Problem (cannot access ...) hey all, i need to include maven in a huge j2ee project. i have a strange error when compiling a part of this main projet (~70 little projects) i have indicated ALL the dependencies needed, it compile into Eclipse / IRAD without problem. but, with mvn compile i got : >mvn -e clean compile + Error stacktraces are turned on. [INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------- --- [INFO] Building Unnamed - xxx:xxx:jar:0. 0.1 [INFO] task-segment: [clean, compile] [INFO] ------------------------------------------------------------------------- --- [INFO] [clean:clean] [INFO] Deleting directory xxx\Target [INFO] Deleting directory xxx\bin [INFO] Deleting directory xxx\test-bin [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:compile] Compiling 224 source files to xxx\bin [INFO] ------------------------------------------------------------------------- --- [ERROR] BUILD FAILURE [INFO] ------------------------------------------------------------------------- --- [INFO] Compilation failure xxxUtils.java:[52,54] cannot access com.ibm.portal .admin.Client file com\ibm\portal\admin\Client.class not found String url = Finder.findThemeResource (runData .getContext(), profile, runData.getRequest().getLocale(), runData.getTheme(), fi leName); [INFO] ------------------------------------------------------------------------- --- [INFO] Trace org.apache.maven.BuildFailureException: Compilation failure at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals (Defa ultLifecycleExecutor.java:552) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLi fecycle(DefaultLifecycleExecutor.java:472) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal (Defau ltLifecycleExecutor.java:451) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan dleFailures(DefaultLifecycleExecutor.java:303) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen ts(DefaultLifecycleExecutor.java:270) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute (DefaultLi fecycleExecutor.java:139) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115) at org.apache.maven.cli.MavenCli.main(MavenCli.java:249) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java :315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java :430) at org.codehaus.classworlds.Launcher.main(Launcher.java:375) Caused by: org.apache.maven.plugin.CompilationFailureException: Compilation fail ure at org.apache.maven.plugin.AbstractCompilerMojo.execute (AbstractCompiler Mojo.java:429) at org.apache.maven.plugin.CompilerMojo.execute(CompilerMojo.java :110) at org.apache.maven.plugin.DefaultPluginManager.executeMojo (DefaultPlugi nManager.java:415) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals (Defa ultLifecycleExecutor.java:531) ... 16 more [INFO] ------------------------------------------------------------------------- --- [INFO] Total time: 4 seconds [INFO] Finished at: Fri Apr 14 17:02:41 CEST 2006 [INFO] Final Memory: 3M/21M [INFO] ------------------------------------------------------------------------- --- you can see the dependencies of the project in the .classpath file first : <?xml version="1.0" encoding="UTF-8"?> <classpath> <classpathentry kind="src" path="Java Source"/> <classpathentry sourcepath="JRE_SRC" kind="var" path="JRE_LIB"/> <classpathentry kind="var" path="WAS_PLUGINDIR/lib/j2ee.jar"/> <classpathentry kind="var" path="WAS_PLUGINDIR/lib/webcontainer.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/calypso- core-services-1.6.1.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/calypso- dbms-1.6.1.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/calypso- utils-1.6.1.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/commons- beanutils.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/commons- digester.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/commons- lang-2.0.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/commons- logging-1.0.3.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/graphics.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/htmlparser.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/jcifs- 0.6.8.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/jcs.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/jlog- 2.2.1.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/DocEditor.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/wp.pe.api.legacy.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/wp.base.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/wp.pe.rt.api.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/ccpp-1_0.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/wp.engine.impl.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/AppServer/webcontainer.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/wp.pe.api.standard.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/junit.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/PortalServer/commons-collections-3.0.jar"/> <classpathentry kind="lib" path="/WebSphereLibraries/build/AppServer/dynacache.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/commons- codec-1.3.jar"/> <classpathentry kind="lib" path="/Libraries/wps-root/shared/app/commons- httpclient-3.0-rc4.jar"/> <classpathentry kind="output" path="bin"/> </classpath> and my pom.xml ... : <?xml version="1.0" encoding="UTF-8"?><project> <modelVersion>4.0.0</modelVersion> <groupId>xxx</groupId> <artifactId>xxx</artifactId> <version>0.0.1</version> <description></description> <build> <sourceDirectory>Java Source</sourceDirectory> <scriptSourceDirectory>Java Source/scripts</scriptSourceDirectory> <testSourceDirectory>Test Source</testSourceDirectory> <outputDirectory>bin</outputDirectory> <testOutputDirectory>test-bin</testOutputDirectory> <resources> <resource> <directory>Resources</directory> </resource> </resources> <testResources> <testResource> <directory>Test Resources</directory> </testResource> </testResources> <directory>Target</directory> <finalName>${artifactId}-${version}</finalName> </build> <dependencies> <dependency> <groupId>ibm.rad.runtimes.base_v5_stub</groupId> <artifactId>webcontainer</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>ibm.rad.eclipse.jre</groupId> <artifactId>core</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>ibm.rad.runtimes.base_v5_stub</groupId> <artifactId>j2ee</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.AppServer</groupId> <artifactId>dynacache</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.AppServer</groupId> <artifactId>webcontainer</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>DocEditor</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>ccpp</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>commons-collections</artifactId> <version>3.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>wp.base</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>wp.engine.impl</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>wp.pe.api.legacy</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>wp.pe.api.standard</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>WebSphereLibraries.build.PortalServer</groupId> <artifactId>wp.pe.rt.api</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>calypso-core-services</artifactId> <version>1.6.1</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>calypso-dbms</artifactId> <version>1.6.1</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>calypso-utils</artifactId> <version>1.6.1</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>commons-beanutils</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>commons-codec</artifactId> <version>1.3</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>commons-digester</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>commons-httpclient</artifactId> <version>3.0-rc4</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>commons-lang</artifactId> <version>2.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>commons-logging</artifactId> <version>1.0.3</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>graphics</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>htmlparser</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>jcifs</artifactId> <version>0.6.8</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>jcs</artifactId> <version>1.0</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>jlog</artifactId> <version>2.2.1</version> </dependency> <dependency> <groupId>wps-root.shared.app</groupId> <artifactId>junit</artifactId> <version>1.0</version> </dependency> </dependencies> <reporting> <outputDirectory>Target/site</outputDirectory> </reporting> </project> When i remove all the project dependencies in Eclipse and i add the "Maven Dependencies" (its a plugin), it build without error. So it's not a dependency problem ? Please help me, thanks ! sid
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
