[ ant-contrib-Bugs-1626443 ] Missing includepath type definition needed with ant 1.7.0

"SourceForge.net" <[email protected]> Wed, 17 Oct 2007 14:22:26 -0700
Newsgroups gmane.comp.java.ant-contrib.devel
Message-ID <[email protected]>
Bugs item #1626443, was opened at 2007-01-02 10:35
Message generated for change (Comment added) made by pickgr
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=416920&aid=1626443&group_id=36177

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: cpptasks
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Mathieu Champlon (mat007)
Assigned to: Curt Arnold (carnold)
Summary: Missing includepath type definition needed with ant 1.7.0

Initial Comment:

Hello,

The following build.xml file used to be valid with ant 1.6.5 :
<project>
  <taskdef resource="net/sf/antcontrib/cpptasks/antlib.xml"/>
  <includepath id="my-id"/>
</project>
(the cpptasks jar must be in the ant lib/ directory)

With ant 1.7.0 it generates the following error :
build.xml:3: Problem: failed to create task or type includepath
Cause: The name is undefined.

Adding one line to cpptasks.types solves the issue :
includepath=net.sf.antcontrib.cpptasks.types.IncludePath

MAT.

----------------------------------------------------------------------

Comment By: Garret Pick (pickgr)
Date: 2007-10-17 11:22

Message:
Logged In: YES 
user_id=1111186
Originator: NO

Hi,

I just ran into this problem when I upgrade to ant 1.7.0 also.  I tried
the work-around of adding the includepath line to the cpptasks.types file,
and like DD, this did not seem to fix my problem at first.

Then I re-read mat007's post more carefully and there is actually a second
change he made in the build file itself:

<path id="my-id"/>

to

<includepath id="my-id"/>

Once I did this everything started working!  Thanks for the work-around
and perhaps this will help clarify the work-around for others too.

- Garret

----------------------------------------------------------------------

Comment By: Mathieu Champlon (mat007)
Date: 2007-06-29 12:07

Message:
Logged In: YES 
user_id=71590
Originator: YES

Hello,

I don't known why it doesn't seem to work for you.
Here is the content of my cpptasks.types file for reference :

defineset=net.sf.antcontrib.cpptasks.types.DefineSet
compiler=net.sf.antcontrib.cpptasks.CompilerDef
linker=net.sf.antcontrib.cpptasks.LinkerDef
targetplatform=net.sf.antcontrib.cpptasks.TargetDef
versioninfo=net.sf.antcontrib.cpptasks.VersionInfo
distributer=net.sf.antcontrib.cpptasks.DistributerDef
syslibset=net.sf.antcontrib.cpptasks.types.SystemLibrarySet
libset=net.sf.antcontrib.cpptasks.types.LibrarySet
includepath=net.sf.antcontrib.cpptasks.types.IncludePath

Are your sure the cpptasks.jar file picked by ant is the patched one ?
Did you try and uncompress the .jar to check the cpptask.types file ?

MAT.

----------------------------------------------------------------------

Comment By: DanDevine (dandevine)
Date: 2007-06-21 12:44

Message:
Logged In: YES 
user_id=1779317
Originator: NO

Added "includepath=net.sf.antcontrib.cpptasks.types.IncludePath" to the
file cpptasks.types and recompiled.

After recompile, I added this to my apache-ant-1.7.0\lib directory and
reran my build script.

Still no difference, still error.

Am I missing something?

Thanks,
DD

----------------------------------------------------------------------

Comment By: DanDevine (dandevine)
Date: 2007-06-21 08:09

Message:
Logged In: YES 
user_id=1779317
Originator: NO

I think I may be getting something similar....

Snip from build.xml that works under 1.6.5 but broken in 1.7.0

    <path id="public_include">
        <pathelement path="${basedir}/public"/>
    </path>

	
    <path id="private_include">
	<pathelement path="${basedir}/inc"/>
	<pathelement path="${basedir}/util"/>
    </path>


    <target name="build_core" description="Builds the Discovery Tool
library (tdtlib)">
        <echo message="Building tdtlib"/>
        <mkdir dir="${build_dir}/tdtlib"/>
        <cc name="${compiler}" debug="${debug}" link="static"
objdir="${build_dir}/tdtlib"
            optimize="${optimize_level}"
outfile="${build_dir}/tdtlib/tdt">
            <compilerarg value="-ftest-coverage" if="define_gcov"/>
            <compilerarg value="-fprofile-arcs" if="define_gcov"/>
            <compilerarg value="${debug_level}" if="define_debug"/>
            <defineset define="_DEBUG" if="define_debug"/>

            <fileset refid="core_source"/>
            <fileset refid="util_source"/>
            <includepath refid="public_include"/>
            <includepath refid="private_include"/>
       </cc>
              
    </target>


Build fails with "public_include doesn't denote a IncludePath"....

After changing the above <path> elements for "public_include" and
"private_include" to <includepath>, I receive the error listed above.

Again, the <path> elements worked alright with the ccTask <includepath>
input under 1.6.5 but broken in 1.7.0

DD

----------------------------------------------------------------------

Comment By: Mathieu Champlon (mat007)
Date: 2007-01-02 22:32

Message:
Logged In: YES 
user_id=71590
Originator: YES

Oups sorry I mixed up my test build files...

Actually the code that use to be valid with ant 1.6.5 and isn't anymore
with ant 1.7.0 is :
<project>
<taskdef resource="net/sf/antcontrib/cpptasks/antlib.xml"/>
<path id="my-id"/>
<cc>
  <includepath refid="my-id"/>
</cc>
</project>

Now with ant 1.7.0 the error is : build.xml:11: my-id doesn't denote a
includepath
Adding the type definition makes it possible to declare :
<includepath id="my-id"/>


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=416920&aid=1626443&group_id=36177

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/