Misha Koshelev wrote:
Hi, since MSDN states that any installer that requires JScript/VBScript
must make sure to install it, and since some applications require these
for install (bug #7353 and another one is there for VBScript for a
different installer), I figure there is no reason why builtin MSI cannot
use Microsoft Script if it is there (and plus when we have our own
JScript/VBScript we will be able to use it off the bat with MSI).
I have posted my initial work on this on the bugzilla for bug #7353. The
first file (a patch, will attach also) is my patch which updates
custom.c to have the appropriate handlers for the custom action types,
extracts the script from the appropriate place, writes it to a file, and
uses a framework very similar to the current thread framework for DLLs
to call my helper call_script function. This first patch, in theory,
should not have to change much (if at all), although I have not
thoroughly tested it yet so it probably will.
The second file (and attached here too) is dlls/msi/script.c, which is
where the meat and potatoes of the actual call_script function is/will
be. Right now it is pretty barebones, but it does load the script from
the file and calls it appropriately.
Now I am working on implementing the Session object, although it looks
like a wrapper around MSI functions we already have so I think it should
be doable.
Anyways, any comments on my work so far will be appreciated.
Nice work! Does MSI expose any builtin objects to the scripts (a quick
Google search indicates there should be a Session object exposed)?
--
Rob Shearman