Problem:
I want to use ITR e-filing utility (India's Income Tax Return e-filing utility) on Ubuntu or any of its flavors.
What I've tried:
- I tried installing
java
(OpenJDK 11), and installing OpenJFX using Synaptic Manager. It still shows following error:
Error: JavaFX runtime components are missing, and are required to run this application
New answer
Income Tax Department recommends using Java version 8 Update 51 (See this PDF file).
Step 1: Download openjdk-8-jre using Synaptic Package Manager or command line as below:
Step 2: Install OpenJFX components of v8 series. It can be done through command line:
Try running the ITR.sh file (need to make it executable first!). Proceed to Step 3 if error occurs.
Step 3: Ensure that Java's version 8 is being used with OpenJFX. Type in command line:
You may be greeted with something like:
Enter
2
to use Java 8 as it is the only one that runs the income tax utility.Use ITR utility
Find
ITR.sh
file that comes in the e-filing utility.Right click on the file
ITR.sh
--> Go toProperties
--> ClickPermissions
tab --> Make the file executable --> ClickApply
thenOK
.Click
ITR.sh
--> Execute the file (preferably in terminal) --> Voila!Note: You may need to edit ITR.sh file (simply right click and open with default text editor) and add
#!/bin/bash
at the start of the file. After doing so,ITR.sh
file should look like:Previous answer
Download supported Java version
Income Tax Department recommends using Java version 8 Update 51 (See this PDF file). You need to have account on Oracle website to be able to download older (archived) Java versions. In case you do not have an account on Oracle website or do not want to open one, head over to this index website by CERN and click on jdk-8u51-linux-x64.tar.gz for 64 bit version or jdk-8u66-linux-i586.tar.gz for 32bit version (JDK v8u66 is slightly upper version but shouldn't matter much). This answer takes jdk-8u51-linux-x64.tar.gz as the downloaded file. If you have downloaded 32 bit version just change the file name to jdk-8u66-linux-i586.tar.gz.
Install Java
Method 1 (Quick):Copy:
Go to the directory (folder), where you have downloaded jdk-8u51-linux-x64.tar.gz.
Create a file named
RUN.sh
. Open it with default text editor (like gedit, kwrite) and paste the above copied contents in it. Save the file.Right click on the file
RUN.sh
--> Go toProperties
--> ClickPermissions
tab --> Make the file executable --> ClickApply
thenOK
.Execute the file in terminal (press F4, and type
sh ./RUN.sh
) --> Type password when prompted (you may not even see asterisks when you type, it is normal)Restart your computer.
Method 2 (Explained):Go to the directory, where you have downloaded jdk-8u51-linux-x64.tar.gz, say Downloads, which gives us path of directory:
/home/*user*/Downloads
.Open terminal window by pressing F4.
Type following commands one by one:
Create a directory in your file system, in a manner so that it wouldn't interfere with OpenJDK in case it is installed in future:
/usr/java
Type password when prompted (you may not even see asterisks when you type, it is normal).
Extract the files you just downloaded in that directory:
Set your JAVA_HOME environment variable:
Set up installed Java (Oracle JDK v8u51) at a higher priority (here 20000), so that in case another JDK (say OpenJDK) is installed in future, Oracle JDK v8u51 continues to be used.
Restart your computer.
Use ITR utility
Find
ITR.sh
file that comes in the e-filing utility.Right click on the file
ITR.sh
--> Go toProperties
--> ClickPermissions
tab --> Make the file executable --> ClickApply
thenOK
.Click
ITR.sh
--> Execute the file (preferably in terminal) --> Voila!Note: You may need to edit ITR.sh file (simply right click and open with default text editor) and add
#!/bin/bash
at the start of the file. After doing so,ITR.sh
file should look like:Hope it helps!
Since oracle took java they made it complicated. I face same issue and sorted out. I have another easy solution.
Download
java-1.8.0-amazon-corretto-jdk_8.262.10-1_amd64.deb
from amazon and install as:It works perfectly.
$ ./ITR.sh
I got correct output for ITR utility like this pic
How to solve JavaFX Runtime Missing Components: The problem occurs as latest JDK/JRE do not come with JavaFX. The fix what I have just found out is:
DOWNLOAD the javaFX sdk. I did it from https://gluonhq.com/products/javafx/. Please ensure you choose the linux version for your Ubuntu installation
UNZIP
SAVE the unzipped folder in your library. I did it in "/usr/lib"
EXPORT THE PATH of javaFX by "export" command. In my case: "export PATH_TO_FX=/usr/lib/javafx-sdk-11.0.2/lib"
UPDATE ITR.sh to include the path of javaFX. After updating mine, it looks like:
#java -jar ITR-2_AY202021_PR3.2.jar \n export PATH_TO_FX=/usr/lib/javafx-sdk-11.0.2/lib \n java -jar --module-path $PATH_TO_FX --add-modules javafx.controls,javafx.fxml,javafx.web ITR-2_AY202021_PR3.2.jar
Please note, how the module path is added to point to $PATH_TO_FXRun ITR utility script: ./ITR.sh
Please revert back to me if it still does not work.
I referred above suggestion given by Vijay and it worked like magic.Thanks Vijay!
I followed below steps on my macOS:
export JAVA_HOME=/Library/Java/JavaVirtualMachines/amazon-corretto-8.jdk/Contents/Home
I was able to launch the utility successfully