What I'm trying to do is export JAVA_HOME path from inside a python script.
Reasons for this:
- Kodi addons are all written in python.
- Bluray and UHD Bluray menus require JAVA (JRE) to run.
- I want to add this to Android and most boxes are not rooted, like the Nvidia Shield.
I'm using a JRE for ARM based devices named Zulu.
My code so far:
import os
os.system('export JAVA_HOME=/storage/emulated/0/JAVA/bin/java')
os.system('export PATH=$PATH:$JAVA_HOME/bin')
Sadly, this isn't working.
EDIT: The proposed solution solves the problem that uses your os.environ. I would like to change an environment path for the entire OS just like exporting JAVA_PATH from a shell.