On 17.11.2016 08:50, Michaël Michaud wrote:
> Hi Ede,
> 
> This week, several co-workers have had problems with their java installation 
> after an automatic update on their windows machine (problems probably related 
> to the enterprise update policy, not the standard windows update).
> 
> On these machines, JRE is still present somewhere in Program Files (but java 
> was no more accessible from the path : java -version returns 'java not found')

recent jre's puts links to it's binaries into 
'C:\ProgramData\Oracle\Java\javapath\' and add that folder to the system PATH 
variable

before that the jre's put symlinks into the Windows\system32 folders, which 
automatically in PATH

> As a temporary solution, I decided to wrap a JRE in an OpenJUMP distribution 
> (reinstalling java was not an option). I used the possibility to set a 
> relative path to a JRE in the .bat file.

that should work, at least for the batch file

> What I noticed and suprised me :
> 
> - on some machines where java was broken, the embeded version with an 
> appropriate JAVA_HOME was working from the .bat, *but not from the .exe*

that can happen
 
> - on some machines where java was broken, the standard version (without 
> customized JAVA_HOME), the .bat stopped working, *but the .exe still worked* !

i'd like to see terminal output from those. uncomment in bat
  set JAVA_BIN=java
and run from exe and bat respectively.

> I did not check how the .exe works but I naively thought that it was just a 
> thin wrapper around the .bat. Have you some hints about how the .exe works, 
> and why it can behave this way ?

not sure what software i created the exe w/ anymore, but i remember that it not 
only run the batch file, it was actually based on Launch4J or such and wraps a 
small java class that in turn executes the batch file. so it actually needs a 
java interpreter as well ;)

always planned to make that more straight forward, but it did the trick so 
nicely. if it does not there is still the batch file, which will always work, 
you might have to edit JAVA_HOME though.

rainy regards ..ede

------------------------------------------------------------------------------
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to