[Interest] Qt Installer Framework - Adding custom generated file to the installation
aexojo at modpow.es
Tue Nov 19 15:12:37 CET 2013
2013/11/18 Michael Jackson <imikejackson at gmail.com>:
> I am very new to QtInstallerFramework but I have successfully created an installer for my project where I package a bunch of precompiled binaries so my developers do not have to build them. The convenience I would like to add to the installer is the ability to generate a simple text file with the values of where things got installed. I have been trying to find some tutorials and working through the documentation but I am coming up a bit short.
> It looks like for each Package I need to add a bit in the config.xml file to setup a .js script file.
I'm brand new to the installer framework too, but I think that's not
the way. The config.xml (I think is the suggested name, but not
mandatory) is for the general installer. Then, the installer works on
packages (in my case is only one). For the packages, each packages has
a package.xml (those are the names as are in the tutorial), and that
file refers (optionally) to a script.
> Inside the script file I am a bit perplexed what to do?
> function Component()
> Component.prototype.createOperations = function()
> component.addOperation("AppendFile" , "@TargetDir@/CMakeCache.txt", "set(BOOST_ROOT \"@TargetDir@/boost-1.55.0\")");
That seems correct. If you want to experiment, try running the
installer, or the "installerbase"/"installerbase.exe" with
--runoperation, followed by the parameters that you expect
addOperation() to receive.
> So that works. Can I have a "top level" script file that initially creates the file? I need to ensure that the file is written in a specific order. I tried adding a <Script></Script> section to the top level config file but that just threw errors.
That seems to be for the general installer only. If you need some kind
of "top level" thing, it seems that the way the Qt SDK is built is
with the concept of a "root", dummy package, and then all the other
ones depending on it.
Wish I could provide more help, sorry.
Alejandro Exojo Piqueras
Technova LaSalle | Sant Joan de la Salle 42 | 08022 Barcelona | www.modpow.es
More information about the Interest