Jump to content

Inf-File misbehaving


amigaman

Recommended Posts

Hello, People,

I am getting more and more familiar with Wihu, but now i encountered a problem i cannot explain.

Please review the following:

Wihu is called from Winnt.sif/guirunonce.

Install.ini has some lines

description.3=Codecs
command.3=cmd /c %systemdrive%\install\codecs.cmd
selected.3 = 1

Codecs.cmd looks like:

set dir=%systemdrive%\install
rundll32.exe setupapi,InstallHinfSection DefaultInstall 132 %dir%\mp3\fhg.inf

Fhg.inf is looking like this:

[Version] 
Signature   = "$Chicago$"
AdvancedINF = 2.5, "Your setup subsystem is outdated.  Please install IE 3.01 or greater."

[DefaultInstall]
RequiredEngine=Setupapi
CopyFiles  = CopyFiles.DLL, CopyINF
RegisterOCXs     = OCX.Register
AddReg = AddReg

[DestinationDirs]
CopyFiles.DLL        = 11  
CopyINF    = 17

[AddReg]
HKLM, "SOFTWARE\Microsoft\Windows NT\CurrentVersion\drivers.desc", "l3codecp.acm",, "Fraunhofer IIS MPEG Layer-3 Codec (Professional)"
HKLM, "SOFTWARE\Microsoft\Windows NT\CurrentVersion\drivers32", "msacm.l3codec",, "l3codecp.acm"

[OCX.Register]
"%11%\l3codecp.acm"  

[CopyFiles.DLL]
l3codecp.acm,,,97
 
[CopyINF]
fhg.inf

Now there's a significant difference in the behaviour of the Inf-File:

In manual installation (right click -> install) it all works well.

Wenn called from wihu, everything in the '%systemdrive%\install'-Directory gets deleted.

What is happening here ?

Link to comment
Share on other sites


Why don't you code the install directly in wihu rather than using inf file ?

For me or you use wihu or you use xplode, but I don't see the interest of having a mix of the 2, but maybe I'm missing something.

What is your purpose ?

Link to comment
Share on other sites

@XPect

No, his reason for using INF is valid.

His purpose is to have those codecs installed.

@amigaman

No, I doubt that wihu has anything to do with this problem. Its more about how you call the files, I think - and then maybe the INF file calls a DLL that empties the folder it runs... gotta check deeper to know. And for that, need more details.

Until then, I have this suggestion for you:

The below series of commands is unnecessarily complicated. It'd make your task easier to change it a bit.

1. Forget about codecs.cmd - not needed.

2. Change those "some lines" that you posted - modified code of that 3 lines below:

description.3=Codecs
command.3=rundll32.exe setupapi,InstallHinfSection DefaultInstall 132 %systemdrive%\install\mp3\fhg.inf
selected.3 = 1

The structure of the INF tells me that _maybe_ the files copying might not work.... but after using the above code, the directory deletion should not happen. Just try it, and tell us how it goes. :thumbup

Link to comment
Share on other sites

@prathapml:

I use the cmd, because the lines i have posted are not the only ones for this item.

But i reduced the cmd-file to this line without getting rid of the problem.

It does not happen, when i doubleclick the cmd-file in Explorer, nor when right-clicking the inf file.

Only wihu does the unexpected deletion. so i think it is a problem of wihu calling the function.

BTW, the inf does what is expected, even with the deletion...

I now have a solution, which is a workaround, but it does what is intended:

I copy the files manually, then add the 2 keys in registry, then call regsvr32 to register the dll, all in my cmd. No need for the inf-file.

Link to comment
Share on other sites

Hello, again,

i tried to install Nero Multimounter this way.

Same procedure, same result.

When i double click on the CMD, which simply calls the rundll32.exe... all works ok,

only when started from Wihu, all content of the %systemdrive%\install-directory except the wihu-exe gets deleted.

The Procedure needs an Service to be installed. Anybody knows how to do this without using the inf-file?

I have tested it on several machines, with nlited and original XP-Pro-SP2-CDs, it even works (not), when i call wihu from an already installed WinXP.

Link to comment
Share on other sites

We have already said this once - WIHU is not deleting that directory by itself!

Most probably, this is a case of cleanup.cmd or some command that is part of it, being run too early on in the unattended. Please post your install.ini and any .CMDs that you use - so that someone can find out what's wrong. (if its too big, post it as an attached text file)

Link to comment
Share on other sites

:blushing: Shame on me...

One of my friends found a (the ?!) solution:

I call a cmd to start wihu, which also sets some HKLM\RunOnce-Keys to delete the installation-Directories on c:

This script calls some 'reg add', then CDs to wihu's Dir, then starts Wihu.exe. I am normally using this script to test under real conditions.

When the call for wihu is first, then the 'reg add's, all seems to work ok.

Whats this? :blink:

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...