Axis 2 can't see JAVA_HOME on my Mac (soapUI and wsdl2java)

Question : Why can Axis 2 not see where Java home is? Have I set it incorrectly?

Summary : I'm attempting to use Axis 2 with soapUI to generate Java objects from a wsdl on my Mac. However, I get the error "You must set the JAVA_HOME variable before running Axis2 Script."

If I type echo $JAVA_HOME into the command line, it says


I've navigated to the JavaVirtualMachines folder and the jdk is indeed there.

I also have edited ~/.bash_profile to say

export JAVA_HOME=$(/usr/libexec/java_home)


Are you launching SoapUI by clicking on an icon? In that case, SoapUI wouldn't necessarily have access to environment variables set in your bash startup scripts.

Take a look at this question and this one about setting environment variables so that they're accessible to GUI apps. Basically, you may have to modify some system-wide configuration files.

Another solution would be to start SOAP UI from the terminal as your .profile will be already loaded.

open -a /Applications/

Need Your Help

How to retrieve part of JSON file?

ios objective-c

it's possible by using IF to retrieve some parts of JSON not all of it in Objective-C. like i want to retrieve just those data when Gender equals Male

How do you set the input level (gain) on the built-in input (OSX Core Audio / Audio Unit)?

objective-c macos core-audio audiounit

I've got an OSX app that records audio data using an Audio Unit. The Audio Unit's input can be set to any available source with inputs, including the built-in input. The problem is, the audio tha...