ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 5291] New: - taskdef not finding ProjectComponent class
Date Wed, 05 Dec 2001 20:44:34 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=5291>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=5291

taskdef not finding ProjectComponent class

           Summary: taskdef not finding ProjectComponent class
           Product: Ant
           Version: 1.3
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: Blocker
          Priority: Other
         Component: Core tasks
        AssignedTo: ant-dev@jakarta.apache.org
        ReportedBy: bwnations@fedex.com


I've been trying to set up an ant task to check my java source code for
adherence to coding standards using the 'checkstyle' product
(http://checkstyle.sourceforge.net).  

Everytime that I run ant against my build file, I get a class not found error
for the class, 'org.apache.tools.ant.ProjectComponent'.  I'm running this on a
RedHat Linux 7.1 PC with JDK1.3.1, but I get the same exact results on a Sun
Solaris 2.6 with JDK1.2.2.

I've grepped through the ant and the checkstyle .java files for
'ProjectComponent' with no luck.  None of them seem to have it.

any ideas?

Here's the output when running ant -debug
=========================================
Buildfile: build.xml
Setting project property: ant.java.version -> 1.3
Detected Java Version: 1.3
Detected OS: Linux
 +User task: tar     org.apache.tools.ant.taskdefs.Tar
 +User task: fail     org.apache.tools.ant.taskdefs.Exit
 +User task: uptodate     org.apache.tools.ant.taskdefs.UpToDate
 +User task: java     org.apache.tools.ant.taskdefs.Java
 +User task: execon     org.apache.tools.ant.taskdefs.ExecuteOn
 +User task: echo     org.apache.tools.ant.taskdefs.Echo
 +User task: native2ascii    
org.apache.tools.ant.taskdefs.optional.Native2Ascii
 +User task: jjtree     org.apache.tools.ant.taskdefs.optional.javacc.JJTree
 +User task: compileTask     org.apache.tools.ant.taskdefs.CompileTask
 +User task: chmod     org.apache.tools.ant.taskdefs.Chmod
 +User task: javadoc2     org.apache.tools.ant.taskdefs.Javadoc
 +User task: deltree     org.apache.tools.ant.taskdefs.Deltree
 +User task: cvs     org.apache.tools.ant.taskdefs.Cvs
 +User task: jlink     org.apache.tools.ant.taskdefs.optional.jlink.JlinkTask
 +User task: tstamp     org.apache.tools.ant.taskdefs.Tstamp
 +User task: unjar     org.apache.tools.ant.taskdefs.Expand
 +User task: patch     org.apache.tools.ant.taskdefs.Patch
 +User task: sound     org.apache.tools.ant.taskdefs.optional.sound.SoundTask
 +User task: cccheckout    
org.apache.tools.ant.taskdefs.optional.clearcase.CCCheckout
 +User task: mail     org.apache.tools.ant.taskdefs.SendEmail
 +User task: gzip     org.apache.tools.ant.taskdefs.GZip
 +User task: wlrun     org.apache.tools.ant.taskdefs.optional.ejb.WLRun
 +User task: copy     org.apache.tools.ant.taskdefs.Copy
 +User task: filter     org.apache.tools.ant.taskdefs.Filter
 +User task: jar     org.apache.tools.ant.taskdefs.Jar
 +User task: unzip     org.apache.tools.ant.taskdefs.Expand
 +User task: rename     org.apache.tools.ant.taskdefs.Rename
 +User task: propertyfile    
org.apache.tools.ant.taskdefs.optional.PropertyFile
 +User task: copyfile     org.apache.tools.ant.taskdefs.Copyfile
 +User task: gunzip     org.apache.tools.ant.taskdefs.GUnzip
 +User task: antcall     org.apache.tools.ant.taskdefs.CallTarget
 +User task: taskdef     org.apache.tools.ant.taskdefs.Taskdef
 +User task: mkdir     org.apache.tools.ant.taskdefs.Mkdir
 +User task: sql     org.apache.tools.ant.taskdefs.SQLExec
 +User task: replace     org.apache.tools.ant.taskdefs.Replace
 +User task: ant     org.apache.tools.ant.taskdefs.Ant
 +User task: style     org.apache.tools.ant.taskdefs.XSLTProcess
 +User task: fixcrlf     org.apache.tools.ant.taskdefs.FixCRLF
 +User task: vssget     org.apache.tools.ant.taskdefs.optional.vss.MSVSSGET
 +User task: genkey     org.apache.tools.ant.taskdefs.GenerateKey
 +User task: zip     org.apache.tools.ant.taskdefs.Zip
 +User task: antstructure     org.apache.tools.ant.taskdefs.AntStructure
 +User task: javah     org.apache.tools.ant.taskdefs.optional.Javah
 +User task: javac     org.apache.tools.ant.taskdefs.Javac
 +User task: test     org.apache.tools.ant.taskdefs.optional.Test
 +User task: cab     org.apache.tools.ant.taskdefs.optional.Cab
 +User task: mparse     org.apache.tools.ant.taskdefs.optional.metamata.MParse
 +User task: ccuncheckout    
org.apache.tools.ant.taskdefs.optional.clearcase.CCUnCheckout
 +User task: ejbjar     org.apache.tools.ant.taskdefs.optional.ejb.EjbJar
 +User task: available     org.apache.tools.ant.taskdefs.Available
 +User task: vsslabel     org.apache.tools.ant.taskdefs.optional.vss.MSVSSLABEL
 +User task: wljspc     org.apache.tools.ant.taskdefs.optional.jsp.WLJspc
 +User task: move     org.apache.tools.ant.taskdefs.Move
 +User task: csc     org.apache.tools.ant.taskdefs.optional.dotnet.CSharp
 +User task: signjar     org.apache.tools.ant.taskdefs.SignJar
 +User task: javacc     org.apache.tools.ant.taskdefs.optional.javacc.JavaCC
 +User task: cccheckin    
org.apache.tools.ant.taskdefs.optional.clearcase.CCCheckin
 +User task: property     org.apache.tools.ant.taskdefs.Property
 +User task: unwar     org.apache.tools.ant.taskdefs.Expand
 +User task: touch     org.apache.tools.ant.taskdefs.Touch
 +User task: ilasm     org.apache.tools.ant.taskdefs.optional.dotnet.Ilasm
 +User task: get     org.apache.tools.ant.taskdefs.Get
 +User task: javadoc     org.apache.tools.ant.taskdefs.Javadoc
 +User task: antlr     org.apache.tools.ant.taskdefs.optional.ANTLR
 +User task: untar     org.apache.tools.ant.taskdefs.Untar
 +User task: delete     org.apache.tools.ant.taskdefs.Delete
 +User task: ejbc     org.apache.tools.ant.taskdefs.optional.ejb.Ejbc
 +User task: copydir     org.apache.tools.ant.taskdefs.Copydir
 +User task: war     org.apache.tools.ant.taskdefs.War
 +User task: ccupdate    
org.apache.tools.ant.taskdefs.optional.clearcase.CCUpdate
 +User task: depend     org.apache.tools.ant.taskdefs.optional.depend.Depend
 +User task: renameext    
org.apache.tools.ant.taskdefs.optional.RenameExtensions
 +User task: exec     org.apache.tools.ant.taskdefs.ExecTask
 +User task: apply     org.apache.tools.ant.taskdefs.Transform
 +User task: wlstop     org.apache.tools.ant.taskdefs.optional.ejb.WLStop
 +User task: rmic     org.apache.tools.ant.taskdefs.Rmic
 +User datatype: fileset     org.apache.tools.ant.types.FileSet
 +User datatype: patternset     org.apache.tools.ant.types.PatternSet
 +User datatype: path     org.apache.tools.ant.types.Path
 +User datatype: mapper     org.apache.tools.ant.types.Mapper
Setting project property: java.runtime.name -> Java(TM) 2 Runtime Environment,
Standard Edition
Setting project property: sun.boot.library.path ->
/usr/local/software/java/jdk1.3.1_01/jre/lib/i386
Setting project property: java.vm.version -> 1.3.1_01
Setting project property: java.vm.vendor -> Sun Microsystems Inc.
Setting project property: java.vendor.url -> http://java.sun.com/
Setting project property: path.separator -> :
Setting project property: java.vm.name -> Java HotSpot(TM) Client VM
Setting project property: file.encoding.pkg -> sun.io
Setting project property: java.vm.specification.name -> Java Virtual Machine
Specification
Setting project property: user.dir -> /home/bn388572/temp/broken_ant
Setting project property: java.runtime.version -> 1.3.1_01
Setting project property: java.awt.graphicsenv -> sun.awt.X11GraphicsEnvironment
Setting project property: os.arch -> i386
Setting project property: java.io.tmpdir -> /tmp
Setting project property: line.separator -> 

Setting project property: java.vm.specification.vendor -> Sun Microsystems Inc.
Setting project property: java.awt.fonts -> 
Setting project property: os.name -> Linux
Setting project property: ant.home -> /home/bn388572/sandbox/ant/bin/..
Setting project property: java.library.path ->
/usr/local/software/java/jdk1.3.1_01/jre/lib/i386:/usr/local/software/java/jdk1.3.1_01/jre/lib/i386/native_threads/:/usr/local/software/java/jdk1.3.1_01/jre/lib/i386/client:/usr/local/software/java/jdk1.3.1_01/jre/../lib/i386::/usr/local/lib:/usr/local/lib
Setting project property: java.specification.name -> Java Platform API
Specification
Setting project property: java.class.version -> 47.0
Setting project property: os.version -> 2.4.2-2
Setting project property: user.home -> /home/bn388572
Setting project property: user.timezone -> 
Setting project property: java.awt.printerjob -> sun.awt.motif.PSPrinterJob
Setting project property: file.encoding -> ISO-8859-1
Setting project property: java.specification.version -> 1.3
Setting project property: java.class.path ->
:/home/bn388572/sandbox/webmacro/webmacro.jar:/home/bn388572/sandbox/ant/lib/ant.jar:/home/bn388572/sandbox/ant/lib/optional/optional.jar:/home/bn388572/sandbox/junit/junit.jar:/home/bn388572/sandbox/httpunit/lib/httpunit.jar:/home/bn388572/sandbox/httpunit/lib/Tidy.jar:/usr/local/software/java/j2sdkee1.3/lib/j2ee.jar:/opt/bea/wls6.1/lib/weblogic.jar:/home/bn388572/sandbox/grems/src/lib/log4j.jar:/home/bn388572/sandbox/gps/src:/home/bn388572/sandbox/grems/src:/home/bn388572/sandbox/webmacro/webmacro.jar:/home/bn388572/sandbox/ant/lib/ant.jar:/home/bn388572/sandbox/ant/lib/optional/optional.jar:/home/bn388572/sandbox/junit/junit.jar:/home/bn388572/sandbox/httpunit/lib/httpunit.jar:/home/bn388572/sandbox/httpunit/lib/Tidy.jar:/usr/local/software/java/j2sdkee1.3/lib/j2ee.jar:/opt/bea/wls6.1/lib/weblogic.jar:/home/bn388572/sandbox/grems/src/lib/log4j.jar:/home/bn388572/sandbox/gps/src:/home/bn388572/sandbox/grems/src::/home/bn388572/sandbox/ant/bin/../lib/ant.jar:/home/bn388572/sandbox/ant/bin/../lib/jaxp.jar:/home/bn388572/sandbox/ant/bin/../lib/parser.jar:/usr/local/software/java/jdk1.3.1_01//lib/tools.jar
Setting project property: user.name -> bn388572
Setting project property: java.vm.specification.version -> 1.0
Setting project property: java.home -> /usr/local/software/java/jdk1.3.1_01/jre
Setting project property: user.language -> en
Setting project property: java.specification.vendor -> Sun Microsystems Inc.
Setting project property: java.vm.info -> mixed mode
Setting project property: java.version -> 1.3.1_01
Setting project property: java.ext.dirs ->
/usr/local/software/java/jdk1.3.1_01/jre/lib/ext
Setting project property: sun.boot.class.path ->
/usr/local/software/java/jdk1.3.1_01/jre/lib/rt.jar:/usr/local/software/java/jdk1.3.1_01/jre/lib/i18n.jar:/usr/local/software/java/jdk1.3.1_01/jre/lib/sunrsasign.jar:/usr/local/software/java/jdk1.3.1_01/jre/classes
Setting project property: java.vendor -> Sun Microsystems Inc.
Setting project property: file.separator -> /
Setting project property: java.vendor.url.bug ->
http://java.sun.com/cgi-bin/bugreport.cgi
Setting project property: sun.io.unicode.encoding -> UnicodeLittle
Setting project property: sun.cpu.endian -> little
Setting project property: user.region -> US
Setting project property: sun.cpu.isalist -> 
Setting ro project property: ant.file ->
/home/bn388572/temp/broken_ant/build.xml
parsing buildfile /home/bn388572/temp/broken_ant/build.xml with URI =
file:/home/bn388572/temp/broken_ant/build.xml
Setting ro project property: ant.project.name -> testAnt
Setting project property: basedir -> /home/bn388572/temp/broken_ant
Project base dir set to: /home/bn388572/temp/broken_ant
 +Target: checkStyle
   +Task: taskdef
Build sequence for target `checkStyle' is [checkStyle]
Complete build sequence is [checkStyle]

checkStyle:
Finding class com.puppycrawl.tools.checkstyle.CheckStyleTask
Class org.apache.tools.ant.Task loaded from system loader
Class com.puppycrawl.tools.checkstyle.CheckStyleTask loaded from ant loader
 +User task: checkstyle     com.puppycrawl.tools.checkstyle.CheckStyleTask
Finding class org.apache.tools.ant.ProjectComponent

BUILD FAILED

/home/bn388572/temp/broken_ant/build.xml:15: Could not create task of type:
checkstyle due to java.lang.NoClassDefFoundError:
org/apache/tools/ant/ProjectComponent
--- Nested Exception ---
java.lang.NoClassDefFoundError: org/apache/tools/ant/ProjectComponent
        at java.lang.Class.newInstance0(Native Method)
        at java.lang.Class.newInstance(Class.java:237)
        at org.apache.tools.ant.Project.createTask(Project.java:439)
        at
org.apache.tools.ant.UnknownElement.maybeConfigure(UnknownElement.java:83)
        at org.apache.tools.ant.Target.execute(Target.java:152)
        at org.apache.tools.ant.Project.runTarget(Project.java:898)
        at org.apache.tools.ant.Project.executeTarget(Project.java:536)
        at org.apache.tools.ant.Project.executeTargets(Project.java:510)
        at org.apache.tools.ant.Main.runBuild(Main.java:421)
        at org.apache.tools.ant.Main.main(Main.java:149)

Total time: 1 second


Here's the buildfile
====================
<?xml version="1.0" encoding="iso-8859-1"?>
<project name="testAnt" default="checkStyle" basedir=".">
    <target name="checkStyle">
        <!-- Java Style checker from http://checkstyle.sourceforge.net -->   
        <taskdef name="checkstyle"
            classpath="./checkstyle-all-1.3.jar"
            classname="com.puppycrawl.tools.checkstyle.CheckStyleTask" />
        <checkstyle file="./Security.java"/>
    </target>
</project>     
     
Here's the Security.java file
=============================
// -----------------------------------------------------------------------
//
//    Copyright (c) FEDERAL EXPRESS CORPORATION 2001
//    This document contains information proprietary and
//    confidential to Federal Express Corporation and may
//    not be copied or reproduced without permission.
//
// -----------------------------------------------------------------------
//
//    $Id: Security.java,v 1.2 2001/12/05 00:03:41 bn388572 Exp $
//
// NOTES:
//
//    Remote interface of security bean
//
//
// OWNER:
//
//    LHSD-CSSD Properties and Facilities Group
//
// -----------------------------------------------------------------------

package com.fedex.properties.grems.ejb;

import java.rmi.RemoteException;
import java.util.Vector;
import javax.ejb.EJBObject;

/**
 *  This EJB is responsible for handling the login of users.
 *  
 *  @author  $Author: bn388572 $
 *  @version $Revision: 1.2 $
 */
public interface Security extends EJBObject
{
    /**
     *  Checks to see that the session id is still valid.  That is,
     *  the user is still logged in on the Eureka Portal server
     *
     *  @param sessionId  The session id associated with this user.
     *  @return <code>true</code> if the session is still good
     *          <code>false</code> otherwise
     *  @throws RemoteException Standard EJB fair
     */
    public boolean isLoggedIn( String sessionId )
    throws RemoteException;

    /**
     *  Checks the user's name and password for validity and returns
     *  any session id's associated with the user.  If there are no
     *  current sessions for this user, and the password is correct,
     *  then it creates a session.
     *
     *  @param username The user's account name
     *  @param password The user's account password
     *  @return A list of valid session id's for this user.
     *  @throws RemoteException Standard EJB fair
     */
    public Vector logIn( String username, String password )
    throws RemoteException;

    /**
     *  Retrieves the user's business group affiliation.  For example. 
     *  MIS, Contract Administrator or Real Estate.
     *
     *  @param username The user's account name
     *  @return A list of valid session id's for this user.
     *  @throws RemoteException Standard EJB fair
     */
    public String getUserGroup( String username )
    throws RemoteException;
}

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message