$ tar xvfz jakarta-ant-1.3-src.tar.gz $ cd jakarta-ant-1.3 $ ./bootstrap.sh (snip) [javac] Compiling 54 source files to /usr/local/src/jakarta-ant-1.3/build/classes [javac] 注: /usr/local/src/jakarta-ant-1.3/src/main/org/apache/tools/ant/taskdefs/optional/PropertyFile.java \ は推奨されない API を使用またはオーバーライドしています。 [javac] 注: 詳細については、-deprecation オプションを指定して再コンパイルしてください。 (snip) BUILD SUCCESSFUL Total time: 49 seconds ... Cleaning Up Build Directories ... Done Bootstrapping Ant Distribution $ ./build.sh # su # ./build.sh install Buildfile: build.xml install: BUILD SUCCESSFUL Total time: 4 seconds # exit |
export ANT_HOME=/usr/local/ant export PATH=$PATH:$ANT_HOME/bin |
$ . ~/.bashrc $ su # ./build.sh install (snip) BUILD FAILED /usr/local/src/jakarta-ant-1.3/build.xml:510: Javadoc failed: java.io.IOException: javadoc: not found --- Nested Exception --- java.io.IOException: javadoc: not found at java.lang.UNIXProcess.forkAndExec(Native Method) at java.lang.UNIXProcess. |
# . ~foo/.bashrc # ./build.sh install (snip) [javadoc] /usr/local/src/jakarta-ant-1.3/build/javadocs/package-list の生成 [javadoc] /usr/local/src/jakarta-ant-1.3/build/javadocs/help-doc.html の生成 [javadoc] /usr/local/src/jakarta-ant-1.3/build/javadocs/stylesheet.css の生成 [javadoc] 警告 70 個 dist: [mkdir] Created dir: /usr/local/ant/docs [mkdir] Created dir: /usr/local/ant/docs/api [copy] Copying 2 files to /usr/local/ant/lib [copy] Copying 1 file to /usr/local/ant/lib [copy] Copying 97 files to /usr/local/ant/docs [copy] Copying 352 files to /usr/local/ant/docs/api [copy] Copying 4 files to /usr/local/ant BUILD SUCCESSFUL Total time: 2 minutes 43 seconds |
# cd /usr/local/ant/bin # chmod go+rx ant antRun # exit $ /usr/local/ant/bin/ant -version Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/Main |
$ su # cd /usr/local/ant # chmod a+r bin/* lib/* # exit $ /usr/local/ant/bin/ant -version Ant version 1.3 compiled on August 28 2001 |
export PATH=$ANT_HOME/bin:$PATH <--- 順序を逆にする |
$ tar xvfz apache-ant-1.5.3-1-src.tar.gz $ cd apache-ant-1.5.3-1 $ ./build.sh -Ddist.dir=/usr/local/ant dist (snip) dist-lite: Copying 2 files to /usr/local/ant/lib BUILD FAILED file:/usr/local/src/apache-ant-1.5.3-1/build.xml:770: \ Failed to copy /usr/local/src/apache-ant-1.5.3-1/build/lib/optional.jar \ to /usr/local/ant/lib/optional.jar due to /usr/local/ant/lib/optional.jar \ (許可がありません) and I couldn't delete the corrupt /usr/local/ant/lib/optional.jar Total time: 22 seconds |
$ su # ./build.sh -Ddist.dir=/usr/local/ant dist # ./build.sh install # exit |