This post explains setting up IntelliJ IDEA to use the OpenJDK on Fedora. It is more for my personal future reference than anything else.
Download the things:
- Download the latest “Community” edition of IntelliJ IDEA from its website.
cdto the directory where its downloaded, extract the tar ball and start the IDE:
$ cd Downloads/ $ tar xvf ideaIC-2021.3.3.tar.gz $ cd idea-IC-213.7172.25/bin $ ./idea.sh
- Optionally, create a launcher for it:
$ cat /usr/local/share/applications/idea.desktop [Desktop Entry] Encoding=UTF-8 Name=Idea Type=Application Exec=sh /path/to/idea-IC-213.7172.25/bin/idea.sh Icon=/path/to/idea-IC-213.7172.25/bin/idea.png Categories=Programming
- Install OpenJDK on Fedora:
$ sudo dnf install -y java-11-openjdk java-11-openjdk-devel
- Open IntelliJ IDEA and click on “New Project”.
- If no SDK was detected by IntelliJ IDEA, click on the drop-down for “Project SDK”, enter the path
/usr/lib/jvm/java-openjdk, and click OK.