[dd5bdf3] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[ff769b8c] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
[dd5bdf3] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[0aeb696] | 7 | <!-- Inserted as a reminder to do this. The mention of a test suite
|
---|
| 8 | is usually right before the root user installation commands. Please
|
---|
| 9 | delete these 12 (including one blank) lines after you are done.-->
|
---|
| 10 |
|
---|
| 11 | <!-- Use one of the two mentions below about a test suite,
|
---|
| 12 | delete the line that is not applicable. Of course, if the
|
---|
| 13 | test suite uses syntax other than "make check", revise the
|
---|
| 14 | line to reflect the actual syntax to run the test suite -->
|
---|
| 15 |
|
---|
| 16 | <!-- <para>This package does not come with a test suite.</para> -->
|
---|
| 17 | <!-- <para>To test the results, issue: <command>make check</command>.</para> -->
|
---|
| 18 |
|
---|
[8bfb60e] | 19 | <!ENTITY apache-ant-download-http "http://archive.apache.org/dist/ant/source/apache-ant-&apache-ant-version;-src.tar.bz2">
|
---|
[dd5bdf3] | 20 | <!ENTITY apache-ant-download-ftp "ftp://ftp.oregonstate.edu/pub/apache/ant/source/apache-ant-&apache-ant-version;-src.tar.bz2">
|
---|
[baba58bc] | 21 | <!ENTITY apache-ant-md5sum "80a7ad191c40b7d8c82533524b282b6b">
|
---|
[dd5bdf3] | 22 | <!ENTITY apache-ant-size "6.2 MB">
|
---|
[baba58bc] | 23 | <!ENTITY apache-ant-buildsize "94.5 MB">
|
---|
| 24 | <!ENTITY apache-ant-time "0.4 SBU">
|
---|
[dd5bdf3] | 25 | ]>
|
---|
| 26 |
|
---|
| 27 | <sect1 id="apache-ant" xreflabel="Apache Ant-&apache-ant-version;">
|
---|
[514ef84d] | 28 | <?dbhtml filename="apache-ant.html"?>
|
---|
| 29 |
|
---|
| 30 | <sect1info>
|
---|
| 31 | <othername>$LastChangedBy$</othername>
|
---|
| 32 | <date>$Date$</date>
|
---|
[56762b82] | 33 | <keywordset>
|
---|
| 34 | <keyword role="package">apache-ant-&apache-ant-version;-src.tar</keyword>
|
---|
[22ac237] | 35 | <keyword role="ftpdir">apache-ant</keyword>
|
---|
[56762b82] | 36 | </keywordset>
|
---|
[514ef84d] | 37 | </sect1info>
|
---|
| 38 |
|
---|
| 39 | <title>Apache Ant-&apache-ant-version;</title>
|
---|
| 40 |
|
---|
| 41 | <indexterm zone="apache-ant">
|
---|
| 42 | <primary sortas="a-Apache-Ant">Apache Ant</primary>
|
---|
| 43 | </indexterm>
|
---|
| 44 |
|
---|
| 45 | <sect2 role="package">
|
---|
| 46 | <title>Introduction to Apache Ant</title>
|
---|
| 47 |
|
---|
[539ace5] | 48 | <para>The <application>Apache Ant</application> package is a
|
---|
| 49 | <application>Java</application>-based build tool. In theory, it is kind of like
|
---|
| 50 | <command>make</command>, but without <command>make</command>'s wrinkles.
|
---|
| 51 | Ant is different. Instead of a model where it is extended with shell-based commands,
|
---|
| 52 | Ant is extended using <application>Java</application> classes. Instead of writing
|
---|
| 53 | shell commands, the configuration files are XML-based, calling out a target tree where
|
---|
| 54 | various tasks get executed. Each task is run by an object that implements a
|
---|
[514ef84d] | 55 | particular task interface.</para>
|
---|
| 56 |
|
---|
| 57 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 58 | <itemizedlist spacing="compact">
|
---|
| 59 | <listitem>
|
---|
| 60 | <para>Download (HTTP): <ulink url="&apache-ant-download-http;"/></para>
|
---|
| 61 | </listitem>
|
---|
| 62 | <listitem>
|
---|
| 63 | <para>Download (FTP): <ulink url="&apache-ant-download-ftp;"/></para>
|
---|
| 64 | </listitem>
|
---|
| 65 | <listitem>
|
---|
| 66 | <para>Download MD5 sum: &apache-ant-md5sum;</para>
|
---|
| 67 | </listitem>
|
---|
| 68 | <listitem>
|
---|
| 69 | <para>Download size: &apache-ant-size;</para>
|
---|
| 70 | </listitem>
|
---|
| 71 | <listitem>
|
---|
| 72 | <para>Estimated disk space required: &apache-ant-buildsize;</para>
|
---|
| 73 | </listitem>
|
---|
| 74 | <listitem>
|
---|
| 75 | <para>Estimated build time: &apache-ant-time;</para>
|
---|
| 76 | </listitem>
|
---|
| 77 | </itemizedlist>
|
---|
| 78 |
|
---|
| 79 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
| 80 | <itemizedlist spacing="compact">
|
---|
| 81 | <listitem>
|
---|
[539ace5] | 82 | <para>Required Patch: <ulink
|
---|
[514ef84d] | 83 | url="&patch-root;/apache-ant-&apache-ant-version;-blfs_install-1.patch"/></para>
|
---|
| 84 | </listitem>
|
---|
| 85 | </itemizedlist>
|
---|
| 86 |
|
---|
| 87 | <bridgehead renderas="sect3">Apache Ant Dependencies</bridgehead>
|
---|
| 88 |
|
---|
| 89 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[56762b82] | 90 | <para role="required"><xref linkend="jdk"/></para>
|
---|
[514ef84d] | 91 |
|
---|
[1039de3] | 92 | <para condition="html" role="usernotes">User Notes:
|
---|
| 93 | <ulink url="&blfs-wiki;/apache-ant"/></para>
|
---|
| 94 |
|
---|
[514ef84d] | 95 | </sect2>
|
---|
| 96 |
|
---|
| 97 | <sect2 role="installation">
|
---|
| 98 | <title>Installation of Apache Ant</title>
|
---|
| 99 |
|
---|
| 100 | <note>
|
---|
[919683dc] | 101 | <para>You may need additional libraries to satisfy the build
|
---|
[539ace5] | 102 | requirements of various packages installed using
|
---|
| 103 | <application>Apache Ant</application>. Review the table at
|
---|
[0619e6d] | 104 | <ulink url="http://ant.apache.org/manual/install.html#librarydependencies"/>
|
---|
[539ace5] | 105 | for any prerequisite libraries you may need. One such library is the
|
---|
| 106 | <application>JUnit</application> testing framework library. Many Ant-installed
|
---|
| 107 | packages will use this library to perform the unit tests during the build
|
---|
| 108 | process. To install the JUnit library along with the
|
---|
| 109 | <application>Apache Ant</application> package, download it from
|
---|
| 110 | <ulink url="http://www.junit.org/"/>, unzip the distribution file (requires
|
---|
[514ef84d] | 111 | <xref linkend="unzip"/>) and copy the <filename>junit.jar</filename> file
|
---|
| 112 | into the <filename class='directory'>lib</filename> subdirectory of the
|
---|
[539ace5] | 113 | <application>Apache Ant</application> source tree before beginning the
|
---|
[514ef84d] | 114 | <application>Apache Ant</application> build.</para>
|
---|
| 115 | </note>
|
---|
| 116 |
|
---|
[539ace5] | 117 | <para>Install <application>Apache Ant</application> by running the following
|
---|
[514ef84d] | 118 | commands:</para>
|
---|
| 119 |
|
---|
| 120 | <screen><userinput>patch -Np1 -i ../apache-ant-&apache-ant-version;-blfs_install-1.patch</userinput></screen>
|
---|
| 121 |
|
---|
| 122 | <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
---|
| 123 |
|
---|
| 124 | <screen role="root"><userinput>./build.sh -Ddist.dir=/opt/ant-&apache-ant-version; dist &&
|
---|
| 125 | ln -v -sf /etc/ant /opt/ant-&apache-ant-version;/etc &&
|
---|
| 126 | ln -v -sf ant-&apache-ant-version; /opt/ant</userinput></screen>
|
---|
| 127 |
|
---|
| 128 | </sect2>
|
---|
| 129 |
|
---|
| 130 | <sect2 role="commands">
|
---|
| 131 | <title>Command Explanations</title>
|
---|
| 132 |
|
---|
[539ace5] | 133 | <para><command>./build.sh -Ddist.dir=/opt/ant-&apache-ant-version;
|
---|
[baba58bc] | 134 | dist</command>: This command does everything. It builds, then
|
---|
[539ace5] | 135 | installs the package into
|
---|
[514ef84d] | 136 | <filename class='directory'>/opt/ant-&apache-ant-version;</filename>.</para>
|
---|
| 137 |
|
---|
[539ace5] | 138 | <para><command>ln -v -sf /etc/ant /opt/ant-&apache-ant-version;/etc</command>:
|
---|
| 139 | The patch changes the configuration directory to
|
---|
| 140 | <filename class='directory'>/etc/ant</filename> to conform with
|
---|
| 141 | FHS guidelines. This command creates a symlink from the
|
---|
| 142 | configuration directory back to the installation directory as the package is
|
---|
[514ef84d] | 143 | expecting to find the files there.</para>
|
---|
| 144 |
|
---|
[539ace5] | 145 | <para><command>ln -v -sf ant-&apache-ant-version; /opt/ant</command>: This
|
---|
[514ef84d] | 146 | command is optional, and creates a convenience symlink.</para>
|
---|
| 147 |
|
---|
| 148 | </sect2>
|
---|
| 149 |
|
---|
| 150 | <sect2 role="configuration">
|
---|
| 151 | <title>Configuring Apache Ant</title>
|
---|
| 152 |
|
---|
| 153 | <sect3 id="apache-ant-config">
|
---|
[30edc031] | 154 | <title>Config Files</title>
|
---|
[514ef84d] | 155 |
|
---|
[539ace5] | 156 | <para><filename>/etc/ant/ant.conf</filename>,
|
---|
| 157 | <filename>~/.ant/ant.conf</filename>, and
|
---|
[514ef84d] | 158 | <filename>~/.antrc</filename></para>
|
---|
| 159 |
|
---|
| 160 | <indexterm zone="apache-ant apache-ant-config">
|
---|
| 161 | <primary sortas="e-AA.ant-ant.conf">~/.ant/ant.conf</primary>
|
---|
| 162 | </indexterm>
|
---|
| 163 |
|
---|
| 164 | <indexterm zone="apache-ant apache-ant-config">
|
---|
| 165 | <primary sortas="e-AA.antrc">~/.antrc</primary>
|
---|
| 166 | </indexterm>
|
---|
| 167 |
|
---|
| 168 | <indexterm zone="apache-ant apache-ant-config">
|
---|
| 169 | <primary sortas="e-etc-ant-ant.conf">/etc/ant/ant.conf</primary>
|
---|
| 170 | </indexterm>
|
---|
| 171 |
|
---|
| 172 | </sect3>
|
---|
| 173 |
|
---|
| 174 | <sect3>
|
---|
| 175 | <title>Configuration Information</title>
|
---|
| 176 |
|
---|
| 177 | <para>Some packages will require <command>ant</command> to be in the search
|
---|
[539ace5] | 178 | path and the <envar>$ANT_HOME</envar> environment variable defined.
|
---|
| 179 | Satisfy these requirements by adding the following lines to
|
---|
| 180 | <filename>/etc/profile</filename> or to individual user's
|
---|
[514ef84d] | 181 | <filename>~/.profile</filename> or <filename>~/.bashrc</filename> files:</para>
|
---|
| 182 |
|
---|
| 183 | <screen><literal>export PATH=$PATH:/opt/ant/bin
|
---|
| 184 | export ANT_HOME=/opt/ant</literal></screen>
|
---|
| 185 |
|
---|
| 186 | </sect3>
|
---|
| 187 |
|
---|
| 188 | </sect2>
|
---|
| 189 |
|
---|
| 190 | <sect2 role="content">
|
---|
| 191 | <title>Contents</title>
|
---|
| 192 |
|
---|
| 193 | <segmentedlist>
|
---|
| 194 | <segtitle>Installed Programs</segtitle>
|
---|
| 195 | <segtitle>Installed Libraries</segtitle>
|
---|
| 196 | <segtitle>Installed Directories</segtitle>
|
---|
| 197 |
|
---|
| 198 | <seglistitem>
|
---|
| 199 | <seg>ant, antRun, antRun.pl, complete-ant-cmd.pl, runant.pl, and runant.py</seg>
|
---|
| 200 | <seg>ant-*.jar, xercesImpl.jar, and xml-apis.jar</seg>
|
---|
| 201 | <seg>/etc/ant and /opt/ant-&apache-ant-version;</seg>
|
---|
| 202 | </seglistitem>
|
---|
| 203 | </segmentedlist>
|
---|
| 204 |
|
---|
| 205 | <variablelist>
|
---|
| 206 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 207 | <?dbfo list-presentation="list"?>
|
---|
| 208 | <?dbhtml list-presentation="table"?>
|
---|
| 209 |
|
---|
| 210 | <varlistentry id="ant">
|
---|
| 211 | <term><command>ant</command></term>
|
---|
| 212 | <listitem>
|
---|
[539ace5] | 213 | <para>is a <application>Java</application> based build tool used by
|
---|
[0619e6d] | 214 | many packages instead of the conventional <command>make</command>
|
---|
[514ef84d] | 215 | program.</para>
|
---|
| 216 | <indexterm zone="apache-ant ant">
|
---|
| 217 | <primary sortas="b-ant">ant</primary>
|
---|
| 218 | </indexterm>
|
---|
| 219 | </listitem>
|
---|
| 220 | </varlistentry>
|
---|
| 221 |
|
---|
| 222 | <varlistentry id="antRun">
|
---|
| 223 | <term><command>antRun</command></term>
|
---|
| 224 | <listitem>
|
---|
[0619e6d] | 225 | <para>is a support script used to start <command>ant</command>
|
---|
[514ef84d] | 226 | build scripts in a given directory.</para>
|
---|
| 227 | <indexterm zone="apache-ant antRun">
|
---|
| 228 | <primary sortas="b-antRun">antRun</primary>
|
---|
| 229 | </indexterm>
|
---|
| 230 | </listitem>
|
---|
| 231 | </varlistentry>
|
---|
| 232 |
|
---|
| 233 | <varlistentry id="antRun.pl">
|
---|
| 234 | <term><command>antRun.pl</command></term>
|
---|
| 235 | <listitem>
|
---|
[539ace5] | 236 | <para>is a <application>Perl</application> script that provides
|
---|
[514ef84d] | 237 | similar functionality offered by the <command>antRun</command> script.</para>
|
---|
| 238 | <indexterm zone="apache-ant antRun.pl">
|
---|
| 239 | <primary sortas="b-antRun.pl">antRun.pl</primary>
|
---|
| 240 | </indexterm>
|
---|
| 241 | </listitem>
|
---|
| 242 | </varlistentry>
|
---|
| 243 |
|
---|
| 244 | <varlistentry id="complete-ant-cmd.pl">
|
---|
| 245 | <term><command>complete-ant-cmd.pl</command></term>
|
---|
| 246 | <listitem>
|
---|
[539ace5] | 247 | <para>is a <application>Perl</application> script that allows
|
---|
[0619e6d] | 248 | <application>Bash</application> to complete an <command>ant</command>
|
---|
[514ef84d] | 249 | command-line.</para>
|
---|
| 250 | <indexterm zone="apache-ant complete-ant-cmd.pl">
|
---|
| 251 | <primary sortas="b-complete-ant-cmd.pl">complete-ant-cmd.pl</primary>
|
---|
| 252 | </indexterm>
|
---|
| 253 | </listitem>
|
---|
| 254 | </varlistentry>
|
---|
| 255 |
|
---|
| 256 | <varlistentry id="runant.pl">
|
---|
| 257 | <term><command>runant.pl</command></term>
|
---|
| 258 | <listitem>
|
---|
[539ace5] | 259 | <para>is a <application>Perl</application> wrapper script used to
|
---|
[514ef84d] | 260 | invoke <command>ant</command>.</para>
|
---|
| 261 | <indexterm zone="apache-ant runant.pl">
|
---|
| 262 | <primary sortas="b-runant.pl">runant.pl</primary>
|
---|
| 263 | </indexterm>
|
---|
| 264 | </listitem>
|
---|
| 265 | </varlistentry>
|
---|
| 266 |
|
---|
| 267 | <varlistentry id="runant.py">
|
---|
| 268 | <term><command>runant.py</command></term>
|
---|
| 269 | <listitem>
|
---|
[539ace5] | 270 | <para>is a <application>Python</application> wrapper script used to
|
---|
[514ef84d] | 271 | invoke <command>ant</command>.</para>
|
---|
| 272 | <indexterm zone="apache-ant runant.py">
|
---|
| 273 | <primary sortas="b-runant.py">runant.py</primary>
|
---|
| 274 | </indexterm>
|
---|
| 275 | </listitem>
|
---|
| 276 | </varlistentry>
|
---|
| 277 |
|
---|
| 278 | <varlistentry id="ant-star">
|
---|
| 279 | <term><filename class='libraryfile'>ant-*.jar</filename></term>
|
---|
| 280 | <listitem>
|
---|
[0619e6d] | 281 | <para>files are the <application>Apache Ant</application>
|
---|
[514ef84d] | 282 | <application>Java</application> class libraries.</para>
|
---|
| 283 | <indexterm zone="apache-ant ant-star">
|
---|
| 284 | <primary sortas="c-ant-star">ant-*.jar</primary>
|
---|
| 285 | </indexterm>
|
---|
| 286 | </listitem>
|
---|
| 287 | </varlistentry>
|
---|
| 288 |
|
---|
| 289 | <varlistentry id="xercesImpl">
|
---|
| 290 | <term><filename class='libraryfile'>xercesImpl.jar</filename></term>
|
---|
| 291 | <listitem>
|
---|
[539ace5] | 292 | <para>is a <application>Java</application> class library used by
|
---|
[514ef84d] | 293 | <application>Apache Ant</application> to perform XML parsing.</para>
|
---|
| 294 | <indexterm zone="apache-ant xercesImpl">
|
---|
| 295 | <primary sortas="c-xercesImpl">xercesImpl.jar</primary>
|
---|
| 296 | </indexterm>
|
---|
| 297 | </listitem>
|
---|
| 298 | </varlistentry>
|
---|
| 299 |
|
---|
| 300 | <varlistentry id="xml-apis">
|
---|
| 301 | <term><filename class='libraryfile'>xml-apis.jar</filename></term>
|
---|
| 302 | <listitem>
|
---|
[539ace5] | 303 | <para>contains the DOM <application>Java</application> classes required
|
---|
[514ef84d] | 304 | by the <application>Apache Ant</application> XML formatter.</para>
|
---|
| 305 | <indexterm zone="apache-ant xml-apis">
|
---|
| 306 | <primary sortas="c-xml-apis">xml-apis.jar</primary>
|
---|
| 307 | </indexterm>
|
---|
| 308 | </listitem>
|
---|
| 309 | </varlistentry>
|
---|
| 310 |
|
---|
| 311 | </variablelist>
|
---|
| 312 |
|
---|
| 313 | </sect2>
|
---|
[dd5bdf3] | 314 |
|
---|
| 315 | </sect1>
|
---|