(Optional) Configure the org.dita.pdf2 plug-in

If you plan to use the org.dita.pdf2 plug-in, you must configure it to replace all the references to the xml.catalog.files Ant property with the full path to the catalogs.

See Working with the DITA Open Toolkit for more information.

  1. Make a backup copy of the %OutputGenDir%/data/%NewOT_Dir%/plugins/org.dita.pdf2/build_template.xml file.
    This ensures that you can revert to a working copy if you get errors compiling the updated build_template.xml file.
  2. Open the %OutputGenDir%/data/%NewOT_Dir%/plugins/org.dita.pdf2/build_template.xml file with a text editor.
  3. Comment out the following line:
    <property name="xml.catalog.files" value="${customization.dir}/catalog.xml;${dita.plugin.org.dita.pdf2.dir}/ cfg/catalog.xml;${dita.dir}/catalog-dita.xml"/>
    For example:
    <!-- Please comment out this property as it can break builds when using more than one customization directory -->
    <!-- <property name="xml.catalog.files" value="${customization.dir}/catalog.xml;${dita.plugin.org.dita.pdf2.dir}/ cfg/catalog.xml;${dita.dir}/catalog-dita.xml"/> -->
  4. Search for all instances of the following string:
    ${xml.catalog.files}
    And replace them with the following:
    ${customization.dir}/catalog.xml;${dita.plugin.org.dita.pdf2.dir}/cfg/catalog.xml;
    ${dita.dir}/catalog-dita.xml
    Note: Make sure to put the string above on a single line.
    For example, change the following lines:
    <index-preprocess input="${inputFile.url}" 
       output="${dita.temp.dir}/stage1.xml"
       indexConfig="${index.config.file}" locale="${document.locale}"
       catalogs="${xml.catalog.files}"/> 
    To:
    <index-preprocess input="${inputFile.url}" 
       output="${dita.temp.dir}/stage1.xml"
       indexConfig="${index.config.file}" locale="${document.locale}"
       catalogs="${customization.dir}/catalog.xml;${dita.plugin.org.dita.pdf2.dir}
    /cfg/catalog.xml;${dita.dir}/catalog-dita.xml"/> 
    There should be at least five occurrences of this string.
  5. Save and close build_template.xml.
  6. In the %OutputGenDir%/data/%NewOT_Dir%/ directory, double-click startcmd.bat (Windows) or run startcmd.sh (Linux).
  7. At the command prompt, enter:
    ant -f integrator.xml
    The integration build runs and you should soon see BUILD SUCCESSFUL.
    Note: If a message similar to the following is displayed, you can safely ignore it:
    Unable to locate tools.jar. Expected to find it in C:\Program Files\Java\jre6\lib\tools.jar
  8. Close the command window.