安裝openjdk-8時選擇用於啟動Intellij的JDK


1

我已經使用以下命令安裝了openjdk-8,

sudo apt-get install openjdk-8-jdk

並設置路徑變量,但是,當我去在Intellij中創建新的Maven項目時,它要求我提供JDK。我選擇了路徑/ usr / lib / jvm / java-8-openjdk-amd64,它不接受此路徑作為JDK的有效路徑。

請幫助我解決此問題。

0

Problem got solved, just 'javac' was missing. Just type javac in your terminal and it will suggest commands for you.

sudo apt install openjdk-8-jdk-headless 

solved my problem