org/codehaus/plexus/archiver/jar/JarArchiver(不受支持的major.minor版本49.0)-Maven构建错误 [英] org/codehaus/plexus/archiver/jar/JarArchiver (Unsupported major.minor version 49.0) - Maven build error

查看:875
本文介绍了org/codehaus/plexus/archiver/jar/JarArchiver(不受支持的major.minor版本49.0)-Maven构建错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

下午,

尝试构建我的项目时,我收到上述错误.我很确定这与使用Java 1.6编译的Maven最新更新有关,而我们尝试构建的项目是1.4项目.之前的插件可以正常工作,因此我将以下内容添加到POM.xml文件中,以尝试强制使用现有的插件.

I am receiving the above error when trying to build my project. I'm pretty sure this has something to do with Maven's latest update being compiled using Java 1.6 and the project we are trying to build is a 1.4 project. The plugin prior to this worked without problems, so I have added the following to the POM.xml file to try to force the existing plugin to be used.

    <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-archiver</artifactId>
        <version>1.2</version>
    </dependency>

但是它仍然失败.

任何帮助将不胜感激

谢谢

推荐答案

尝试为maven添加以下插件.它对我有用:

Try to add the following plugin for maven. It works for me:

<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-jar-plugin</artifactId>
    <version>2.3.2</version>
    <configuration>
        <encoding>UTF-8</encoding>
    </configuration>
</plugin>

这篇关于org/codehaus/plexus/archiver/jar/JarArchiver(不受支持的major.minor版本49.0)-Maven构建错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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