eclipse打包No compiler is provided in this environment. Perhaps you are running on a JRE rather a JDK?

报错信息;打包时经常报错如下;

No compiler is provided in this environment. Perhaps you are running on a JRE rather a JDK?

比较好的解决方式,就是在pom文件中配置你本地的jdk的路径,相当成功了,哈哈

<plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <fork>true</fork>
          <!--指定你的jdk地址-->
          <executable>
           D:\soft\jdk1.8\bin\javac.exe
          </executable>
        </configuration>
      </plugin>

猜你喜欢

转载自blog.csdn.net/qq_38220334/article/details/107533090