NetBeans + GWT 2.2.0 + Maven编译问题 [英] NetBeans + GWT 2.2.0 + Maven compile problem

查看:89
本文介绍了NetBeans + GWT 2.2.0 + Maven编译问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在NetBeans 6.9中用Google Web Toolkit创建一个Maven Web Application项目。我已按照此视频中显示的步骤进行操作: http://www.youtube.com/观看?v = M-iVZ5TJ21w



在创建项目并将GWT添加到框架后,我的项目很好地编译并部署到了Tomcat。现在我想将默认的GWT版本从2.0.3更改为2.2.0。当我编辑POM中的 gwt.version 属性并保存文件时,NetBeans获取新的 gwt-user-2.2.0.jar 文件和javadoc。但是,如果我尝试编译项目,我在控制台中得到这个Maven错误:

 下载:http://repo1.maven .org / maven2 / com / google / gwt / gwt-dev / 2.2.0 / gwt-dev-2.2.0-linux.jar 
无法找到资源'com.google.gwt:gwt-dev:jar :linux:2.2.0'in repository central(http://repo1.maven.org/maven2)

如果我将浏览器指向 http: //repo1.maven.org/maven2/com/google/gwt/gwt-dev/2.2.0/ 我可以看到确实没有 gwt-dev-2.2.0-linux .jar 存在。不过,我可以看到一个 gwt-dev-2.2.0.jar ,我认为它是正确的。



我应该怎么做才能解决这个错误?解析方案

你可能使用的是旧版本的gwt-maven-插入。切换到2.2.0或删除版本声明,它会获取最新版本。



你也可能在你的pom中有一些GWT的旧格式依赖。旧的GWT版本需要标签。如果你有一个你可以删除标签,它将获取不带-linux后缀的系统独立版本。


I'm trying to create a Maven Web Application project with Google Web Toolkit in NetBeans 6.9. I've followed the steps shown on this video: http://www.youtube.com/watch?v=M-iVZ5TJ21w

After creating the project and adding GWT to the frameworks my project compiles and deploys to Tomcat nicely. Now i like to change the default GWT version from 2.0.3 to 2.2.0. As i edit the gwt.version property in the POM and save the file, NetBeans fetches the new gwt-user-2.2.0.jar file and the javadoc. However if i try to compile the project i get this Maven error in the console:

Downloading: http://repo1.maven.org/maven2/com/google/gwt/gwt-dev/2.2.0/gwt-dev-2.2.0-linux.jar
Unable to find resource 'com.google.gwt:gwt-dev:jar:linux:2.2.0' in repository central (http://repo1.maven.org/maven2)

If i point my browser to the URL http://repo1.maven.org/maven2/com/google/gwt/gwt-dev/2.2.0/ i can see that there's truly no gwt-dev-2.2.0-linux.jar present. However i can see there a gwt-dev-2.2.0.jar which i think will be the correct one to use.

What should i do to fix this error?

解决方案

You're probably using old version of gwt-maven-plugin. Switch to 2.2.0 or remove version declaration and it'll fetch newest version.

It's also possible that you have some old-format dependency for GWT in your pom. There used to be tag required for old GWT versions. If you have one you can remove tag and it will fetch system independent version without -linux suffix.

这篇关于NetBeans + GWT 2.2.0 + Maven编译问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆