I have an executable called fingerVerification_fdu03 in my current directory. I want to run that executable from Java using the ProcessBuilder, so I do:
Process pb = new ProcessBuilder("fingerVerification_fdu03").start();
However it is saying that it cannot find the file, even though it is in the same directory as the java program. Normally, I can execute the execute fingerVerification_fdu03 through the linux terminal simply doing:
./fingerVerification_fdu03
and it will run. What am I doing wrong?
Update:
I tried adding the directory, but still getting the same issue. I did:
String workingDirectory = new String(System.getProperty("user.dir"));
File tempDir = new File(workingDirectory);
Process p = new ProcessBuilder("fingerVerification_fdu03").
directory(new File(workingDirectory+"//")).start();
Could there be something wrong with the extension of the fingerVerification_fdu03 file? I'm not sure how to find out what extension it has. It is a binary file and is not listing it's extension.