summaryrefslogtreecommitdiffstats
path: root/src/sdk/installerbase.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fix loading of translationsJarek Kobus2015-01-261-22/+15
| | | | | | | | | | In case we hit the English translation just try to load it and break in any case. In case we hit another language we only install the translation if the qt translation was loaded properly, and break. Change-Id: I2755501c1af8cb51b38cf21e0205bcf05541fb91 Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
* rename CreateOfflineRepository to CreateLocalRepositoryChristoph Vogtländer2015-01-081-2/+2
| | | | | Change-Id: I36d7a504b27dfff8b9d10c9d90b6ff77108b9982 Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
* Remove country from most translationsKai Koehne2015-01-061-1/+1
| | | | | | | | | | | | | | | If we provide an en_us translation only this won't be picked up by users having configured 'en', or 'en_uk'. This also mirrors the naming of the qt translations. The exception is zh_CN though, because the difference between simplified and traditional characters is big. I'm not sure whether taiwanese people would rather prefer traditional characters or english. For Qt we have both zh_CN and zh_TW, maybe we will get a zh_TW in the future too... Change-Id: I73490337aef8f54da14b6feca3a035e1e405d65b Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
* Add CreateOfflineRepository configuration optionChristoph Vogtländer2014-12-111-1/+2
| | | | | | | | | | Setting CreateOfflineRepository to "true" in config.xml will create a local offline repository, same functionality as "--create-offline-repository" command line option Change-Id: I51b947157ebc27800b1e9ad0b55d139ac6e164b2 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* Add possibility to specify a control script.kh2014-12-101-0/+3
| | | | | | | | | | | | | Right now we support control scripts just as command line argument, but now we can also bundle it in the binary as well. This helps e.g. with running scripts during uninstallation, enables the possibility to modify the introduction page or enables headless installer builds. Task-number: QTIFW-495 Task-number: QTIFW-166 Change-Id: I6fee6a55db78ed28b1eeb8257a4febaa2703c04e Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* Implement a way to start the server in debug mode and API cleanup.kh2014-11-261-4/+17
| | | | | | | | | | | | 1; Passing debug as first argument to the starting server does not start the server side so the server keeps running in an endless loop. This makes it far easier to attach a debugger. 2; API cleanup and unify init function to take port, key, and mode. The address was never able to be changed anyway, so stop passing them around. Change-Id: I2a847f009ed1557a5e136e2b0006de5c62426da2 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* Expose real type of PackageManagerProxyFactoryKai Koehne2014-11-181-0/+1
| | | | | | | This allows us to store proxy settings in the factory later on. Change-Id: Ib389ccffb3163be4f5cd511be4c4b8bbe15e8a93 Reviewed-by: Karsten Heimrich <karsten.heimrich@theqtcompany.com>
* Make sure we do not fail if we can't create the lock file.kh12014-11-121-8/+13
| | | | | | | | | | | If we can't lock the file (possible missing privileges to create and lock it), we now check the running processes before we fail. Task-number: QTIFW-566 Change-Id: I821ccf8c37d6a235df49e060c59a0283bb91261c Reviewed-by: Takayuki ORITO Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com> Reviewed-by: Niels Weber <niels.weber@digia.com>
* Rewrite the isRunning implementation and remove private class.kh12014-11-121-2/+2
| | | | | | | | | | Use a more descriptive enum name. On Windows keep the lower case version of the process name instead of calling toLower() several times. Print a warning if we cannot obtain or release the lock. Change-Id: Iaaefae0359cd214290f62ce78677cb343da8823c Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com> Reviewed-by: Niels Weber <niels.weber@digia.com>
* Implement package filtering for online and offline installer.kh12014-10-301-6/+7
| | | | | | Change-Id: If17725c0d97111aff67bcc0bc060fb74bb1109cd Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com> Reviewed-by: Niels Weber <niels.weber@digia.com>
* Add LGPLv3 as new licenseKai Koehne2014-10-161-14/+7
| | | | | | | Change-Id: I61158f956894e209dccf83744b4753774676099d Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com> Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@digia.com>
* Overhaul the binary format API.kh12014-10-151-11/+5
| | | | | | | | | | | | | | Adjust some naming. Add documentation. Make the Resource class handle files only, this is sufficient to read and map inbuild resources. Keep the QResources inside the manager as well, no need to handle them separate. Remove read, write functions from collection class, the API was just unclear how to use. Still it is far from intuitive in the manager class either. If we open a Resource, we need to close it on our own case they are pointers. Change-Id: Ic8aa32a84a15ac774fe1194ba0dbb5733f7216d6 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com> Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* Fix some std::cout usage.kh12014-09-051-9/+6
| | | | | | | Fixes missing timestamps and some propably wrong conversion. Change-Id: I6106e1ea61d0840d132dd3b44cd746f023e795af Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Split and implement new installer base, update checker.kh12014-09-041-350/+196
| | | | | | | | | | | | | Based on the former patches, split the installer base into its own class. Use the new binary content read functions. Adjust uses to match the new classes. Adjust installer base /update checker signature and inheritance. Remove all now superfluous functions from binary content. Core engine instantiates the operations now, makes reading and writing more generic. Move product key check into QInstaller namespace. Make use of the new command line parser. Change-Id: I00aff79085b69ce627906881b43f374681ea7e91 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Fix listing of resourcesKai Koehne2014-08-271-1/+1
| | | | | | | In commit 6466dbd11190 the list iterator advances two times in one go. Change-Id: I24aae53b764732b04159261921365c99518ee3e9 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Make listing of resources less verboseKai Koehne2014-08-271-10/+9
| | | | | | | Print the resources only once, and hide Qt internal resource paths. Change-Id: I4fce72424b4ab94d44d63e16b6ae89cff7ccac72 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Fix Typo resulting in wrong error messageNiels Weber2014-07-171-1/+1
| | | | | Change-Id: I62e91bcb3bfe73ea0d23f6cdf6938af10fffd8cc Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Move class BinaryContent into its own file.kh12014-07-151-1/+1
| | | | | | | Prepare for QTIFW-292 and QTIFW-345. Change-Id: I938b5aa728e8f81eb9521df5753ad80ac630d96e Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Move updater class into sdk binary and rename to UpdateChecker.kh12014-07-151-23/+8
| | | | | | | | | | | | | Remove some now superfluous methods from binary format. Adjust initializing some objects as we need them not earlier. Unify implementation of accessing the right binary to read the content from. UpdateChecker does now have its own run checker, makes it possible to run the binary even if a e.g. maintenace tool is already running. Change-Id: I94f32f7f38b62b5aee433753abc2fe72e879ddc9 Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Adjust parsing the arguments, we now only need them for the parser.kh12014-07-141-7/+5
| | | | | Change-Id: Ibf4ee8358f7eb75854c8b6ca9be25b1288eb045d Reviewed-by: Niels Weber <niels.weber@digia.com>
* Remove ubuntu hack that should be no longer necessary.Niels Weber2014-07-101-26/+0
| | | | | Change-Id: I698b83cbbd9fd1b8f2ed3bb52cdb2849ef1e7e1c Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Use QCommandlineParser, remove some developer related options.kh12014-07-101-224/+248
| | | | | | | | | Remove: --runoperation, --undooperation, --update-installerbase --dump-binary-data, Script, Updater, ManagePackages Some of these options will go into a separate dev related tool. Change-Id: I31084f60d3ed9a33abeb3df90fadf939d3b4c0a7 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Rename settings in config.xml filejkobus2014-07-071-2/+2
| | | | | | | | | | | Rename UninstallerName to MaintenanceToolName (change its default value to "maintenancetool"). Rename UninstallerIniFile to MaintenanceToolIniFile. Change-Id: Ic8ceae80b43c6793ae9b0baacea2ea374a0f90d1 Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com> Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Replace Q_OS_MAC with Q_OS_OSXNiels Weber2014-07-031-4/+4
| | | | | | | | Q_OS_MAC also refers to iOS. Change-Id: I91603d0add90a0f3948453a6b9628814b0d9f80c Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Initialize both client and server with default values.kh12014-06-231-1/+1
| | | | | Change-Id: I51934b0de77b1062153f5f60be44d4bcf4be5ee5 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Fix replace maintenance tool binary.kh12014-06-041-1/+2
| | | | | | | | | | Missing QInstaller::init() did lead to crashes cause of uninitialized lib7z (in case we used a zipped file as input). In verbose mode console did not show up. Get rid of KDSaveFile as it complicated to code unnecessary. Change-Id: I5911c895d7763e4ce919b1d4761568e47b244b1b Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Replace client-server classes and update implementations.kh12014-06-031-3/+5
| | | | | | | | | | Remove superfluous file engine tests. Introduce auto test for newly added client server classes. Fix some wrong implementations serverside for settings array handling and broken arguments in process wrapper. Replace all other parts that with new implementations. Remove now unused classes. Change-Id: I6f9e836993096a2c2c06b06f2b06d7aa4b287e56 Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Avoid 'Too many open files' on MacKai Koehne2014-05-141-1/+9
| | | | | | | | | Increase the number of file descriptors that the process can open to the maximum allowed. By default, Mac OS X only allows 256 file descriptors, which can easily be reached. Change-Id: Ie4e5ab1051d8e3bf1cb39747f629360915a22d97 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Fix --checkupdates shows error dialog if network is down.kh12014-01-081-12/+7
| | | | | | | | | | | | Task-number: QTIFW-431 We need to add a separate console window in case we run on windows, though we can't use a gui application as the lib might popup message boxes. (MessageBoxHandler checks against a running core application) Change-Id: Idad8dff44c6c0bfb0bb45e8a0fb408b3db832c3c Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Adjust ProductKeyCheck API. (in preparation for multiple pages)kh12013-11-251-0/+3
| | | | | Change-Id: I69d0fc9842df7fb564db57067da5f40e002b61de Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Open a console window (Windows) to show the verbose output.kh12013-11-251-1/+10
| | | | | | | | Task-number: QTIFW-403 Change-Id: I5ab5221e8035e7d47c8d368c552f930db65931d9 Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Implement a way to replace the default resource.kh12013-10-161-0/+5
| | | | | | Change-Id: I2e362d255bf2526f216cbb872bbb64d37383d229 Reviewed-by: Tim Jenssen <tim.jenssen@digia.com> Reviewed-by: Michal Klocek <michal.klocek@digia.com>
* Be more verbose on the resource tree.kh12013-10-161-17/+9
| | | | | Change-Id: I1e079f94767d95d997ebb6d758c40e605fd36c75 Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Make sure we parse and pass arguments as early as possible.kh12013-10-161-53/+53
| | | | | | Change-Id: I384f036a24e3eb648bde0fa8e40ab8dcb0779e7b Reviewed-by: Michal Klocek <michal.klocek@digia.com> Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Fix selected translation in special circumstances.Niels Weber2013-08-091-6/+16
| | | | | | | | | | | | In cases where there where multiple uilanguages, sometimes the wrong language was chosen for the Qt localisation. Also, use the standard matching for locales for the ifw translation as well. Task-number: QTIFW-324 Change-Id: I2c4cd079baa3d1ce4c5c69bf6692ba313616f722 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Implement dedicated translation settings support.kh12013-06-261-27/+32
| | | | | | | Change-Id: I41dd23f01e9b511c217fee7f736d9187b8a8623a Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Tim Jenssen <tim.jenssen@digia.com> Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Check os-release instead of lsb-releaseNiels Weber2013-04-111-2/+2
| | | | | | | Should be more standard. Change-Id: I531c19a2139bf1e1a2d307997e1ed01c33b50249 Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Don't hard-code version in sourcesKai Koehne2013-02-141-1/+1
| | | | | | Change-Id: I1a1f3a22d7360f9a9e8036c76b721aa740e612e9 Reviewed-by: Niels Weber <niels.weber@digia.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Add --binarydatafile argument to installerbase.kh12013-02-071-8/+25
| | | | | | | | | | | Task-number: QTIFW-214 Simplifies testing an already existing installer or maintenancetool using a newer installerbase or IFW build. Change-Id: I11df629614eb1c2c15ecc28af37d8e40b5173a79 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com> Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Add 2013 to the copyright.Niels Weber2013-02-051-1/+1
| | | | | Change-Id: If64730ba7203d1a910a426c0d9c9a738ecfeff4b Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Change copyright headers from Nokia to DigiaSergio Ahumada2012-12-211-18/+27
| | | | | Change-Id: Id55a71a6ee24b234739b6066e11e9c1f2e389f73 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Fix 207cfebb778b.kh12012-11-201-3/+6
| | | | | | | | | Obviously there was a problem with the indexOf call. Also once we omit the -i, the input could be -o or even worse the output path. Change-Id: I60a970c7e2857195e214cf2441d87468d297a7c2 Reviewed-by: Kai Koehne <kai.koehne@digia.com> Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Some changes to start compile with Qt5.kh12012-11-201-1/+1
| | | | | Change-Id: Ie6a3ba7b3c0b24fc292d0d7444ae920dfa866a54 Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Implement cmd option to dump binary content into given dir.kh12012-11-141-0/+30
| | | | | | | | | | Reuse already existing functionality, just fix the hard coded "repository" path name. Also check if we are running offline only, as otherwise there will be no data section. Change-Id: Iac45d89822fceee9e527afe0dc9eb589e39e16e7 Reviewed-by: Kai Koehne <kai.koehne@digia.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
* Move help switch further up, so it's allways available.kh12012-11-141-3/+5
| | | | | Change-Id: I3a8b2ae4b7445ba5ca6ab93f10e57e9fc1928a7b Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Store installer data in a separate file on Mac to support code signingPasi Matilainen2012-09-261-0/+8
| | | | | | | | | | | | | Code signing fails on Mac OS X if there's any extra data after the link edit segment in a binary, so store the installer data in a separate file inside the bundle. Task-number: QTIFW-153 Change-Id: Ie1edf21212b4a3bc5b6f32eea3f5d61e8800a0d5 Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Simo Fält <simo.falt@digia.com> Reviewed-by: Niels Weber <niels.weber@digia.com>
* Add new commandline argument.kh12012-08-171-0/+2
| | | | | | | | | | | | In case we run an offline installer, --create-offline-repository will dump the whole installer content into the install directory and add an extra url to the repositories pointing to the mentioned local repository. This allows an offline user to add packages without the need of a new installation. Change-Id: I3e7eb0c56f632b74f5ea41b96bf3d9be83173f41 Reviewed-by: Tim Jenssen <tim.jenssen@nokia.com> Reviewed-by: Niels Weber <niels.2.weber@nokia.com>
* Make all Ubuntu versions use cleanlooks style.Niels Weber2012-08-031-5/+2
| | | | | | | | | | Doesn't make any sense to limit this to specific versions as the old ones go away anyway and all new ones exhibit this issue. Change-Id: I20fb4d13f2d1933c92fa09727f3d467d5210d24f Reviewed-by: Rainer Keller <rainer.keller@nokia.com> Reviewed-by: Tim Jenssen <tim.jenssen@nokia.com>
* add the installer create datetime to --versionTim Jenssen2012-06-121-1/+12
| | | | | | | | | | - binarycreate patches the installerbase to add the installer create datetime - output is now: Installer creation time 2012-06-08 - 17:39:43 IFW Version: "1.0.0", Installer base SHA1: "7031ecf", Build date: "Jun 8 2012". Change-Id: I8f82c6942eefaf49e5ad8605577a0034a7502a6c Reviewed-by: Niels Weber <niels.2.weber@nokia.com>
* now we can setTempRepositories from script sideTim Jenssen2012-04-271-6/+5
| | | | | | | - this makes testing with autoscript more convenient Change-Id: I93e25570cd9f2b1431412a601476947fc9a046d9 Reviewed-by: Karsten Heimrich <karsten.heimrich@nokia.com>