7

Today I accidentally delete the /usr/libexec/java_home executable on my Mac OS X 10.8.5 (Mountain Lion) while trying to install latest JDK. Then, I realized that homebrew (package manager) and some other apps needs that binary.

Where can I find or recover that file?

Giacomo1968
  • 58,727
edigu
  • 243
  • 2
  • 9

1 Answers1

7

I found the solution. It was just a symlink and original file was still alive in this directory:

/System/Library/Frameworks/JavaVM.framework/

So, simply put back the symlink using the following command:

sudo ln -s /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java_home /usr/libexec/.

Update: The System/Library/Frameworks directory holds the framework files which provide interfaces needed to write software for Mac. You can learn more about this directory on official OS X Frameworks documentation.

edigu
  • 243
  • 2
  • 9