I have to make a installer using package maker, package maker version is Version 3.0.4 (179)
In our package, before installing, we need to run the a script, ( Pre-Install script) , which should check the JAVA Version,
if version is less then 1.6 then it should tell user to take update of JVM and installation should quit without installing the App,
I did following,
In Distribution, click on pre-install Action and added this script,
Added necessary action what message should show when it failed,
its working fine on my machine, but when i tried to run on other machine which is having JVM1.6 installed, the package is failing,
after doing lot of investigation, i got following piece of code in Raw-Editing-mode
<script>
function pm_install_check() {
if(!(system.run('/Users/amitg/Documents/MacApp/CheckJVMScript.sh') == true)) {
my.result.title = 'JAVA VM Error ';
my.result.message = 'JAVA Version should be 1.6 or above, ';
my.result.type = 'Fatal';
return false;
}
return true;
}
</script>
It means it search on a pre-defined path and it seems its failing due to it didn't get script on that path.
It seems, package is expecting script to be present at that path , or i am doing any mistake while giving path, i checked there, there is no absolute / relative path.
Are there any work-around, for that, googling says , there is preflight script , but i didn't get any documentation for that.
Thanks in Advance