I'm trying to use wpkg to install tightvnc (i prefere it over ultra)
and apply some autoconfiguration.
I've do:
<package
id="tightvnc"
name="TightVNC server"
revision="129"
priority="10"
reboot="false">
<check type="uninstall" condition="exists" path="TightVNC 1.2.9" />
<install cmd="%SOFTWARE%\WPKG\tightvnc-1.2.9-setup.exe /sp-
/verysilent" />
<install cmd="%ProgramFiles%\TightVNC\WinVNC.exe -reinstall" />
<install cmd="%ProgramFiles%\TightVNC\WinVNC.exe -servicehelper" />
<install cmd='netsh firewall add allowedprogram program =
%ProgramFiles%\TightVNC\WinVNC.exe name = "Launch TightVNC Server"' />
<upgrade cmd='%SOFTWARE%\WPKG\tightvnc-1.2.9-setup.exe /sp-
/verysilent' >
<exit code="0" reboot="true" />
</upgrade>
<remove cmd='%ProgramFiles%\TightVNC\unins000.exe /SP- /VERYSILENT' />
</package>
And this seems to work well. Now i wont to setup tightvnc, and to be
able to change settings (most notably, password) via wpkg.
I've done:
<package
id="tightvnc-settings"
name="TightVNC server settings"
revision="1"
priority="100"
reboot="false">
<depends package-id="tightvnc"/>
<check type="file" condition="exists" path="%ProgramFiles%\TightVNC\1"
/>
<install cmd="%WPKGROOT%\packages\tightvnc.bat 1" />
<upgrade cmd="%WPKGROOT%\packages\tightvnc.bat 1" />
</package>
where tightvnc.bat are:
:: start, restart or apply settings to tightvnc
::
net stop "VNC Server"
regedit /s %WPKGROOT%\packages\tightvnc.reg
net start "VNC Server"
:: fake the stupid...
::
echo "%1" > %ProgramFiles%\TightVNC\%1
:: we ignore errors...
::
exit 0
note the hack to create the file %ProgramFiles%\TightVNC\%revision%,
because the condition (also if there's no check condition!) are checked
before and after installation, so this package entry will fail.
What i'm missing? I've looked at other examples on:
http://wpkg.org/index.php/Category:Changing_Windows_settings
but i've not found the clue...
PS: it is normal that on first installation a /synchronize only does
nothing, and i've to add a /force to instal something?
--
dott. Marco Gaiarin GNUPG Key ID: 240A3D66
Associazione ``La Nostra Famiglia'' http://www.sv.lnf.it/
Polo FVG - Via della Bontà , 7 - 33078 - San Vito al Tagliamento (PN)
marco.gaiarin(at)sv.lnf.it tel +39-0434-842711 fax +39-0434-842797
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
wpkg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wpkg-users