![]() ![]() |
Aug 28 2006, 04:06 AM
Post
#1
|
|
|
So solid as a rock is ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 794 Joined: 30-May 04 Member No.: 21053
|
i get a error when i place the folder install outside the WPI folder (cant find :\Install\WPI\adobereader.exe).
After this i read in WPI.log that the program is installed succesfull. Thats not true. If WPI.log dont tell true things we have nothing at all the info.... So... a bug? |
|
|
|
Aug 28 2006, 06:38 AM
Post
#2
|
|
|
Advanced Member ![]() ![]() ![]() Group: Members Posts: 427 Joined: 25-July 06 From: Charleston, SC Member No.: 105938
|
Can you give us a little more info. Where is your install folder located (cdrom or HDD)? What does the error message say? What command are you using to call the install?
|
|
|
|
Aug 28 2006, 07:38 AM
Post
#3
|
|
|
So solid as a rock is ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 794 Joined: 30-May 04 Member No.: 21053
|
Can you give us a little more info. Where is your install folder located (cdrom or HDD)? What does the error message say? What command are you using to call the install? Install-folder exist in the root of cdrom and the install goes from cdrom. WPI also exist in the root and also tryed in the Install-folder ( so i tryed two ways). WPI only have 1 line by every applicatition: CODE prog[pn]=['Opera 9']; uid[pn]=['OPERA9']; dflt[pn]=['no']; cat[pn]=['Office']; forc[pn]=['no']; gcond[pn]=['FileExists(\'%programfiles%\')']; cmd1[pn]=['%CDROM%\\Install\\Opera\\Opera.cmd']; pn++; Opera9.cmd: CODE START "Opera 9.1" /wait "Opera_9.01_International_Setup.exe" /s
This post has been edited by Solid as a rock: Aug 28 2006, 08:15 AM
Attached File(s)
|
|
|
|
Aug 28 2006, 10:28 AM
Post
#4
|
|
|
Advanced Member ![]() ![]() ![]() Group: Members Posts: 427 Joined: 25-July 06 From: Charleston, SC Member No.: 105938
|
Ok. The problem here is that you are calling the .cmd inside WPI, therefore when it opens your ms-dos window it defaults to the root of where the call originated (D:\Install\WPI).
Is that the only command in your Opera9.cmd? If so, you could just call it directly as your command1 config entry. Otherwise you would need to add something like: CODE cd %CDROM%\Install\Opera to your Opera9.cmd before you call the .exe.However, the problem with this is that %CDROM% is a WPI variable and not a ms-dos environment variable. I'm not sure, but I cannot think of a way to create a global environment variable in ms-dos and there isn't a cdrom variable. So the only thing that I can think of is to cd to an absolute path (which is not good, but will work): CODE cd ..\..\Install\Opera Try adding that to your Opera9.cmd. |
|
|
|
Aug 28 2006, 10:39 AM
Post
#5
|
|
|
WPI Co-Developer Group: Software Developers Posts: 552 Joined: 13-November 05 From: Bettendorf, IA Member No.: 79628 OS: Vista Home Premium x64
|
The return codes for the installer log are misleading sometimes. What happened is that the script was executed, so as far as WPI knows it was installed. But then the script itself has the path problem you mentioned, WPI doesn't know this, so it says it installed successfully.
|
|
|
|
Aug 28 2006, 10:54 AM
Post
#6
|
|
|
So solid as a rock is ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 794 Joined: 30-May 04 Member No.: 21053
|
Ok. The problem here is that you are calling the .cmd inside WPI, therefore when it opens your ms-dos window it defaults to the root of where the call originated (D:\Install\WPI). Is that the only command in your Opera9.cmd? If so, you could just call it directly as your command1 config entry. No, the Opera9.cmd exist in cdrom:\Install\Opera9\ WPI itself is pointed to the cmd. So i can change in the future very easy the cmd when get new versions. I dont like to change config.js, to much work for me... QUOTE Otherwise you would need to add something like: Hmmm, i will take a look at it....CODE cd %CDROM%\Install\Opera to your Opera9.cmd before you call the .exe.However, the problem with this is that %CDROM% is a WPI variable and not a ms-dos environment variable. I'm not sure, but I cannot think of a way to create a global environment variable in ms-dos and there isn't a cdrom variable. So the only thing that I can think of is to cd to an absolute path (which is not good, but will work): CODE cd ..\..\Install\Opera Try adding that to your Opera9.cmd. The return codes for the installer log are misleading sometimes. What happened is that the script was executed, so as far as WPI knows it was installed. But then the script itself has the path problem you mentioned, WPI doesn't know this, so it says it installed successfully. Is there no waterproof way to check if a install is succesfull? Maybe a check "If there %Programfiles%\Opera is true = then show "Congrulations, you have installed Opera succesfully"? Or to look if there is happened any error, than write this to the WPI.log "an error happened after excuting "Opera9.cmd" |
|
|
|
Aug 28 2006, 12:31 PM
Post
#7
|
|
|
Advanced Member ![]() ![]() ![]() Group: Members Posts: 427 Joined: 25-July 06 From: Charleston, SC Member No.: 105938
|
It would be possible to have a post-execute condition. You might want to bring that up as an enhancement request for 5.4. As far as checking for errors, WPI can only go off of what the command returns and your commands are returning that they executed properly.
|
|
|
|
Aug 28 2006, 01:11 PM
Post
#8
|
|
|
So solid as a rock is ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 794 Joined: 30-May 04 Member No.: 21053
|
Which changes do i need to make this work? (XPFINAL=%cdrom%)
This post has been edited by Solid as a rock: Aug 28 2006, 01:12 PM
Attached File(s)
|
|
|
|
Aug 28 2006, 02:29 PM
Post
#9
|
|
|
Advanced Member ![]() ![]() ![]() Group: Members Posts: 427 Joined: 25-July 06 From: Charleston, SC Member No.: 105938
|
In this case you need to add the cd statement to your .cmd files before the start command. Since your WPI folder is in the root of your cd, you only need to escape one folder (WPI) so just use one '..' in your cd command. So the first command of each of your .cmd files should be the cd command.
For example, your Opera9.cmd should look something like this: CODE cd ..\Install\Opera START "Opera 9.1" /wait "Opera_9.01_International_Setup.exe" /s I think that should solve your problem. |
|
|
|
Aug 29 2006, 04:53 PM
Post
#10
|
|
|
So solid as a rock is ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 794 Joined: 30-May 04 Member No.: 21053
|
In this case you need to add the cd statement to your .cmd files before the start command. Since your WPI folder is in the root of your cd, you only need to escape one folder (WPI) so just use one '..' in your cd command. So the first command of each of your .cmd files should be the cd command. For example, your Opera9.cmd should look something like this: CODE cd ..\Install\Opera START "Opera 9.1" /wait "Opera_9.01_International_Setup.exe" /s I think that should solve your problem. Could this be done in the WPI itself? Something like this: cmd1[pn]=['cd ..\Install\Opera']; cmd2[pn]=['%CDROM%\\Install\\Opera\\Opera.cmd']; I means, all my cmd are pathfree so if i give a folder to someone it will work immediality when running the cmd, When i specify the path \install\ in the 1st line it will no longer work. So if i choose your way i better give full paths in every line of my cmd... |
|
|
|
Aug 29 2006, 06:55 PM
Post
#11
|
|
|
WPI Co-Developer Group: Software Developers Posts: 552 Joined: 13-November 05 From: Bettendorf, IA Member No.: 79628 OS: Vista Home Premium x64
|
@Solid: Just checking, this goes back a ways, but do you have WIN51 in your CD root? That is where WPI checks first. If not there, then it goes in to WPI's starting path. That may be why your path is set to X:\WPI\Install instead of X:\Install
Just something to check................. |
|
|
|
Aug 29 2006, 08:53 PM
Post
#12
|
|
|
Advanced Member ![]() ![]() ![]() Group: Members Posts: 427 Joined: 25-July 06 From: Charleston, SC Member No.: 105938
|
@solid: The cd command must be executed in the same shell as the .cmd command.
Try this: CODE cmd1[pn]=['cd %CDROM%\\Install\\Opera & Opera.cmd'];
|
|
|
|
![]() ![]() |
| Lo-Fi Version | Time is now: 23rd November 2008 - 04:54 AM |