MacOS/Java AppBundler error: NoSuchFileException: Info.plist

If you’re using the Oracle AppBundler to build a Mac/MacOS application bundle from a Java application and run into this error when running Ant:

NoSuchFileException: <directory path here> Info.plist

I have found that the problem is that I have not set and exported JAVA_HOME. To set and export JAVA_HOME on MacOS 10.12, I use this command in the shell script I use to build my Mac/Java app:

JAVA_HOME=`/usr/libexec/java_home -v 1.8`
export JAVA_HOME

That’s a frustrating error message, because it has nothing to do with the problem, but I have found this to be the solution.

 

“There is only Now.”
 
~ Eckhart Tolle