【发布时间】:2021-10-07 17:43:57
【问题描述】:
我有一个项目 git clone --depth 1 --branch v2.3.30 https://github.com/apache/freemarker.git 并想从源代码构建它。为此我发出一个命令
ant jar
有以下输出
└─$ ant -version 1 ⨯
Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true
Apache Ant(TM) version 1.10.9 compiled on December 25 1969
┌──(katya12㉿kali)-[/home/…/prostor/offline/ito-kpo-mka/freemarker]
└─$ ant jar
Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true
Buildfile: /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build.xml
[copy] Copying 1 file to /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build
[delete] Deleting: /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build/version.properties.tmp
_autoget-deps:
[copy] Copying 1 file to /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build
[delete] Deleting: /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build/version.properties.tmp
_autoget-deps-condition-workaround:
[copy] Copying 1 file to /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build
[delete] Deleting: /home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build/version.properties.tmp
update-deps:
[echo] Getting dependencies...
[echo] -------------------------------------------------------
BUILD FAILED
/home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build.xml:968: The following error occurred while executing this line:
/home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build.xml:977: The following error occurred while executing this line:
/home/katya/work/prostor/offline/ito-kpo-mka/freemarker/build.xml:985: Problem: failed to create task or type antlib:org.apache.ivy.ant:settings
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.
No types or tasks have been defined in this namespace yet
This appears to be an antlib declaration.
Action: Check that the implementing library exists in one of:
-/usr/share/ant/lib
-/home/katya12/.ant/lib
-a directory added on the command line with the -lib argument
Total time: 0 seconds
我不知道这是什么意思。你能不能告诉我?是否可以以某种方式使用 ANT 或 IVY 构建源代码?谢谢!
【问题讨论】: