Hi, It is primary on my "wrapped" library that this applies, for so it can be easily installed.
Yes on windows the JRE is found using the PATH. I haven't been able to locate where this is done, as I would prefer to use a direct variable or separate environment variable for this to keep it "boxed" from the system variables. I have however found a way now that works fine based on updating the PATH as a first thing in the __init__.py file in the wrapped library by prepending: import os os.environ["PATH"] = r"mypath\jre\bin\server" + os.pathsep + os.environ["PATH"] the installer takes care of updating the path to the right place later on. Many thanks /Petrus On Tue, Jan 20, 2015 at 7:14 PM, Andi Vajda <va...@apache.org> wrote: > > On Tue, 20 Jan 2015, Petrus Hyvönen wrote: > > Hi, >> >> I'm trying to package a wrapped library together with a non system-wide >> java JDK so that it can be easily installed. >> >> Can I somehow direct which JDK to use besides using JCC_JDK and putting >> the >> JRE in the PATH (I'm currently under windows)? The JCC_JDK could be >> patched >> in the setup.py but the PATH JRE that is accessed during running the >> wrapped library I don't understand where it is accessed, or how to patch >> this? >> > > So you're asking how to control where to pickup the JRE DLLs (on Windows) > at runtime ? If I remember correctly, on Windows you just set the Path > environment variable, no ? > > For example it would be good to have this in the config.py file if >> possible? >> > > If you're sure config.py is run _before_ any JRE DLL is loaded, you might > be able to change the Path fron there too. > > Andi.. > > > >> Any thoughts or someone who's done this already? >> >> Regards >> /Petrus >> >> >> -- >> _____________________________________________ >> Petrus Hyvönen, Uppsala, Sweden >> Mobile Phone/SMS:+46 73 803 19 00 >> > -- _____________________________________________ Petrus Hyvönen, Uppsala, Sweden Mobile Phone/SMS:+46 73 803 19 00