0

Note: even though this question involves GWT, it's really an Ant question. All I'm asking is: is the Ant PATH that I have below a "legal" path?

I am getting ClassNotFoundExceptions on a type (com.google.gwt.dev.Compiler) that is packaged inside gwt-dev.jar (which as you can see is configured to be on the path below). Does the gwt.path look wrong to anyone:

<path id="gwt.path">
    <pathelement location="${gen.bin.main.dir}"/>
    <fileset dir="${gen.lib.main.dir}">
        <filename name="gin-2.1.2.jar"/>
        <filename name="guice-3.0.0.jar"/>
        <filename name="guice-assistedinject-3.0.0.jar"/>
        <filename name="gwt-bootstrap-2.2.2.jar"/>
        <filename name="gwt-bootstrap-sources-2.2.2.jar"/>
        <filename name="gwt-dev.jar"/>
        <filename name="gwt-user.jar"/>
        <filename name="javax-inject-1.0.0.jar"/>
        <filename name="requestfactory-apt.jar"/>
        <filename name="requestfactory-client+src.jar"/>
        <filename name="validation-api-1.0.0.GA.jar"/>
        <filename name="validation-api-1.0.0.GA-sources.jar"/>
    </fileset>
</path>

If now then I will explore other avenues.

4

2 回答 2

1

要查看 ant 路径是否正确,请使用 ant touch命令:

<touch file="myfile"/>

这类似于 unix touch 命令,如果路径正确,应该在该路径中创建一个名为 myfile 的空文件。

在这种情况下,您是否尝试将一些 jars 添加到类路径中?在这种情况下,您应该使用类路径元素而不是路径。

于 2013-12-08T22:27:21.993 回答
0

我想到了。这是坏蚂蚁。所有<fileset>元素都需要<pathelement location="the-jar"/>代替。

于 2013-12-09T18:50:53.930 回答