Jul 27, 2016

Could not load definitions from resource net/sf/antcontrib/antcontrib.properties

error

When click on build.xml and running ant build. Getting following error :
[taskdef] Could not load definitions from resource net/sf/antcontrib/antcontrib.properties. It could not be found.

APPLIES TO:

Oracle Commerce Platform - Version 9.4 and later
Information in this document applies to any platform.

Solution

Please follow the steps below to get rid of above issue.
Important steps to be followed and are mandatory.

  1. Install ANT on to your machine drive.
  2. Make sure class path for ant is set to ANT_HOME
  3. In lib folder of ANT_HOME copy jar file names "ant-contrib-0.6".
  4. In build.xml at line number <exact line number> where it say's "
    <taskdef resource="net/sf/antcontrib/antcontrib.properties">
    <classpath>
    <pathelement location="" /> <taskdef>
  5. Give correct location of jar files. e.g "C:\apache-ant-1.8.4\lib\ant-contrib-0.6.jar".
  6. Try running ANT build again.

No comments: