I am using Linux Mint and trying to run Intellij IDEA from icon on the start menu. Starting Intellij via terminal ./idea.sh works fine. However launching from icon (points to the same ./idea.sh) ends up with following error:
No JDK found. Please validate either IDEA_JDK, JDK_HOME or JAVA_HOME environment variable points to valid JDK installation.
Running echo $JAVA_HOME and java -version works correctly and shows installed JDK.
How can I fix this issue and why starting from icon differs from starting from terminal?