Resolving version conflict between java and javac on Ubuntu

后端 未结 5 1599
故里飘歌
故里飘歌 2021-02-01 06:09

I have a problem with my compiled Java application on Ubuntu. It throws UnsupportedClassVersionError. I am compiling with a higher JDK version than the one that is

5条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-02-01 06:46

    Run either of the following to locate where the location is of that

    javac 1.7.0_147
    

    being used as follows:

    whereis javac
    

    or

     locate javac
    

    or

    find javac
    

    Then once you found the directory, symbolically and forcefully link the bin contents to /usr/bin:

    sudo ln -f -s [put location here]/bin/* /usr/bin
    

提交回复
热议问题