[wpkg-users] Truecrypt silent install

Brian May brian at vpac.org
Thu Sep 24 07:31:25 CEST 2009


David N wrote:
> I am very interested for the silent install. I've tried but haven't
> had any luck.

First a disclaimer: I never got around to deploying this, have not
tested it recently, however it worked back at the time I created it...

(I haven't checked - is version 6.1a still the latest?)

First run exe file by hand, and unpack files, move unpacked files into
%SOFTWARE%\truecrypt directory.


=== cut ===
<packages>
<package id="truecrypt"
         name="Truecrypt 6.1a"
         revision="1"
         reboot="false"
         priority="0">
       <check type="file" condition="versiongreaterorequal"
path="%WINDIR%\System32\Drivers\truecrypt.sys" value="6.1.1.0"/>
       <depends package-id="perl"/>
       <install cmd='%SOFTWARE%\truecrypt\install.cmd 6.1a' />
       <upgrade cmd='%SOFTWARE%\truecrypt\install.cmd 6.1a' />
       <remove cmd='%SOFTWARE%\truecrypt\remove.cmd 6.1a' />
</package>
</packages>
=== cut ===


install.cmd

=== cut ===
"%WINDIR%\System32\sc.exe" stop truecrypt
copy "%SOFTWARE%\TrueCrypt\%1\truecrypt.sys" "%WINDIR%\System32\Drivers"
"%WINDIR%\System32\sc.exe" create truecrypt type= kernel start= auto
error= normal binPath= "%WINDIR%\System32\Drivers\truecrypt.sys"
DisplayName= truecrypt
"%WINDIR%\System32\sc.exe" start truecrypt
xcopy /E /I /Y "%SOFTWARE%\truecrypt\%1" "%ProgramFiles%\TrueCrypt"
"%SOFTWARE%\unattended\shortcut.pl" --description "Truecrypt encryption"
"%ProgramFiles%\TrueCrypt\TrueCrypt.exe"
special:AllUsersStartMenu\Programs\TrueCrypt
=== cut ===


remove.cmd

=== cut ===
del "%ALLUSERSPROFILE%\Start Menu\Programs\TrueCrypt.lnk"
"%WINDIR%\System32\sc.exe" delete truecrypt
del "%WINDIR%\System32\Drivers\truecrypt.sys"
rmdir /S /Q "%ProgramFiles%\TrueCrypt"
=== cut ===



It is possible my mail client may try to wrap these lines, will check
after I send this.

It might be possible to do this all within the packages XML file,
however the method I chose way makes the quoting requirements simpler.

Any feedback on problems, solutions, etc, appreciated.

Brian May




More information about the wpkg-users mailing list