From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 75476 invoked by alias); 23 Nov 2017 16:37:45 -0000 Mailing-List: contact cygwin-apps-cvs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: cygwin-apps-cvs-owner@sourceware.org Received: (qmail 75457 invoked by uid 9795); 23 Nov 2017 16:37:45 -0000 Date: Thu, 23 Nov 2017 16:37:00 -0000 Message-ID: <20171123163745.75329.qmail@sourceware.org> From: jturney@sourceware.org To: cygwin-apps-cvs@sourceware.org Subject: [setup - the official Cygwin setup program] branch topic/libsolv, created. release_2.882-62-g75a2e03 X-Git-Refname: refs/heads/topic/libsolv X-Git-Reftype: branch X-Git-Oldrev: 0000000000000000000000000000000000000000 X-Git-Newrev: 75a2e03ae765ca494e07124d20a061c6617e2139 X-SW-Source: 2017-q4/txt/msg00035.txt.bz2 at 75a2e03ae765ca494e07124d20a061c6617e2139 (commit) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=75a2e03ae765ca494e07124d20a061c6617e2139 commit 75a2e03ae765ca494e07124d20a061c6617e2139 Author: Jon Turney Date: Mon Nov 6 18:02:08 2017 +0000 More crash avoidance in SolvableVersion member functions The following call-stack means we end up calling SolvableVersion methods before packagedb::prep(), i.e. before attributes have been internalized, so their values aren't available. PickView::init_headers PickView::refresh PickView::init ChooserPage::createListview ChooserPage::OnInit We call PickView::refresh again after we've computed the initial solution, so the columns always end up with the correct width. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=715f0ed69bb592e3fb817fb7fabbe753de7f82f9 commit 715f0ed69bb592e3fb817fb7fabbe753de7f82f9 Author: Jon Turney Date: Sat Nov 4 18:01:49 2017 +0000 Correctly order preparing packagedb for chooser Do packagedb::prep() in ChooserPage::OnActivate(), as doing it in OnInit() is wrong, as that only gets called once (but lazily). Make packagedb::prep() idempotent after packagedb::init(), so it doesn't do it's work again, if we come back to chooser from a later page. Re-arrange applying command line package selection, and determining the initial solution, which should only happen once, but after packagedb::prep() https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=2d2a93a50ec6304d27005cc1c3093afc98e4d136 commit 2d2a93a50ec6304d27005cc1c3093afc98e4d136 Author: Jon Turney Date: Thu Nov 2 14:15:04 2017 +0000 Ensure packagedb and underlying solver pool is empty before we read setup.ini We need to make sure the packagedb is empty if we step backwards to here. v2: Also clear solver stored in SolverSolution, which holds a pool pointer https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=2d21e2434bb54fb4c0e00e38a0fe845248c9f085 commit 2d21e2434bb54fb4c0e00e38a0fe845248c9f085 Author: Jon Turney Date: Sat Nov 4 16:09:01 2017 +0000 Simplify LocalDirPage::OnNext() Never go directly to IDD_CHOOSE from LocalDirPage::OnNext(), go to IDD_INSTATUS with WM_APP_START_SETUP_INI_DOWNLOAD (if source == IDC_SOURCE_LOCALDIR), otherwise IDD_NET (which eventually leads there) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=7b90c3559c27e38b4ec5bf396886f40587957f07 commit 7b90c3559c27e38b4ec5bf396886f40587957f07 Author: Jon Turney Date: Sat Nov 4 15:37:58 2017 +0000 Make do_ini() succeed if found_ini_list is empty Rather than count the number of .ini files read in do_{local,remote}_ini, and assume success if greater than zero, actually track if an error occured. This is a subtle change of behaviour if more than one .ini file is read: previously all we needed was one to succeed, now we need them all to succeed. (Note that site_list should never be empty, and it's still an error if we don't find an .ini file from a site, so the practical effect is to make do_local_ini succeed with an empty found_ini_list) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=2e0280064c14315dd8673168c1083a4c77fc8b27 commit 2e0280064c14315dd8673168c1083a4c77fc8b27 Author: Jon Turney Date: Mon Oct 30 15:09:33 2017 +0000 Revert "Bump the installed.db version to 4" This reverts commit cbf84482f992011eca70c560a0584bc588db80d6. Do this temporarily so people can test but go back to using setup 2.882 without too much inconvenience... https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=e12740980f2f6955a5ea70a6b5bbe2d115829e09 commit e12740980f2f6955a5ea70a6b5bbe2d115829e09 Author: Ken Brown Date: Fri Oct 27 14:47:22 2017 -0400 Bump the installed.db version to 4 Starting with the commit 'Remove the function filemanip.cc:base', setup correctly parses version numbers of the form e:v-r in installed.db. Bump the version of installed.db to reflect the fact that older setup doesn't parse filenames containing colons correctly. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=2c86c4662b49edf4851e696b4c99d7ef69c7ebc4 commit 2c86c4662b49edf4851e696b4c99d7ef69c7ebc4 Author: Ken Brown Date: Fri Oct 27 14:47:21 2017 -0400 Remove the function filemanip.cc:base() This was called only on plain filenames, not full pathnames, so it was not needed. Moreover, it wasn't correctly handling filenames containing colons. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=afc55683143b54274951f8c32d8ac8590eaceecf commit afc55683143b54274951f8c32d8ac8590eaceecf Author: Jon Turney Date: Sun Oct 29 17:20:51 2017 +0000 Fix invalid iterator use in packagedb::removeEmptyCategories() https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=f68c26124df2fb3d21486493752ac4b391c28d55 commit f68c26124df2fb3d21486493752ac4b391c28d55 Author: Ken Brown Date: Sat Oct 28 13:46:19 2017 -0400 Avoid clobbering installed.db when no setup.ini is found If no setup.ini is found, do_ini_thread is never called. But we need to ensure that packagedb::read is called, or else installed.db gets emptied. Move the calls to packagedb::read and other packagedb functions from do_ini_thread to ChooserPage::OnInit. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=92ab2021f597f19b5eb4d3da5d4916da839b1b2d commit 92ab2021f597f19b5eb4d3da5d4916da839b1b2d Author: Jon Turney Date: Thu Oct 26 19:13:45 2017 +0100 Check for libregex at configure time Done properly this should use PKG_CHECK_MODULES, rather than checking for the header... https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=722403152895a14e6bf1851b6c847eccb137cb03 commit 722403152895a14e6bf1851b6c847eccb137cb03 Author: Jon Turney Date: Thu Oct 26 13:27:55 2017 +0100 Update build instructions https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=d226574e5bbb9c4a05725c4845f68f75373fd43e commit d226574e5bbb9c4a05725c4845f68f75373fd43e Author: Ken Brown Date: Fri Oct 20 06:59:54 2017 -0400 Don't override a Skip selection Introduce SolverTasks::taskSkip, and generate it when the user chooses to Skip a package that the solver wants to install. Implement it by sending a SOLVER_LOCK command on the package name. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=713719e3b5cf1716c5005fe904082d84b4fe5358 commit 713719e3b5cf1716c5005fe904082d84b4fe5358 Author: Ken Brown Date: Thu Oct 19 14:44:45 2017 -0400 Fix the functionality of taskKeep A taskKeep is generated whenever the user wants to keep an installed version that's different from the default_version, where the latter is whatever the solver has chosen. We need to make sure that default_version is set appropriately wherever it is needed. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=a06f9553ebf0a8e748c582a81bcf86c74db31d00 commit a06f9553ebf0a8e748c582a81bcf86c74db31d00 Author: Ken Brown Date: Tue Oct 17 08:12:48 2017 -0400 Extend the SolvableVersion member functions to the empty package Currently some of these functions cause crashes when the package is empty because the libsolv function pool_id2solvable unconditionally dereferences its first argument ('pool'). https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=5b697fbc462c4ce7d9096261ac8834d7194e1885 commit 5b697fbc462c4ce7d9096261ac8834d7194e1885 Author: Jon Turney Date: Mon Oct 9 18:10:52 2017 +0100 Take command line package/category install/uninstall into account Rather than overwriting the packagedb changes made from processing command line options in ChooserPage::OnInit(), use the 'initial' flag to changeTrust() in createListview() to take them into consideration. --upgrade-also and --force-current are now handled directly. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=9fca9240ab412d3aa8fd0220d3dbdc068e5f562d commit 9fca9240ab412d3aa8fd0220d3dbdc068e5f562d Author: Jon Turney Date: Mon Oct 9 15:37:06 2017 +0100 Change UI to add 'Sync' choice and change 'Test' to checkbox Set the initial update mode in UI correctly: - 'Sync', if --force-current option is used - 'Keep', if packages are selected on command line without --upgrade-also - 'Current', otherwise Add mapping of 'Sync' to SolverSolution::updateForce to mapping of UI update mode to solver update mode. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=c3856f2b60a817ec222046bdcfa3326a1d057038 commit c3856f2b60a817ec222046bdcfa3326a1d057038 Author: Jon Turney Date: Mon Oct 9 15:05:22 2017 +0100 Add distupgrade support to solver Also, ignore change transactions (these are usually vendorchange as we forget the vendor for installed packages) Also, don't put unknown type transactions into the transaction list https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=669c403c32e1803203eb7e6eaafc4ebc2a02b5fd commit 669c403c32e1803203eb7e6eaafc4ebc2a02b5fd Author: Jon Turney Date: Sat Sep 30 23:23:29 2017 +0100 Non-existent source packages aren't accessible for installation Prevent the src checkbox appearing for source packages which don't exist https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=ddef397e70f7db5f990d2b00774756f4f004ef5a commit ddef397e70f7db5f990d2b00774756f4f004ef5a Author: Jon Turney Date: Fri Sep 29 14:46:46 2017 +0100 Use solver for initial pick list when upgrading Use the solver to determine initial pick list for Curr or Test, rather than directly picking packages. Thus the solver's initial solution in the pending view should be the first thing the user sees. Note: Keep is magical, and the package db pick list gets reset by ChooserPage::keepClicked(), rather than going through changeTrust(). We don't unify these two paths, because the trust level passed to changeTrust() gets recorded in PickView::defTrust and used by the line picker in some mysterious way, and seems to only be expected to be TRUST_CURR or TRUST_TEST. There's probably a subtle bug here, in that the line picker might behave differently depending on if Curr or Test was selected before Keep. Drop passing upgrade flag to solver run after the user has made their selections: the picker selection now reflects what the user is asking for. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=74a08e59e521cf3c8a630999471f027cd007ecdb commit 74a08e59e521cf3c8a630999471f027cd007ecdb Author: Jon Turney Date: Fri Sep 29 14:18:44 2017 +0100 Make removeEmptyCategories() explicit, rather than a side effect of defaultTrust() It's unclear that this can ever do anything. The list of categories is built as we see packages in those categories, so I don't know how we can ever get an empty category. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=dd8ed6f0b3d0d2ee9e23691a2b2dd7c403ff8ea7 commit dd8ed6f0b3d0d2ee9e23691a2b2dd7c403ff8ea7 Author: Jon Turney Date: Fri May 26 14:30:40 2017 +0100 Handle 'Source:' lines in setup.ini This is somewhat awkward: Storing the source package by Id rather than by name is looking a bit like a premature optimization, but being to able to refer to source packages by Id is very handy. If the src pkg isn't seen until after the pkg, we don't know what it's Id will be. So we have to go back and fixup the Ids after we've seen all packages. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=157ccf00e7f171e4cad38048d8af338d726e0fc6 commit 157ccf00e7f171e4cad38048d8af338d726e0fc6 Author: Jon Turney Date: Tue Sep 26 19:43:12 2017 +0100 Link with libregex rather than libgnurx Use -lregex rather than -lgnurx, as the Fedora mingw{32,63}-libgnurx cross-packages only contain the library under that name. (The Cygwin mingw63-{i686,x86_64}-libgnurx cross-packages have both names). https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=0a77babe95da48ce676f3de12ed6f0137144e7bc commit 0a77babe95da48ce676f3de12ed6f0137144e7bc Author: Ken Brown Date: Sat Sep 16 11:39:40 2017 -0400 Allow user to refuse the default problem solutions Add new method SolverSolution::db2trans to change the solver's transaction list to reflect the package database. Use it if the user refuses the default problem solutions. Reinstate warning that this could cause breakage. Remove PrereqPage::OnMessageCmd, which is no longer needed (and which disallows clicking Next if the "Accept default problem solutions" box is unchecked). https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=e8a3b982573a4bc5e445f4394961b748250d66a2 commit e8a3b982573a4bc5e445f4394961b748250d66a2 Author: Ken Brown Date: Sat Sep 16 11:28:37 2017 -0400 Add a ficitious "base" package that requires all Base packages Modify the solver's problem report so that it refers to "Base packages" rather than the "base" package. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=241f9d6cb7fb1c54332a0820689e2965b9f59238 commit 241f9d6cb7fb1c54332a0820689e2965b9f59238 Author: Ken Brown Date: Sat Sep 16 11:23:04 2017 -0400 Mention how you can see what packages were added to resolve dependencies https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=3a28cc8c0ad1cb574b65e4c6f89c05275dd688bd commit 3a28cc8c0ad1cb574b65e4c6f89c05275dd688bd Author: Ken Brown Date: Fri Sep 8 11:16:24 2017 -0400 Add new member function SolverSolution::trans2db This resets the package database to reflect the solver's transaction list. Call this if the user clicks Back on the Prerequisite page, to allow reviewing and making changes before accepting the solver's solution. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=90da4df2f7853d7b6ad345d8541a9b1c34fdb625 commit 90da4df2f7853d7b6ad345d8541a9b1c34fdb625 Author: Ken Brown Date: Sat Sep 16 10:50:37 2017 -0400 Factor out SolverTasks::setTasks() Move the code from prereq.cc that makes a solver task list from packagedb state into a new function SolverTasks::setTasks. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=02506a72df8af478146fdd6c53426d8f1099f50b commit 02506a72df8af478146fdd6c53426d8f1099f50b Author: Ken Brown Date: Sat Sep 2 14:35:58 2017 -0400 Simplify code in install.cc Avoid passing around a packagemeta, when all we use is the package name. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=1d470644005060368d140d38f3015ad130987e06 commit 1d470644005060368d140d38f3015ad130987e06 Author: Ken Brown Date: Mon Sep 4 16:44:31 2017 -0400 Fix 'SolverTasks::taskList' typedef Remove the '&'. This was causing source installs to all refer to the same package, due to the call to q.add(pkg->desired.sourcePackage(), SolverTasks::taskInstall) in PrereqChecker::isMet. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=b020f7fc9e3d065853cca95edc56c3789c561e5c commit b020f7fc9e3d065853cca95edc56c3789c561e5c Author: Ken Brown Date: Sat Sep 2 14:27:52 2017 -0400 Download only the packages being installed https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=9a9bad7455223f32b49ccefc10b5429729a2509a commit 9a9bad7455223f32b49ccefc10b5429729a2509a Author: Ken Brown Date: Wed Sep 6 10:44:27 2017 -0400 Don't create an "_installed_test_" repo This prevents libsolv from knowing that an installed test release is installed, since pool->installed is "_installed". https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=55d46bd142e883959b331f9213fa96a8d44d31b7 commit 55d46bd142e883959b331f9213fa96a8d44d31b7 Author: Ken Brown Date: Tue Sep 5 22:22:23 2017 -0400 Allow the installation of test packages without setting "Test" globally Instead of disabling test repos when "Test" is not selected, just give them lower priority than ordinary repos. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=433ae14129bb21e2903a1c2517740c289f005b17 commit 433ae14129bb21e2903a1c2517740c289f005b17 Author: Ken Brown Date: Sat Sep 16 10:06:26 2017 -0400 Ask solver to check dependencies of installed packages https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=7be74865722ee835829aaf2ed60961ad601a96f8 commit 7be74865722ee835829aaf2ed60961ad601a96f8 Author: Ken Brown Date: Sat Sep 2 12:37:29 2017 -0400 Improve the reading of installed.db When creating a packageversion for a package listed in installed.db, use the information for the installed version rather than the "current" version. Add a new function packagedb::findBinaryVersion to help with this. Get as much information about an installed information as possible from the prior reading of setup.ini. Improve detection of installed test releases. An installed test release might not appear in setup.ini because it is no longer available (e.g., it might have been replaced by a newer test release). Detect this by comparing its version to the current version. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=bb293fc114e51ffd8cdaf234d2a8296bb3ddbb5a commit bb293fc114e51ffd8cdaf234d2a8296bb3ddbb5a Author: Jon Turney Date: Fri May 26 14:30:40 2017 +0100 Add a PackageSpecification() constructor which takes a package name and version https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=b709651c5a88d83ba560766865b2f63af16f3c0a commit b709651c5a88d83ba560766865b2f63af16f3c0a Author: Ken Brown Date: Sat Sep 16 07:19:55 2017 -0400 Add SolvableVersion::obsoletes() v2: Add SolvableVersion::obsoletes(), factor out key-to-deplist code from SolvableVersion::depends() as SolvableVersion::deplist() https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=8a85fa8c70489dea6a03e07965e0f09989d2a0d1 commit 8a85fa8c70489dea6a03e07965e0f09989d2a0d1 Author: Ken Brown Date: Sat Sep 2 11:57:25 2017 -0400 Fix setup.ini parsing The IniDBBuilderPackage::process function wasn't fully resetting the addPackageData for a new version of a package. This caused SHA512 failures among other things. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=942e8b1fbc1236220a90aa75676a187ccc09be7d commit 942e8b1fbc1236220a90aa75676a187ccc09be7d Author: Ken Brown Date: Wed Aug 30 17:36:13 2017 -0400 Don't override a Keep selection https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=ee6f272768598eed0677218c0bf8347ef8fd5406 commit ee6f272768598eed0677218c0bf8347ef8fd5406 Author: Jon Turney Date: Mon May 22 18:04:02 2017 +0100 Add obsoletes: support Note that we need separate depends and obsoletes nodelists v2: Reset "obsoletes" between packages. Also add a debugging statement. (kbrown) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=0ab28d15b0222a2c2b8e04d3fddd057dbd96ec55 commit 0ab28d15b0222a2c2b8e04d3fddd057dbd96ec55 Author: Jon Turney Date: Fri May 19 11:26:07 2017 +0100 Download/checksum/install/uninstall what transaction wants Some of this goes rather around the houses to avoid lots of churm: In lots of cases, we're looking up packagemeta for a given packageversion just so we can use the pacakgemeta to access the name, which we could do via packageversion just as easily. We do actually need packagmeta for a couple of things: To note the package as installed/uninstalled, and to note postinstalls scripts. If IncludeSource is on source packages installs will have been added to the task list in post-processing, so we don't need to handle that specially anymore. Source packages to be installed are kept in a separate queue as they are installed differently to binary packages (root is /usr/src, install isn't recorded, etc.) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=05f2c2aaab645dc8b536b597875c2fef82a62366 commit 05f2c2aaab645dc8b536b597875c2fef82a62366 Author: Jon Turney Date: Sat Apr 29 15:43:52 2017 +0100 Use solver to check for problems and produce a list of package transactions Convert chooser UI selections into a SolverTaskList Apply SolverSolution to that task list (with choice of keep, upgrade, upgrade with test, IncludeSource) to produce a vector of SolverTransactions. Store a solution object in packagedb The transaction list returned by the solver is postprocessed to add reinstall and IncludeSource actions Very crudely present solver problems in the PrereqChecker page UI, as text. Change tickbox to say "accept default solutions" and don't allow to preceed unless those solutions are accepted (ideally we would have a UI to choose solutions). Remove warning about missing dependencies. Also pass initial trust state to PrereqChecker v2: Fix comment typo (kbrown) Tweak comment in OnActivate() (kbrown) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=ce47ca282760a3de07d256c9e9cfefbae8ca50d9 commit ce47ca282760a3de07d256c9e9cfefbae8ca50d9 Author: Jon Turney Date: Sat Apr 29 15:39:46 2017 +0100 Drop in SolvableVersion as a replacement for packageversion https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=202f36768bbd45c0cb236da84424b05c0d7d1dd6 commit 202f36768bbd45c0cb236da84424b05c0d7d1dd6 Author: Jon Turney Date: Fri Apr 28 17:39:26 2017 +0100 Remove packageversion class Remove packageversion, _packageversion, defaultversion classes https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=578af44f713289a327d769cd62412066e09f7baf commit 578af44f713289a327d769cd62412066e09f7baf Author: Jon Turney Date: Fri Apr 28 15:26:05 2017 +0100 Remove cygpackage class v2: Fix typo in bootstrap.sh (kbrown) https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=123f29dc27912a6666fd4382097b04ac7bc2f6fc commit 123f29dc27912a6666fd4382097b04ac7bc2f6fc Author: Jon Turney Date: Fri Apr 7 21:52:17 2017 +0100 Change to using a libsolv pool for storing package information Add class SolverVersion, a wrapper around a Solvable Id. The interface is similar to class packageversion, the name change is just to make sure I've got everything. Place test packages into separate repos. Expressing that curr: packages are preferred to prev: ones when that is not the version number ordering should be done with epoch numbers. Wire up various bits of data in packageversion to Solvable attributes, including sourcepackage, stability, archive (packagesource) and depends. Store sourcePackage() by the id rather than name, for much faster lookup. SolverVersions for the same package can be ordered and compared by evr. Factor out packagedb:addBinary() and also use it in IniDBBuilder, rather that inlining the process of adding a package there. Add an analagous packagedb:addSource() to do the same thing for source packages. Change to reading installed.db after setup.ini's have been read, so we can supplement the installed.db packages with information from setup.ini. Make packagemeta::add_version() check for successful insertion of version. Record the version at a stability level. The last version wins in setting curr/test. Use a Solver object inside packagedb https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=ab68ed5bd3834d86d64f3e74428228b830df4ea5 commit ab68ed5bd3834d86d64f3e74428228b830df4ea5 Author: Jon Turney Date: Mon Apr 24 20:17:36 2017 +0100 Store package stability in class packageversion https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=bee9b8f2fc94386e410a8199e41b640515fbab5f commit bee9b8f2fc94386e410a8199e41b640515fbab5f Author: Jon Turney Date: Wed Apr 26 16:22:30 2017 +0100 Hoist scan() up from packageversion to packagemeta https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=e88a43f8597b9e5d83895ffd93ee094fe01635c0 commit e88a43f8597b9e5d83895ffd93ee094fe01635c0 Author: Jon Turney Date: Tue Apr 25 23:44:08 2017 +0100 Hoist uninstall up to Installer::uninstallOne() This calls packagemeta, which applies to packageversion (which delegates through packageversion_ to cygpackage) to return lines from the .lst.gz file (pretending that we know it contains a file list for that specific version) and to remove the .lst.gz file when done. Move this all up into Installer::uninstallOne(), where it's all in the same place as the operation it is reversing, Installer::installOne(). https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=375e42110f207ba3e4250f5166f54f0b5d7f9eaa commit 375e42110f207ba3e4250f5166f54f0b5d7f9eaa Author: Jon Turney Date: Wed Apr 26 15:20:14 2017 +0100 Hoist pick() up to packagemeta We are always writing packagemeta.desired.pick(bool, packagemeta). This kind of suggests something not quite right. The pick flag means install/reinstall, so despite being stored per packageversion, is only significant to download/install for the desired version. There's a slight wrinkle in that we want to also set/clear this flag for the source packageversion. We can't change this to point to packagemeta rather than packageversion, as that may not be the same for all versions, so instead just track this flag separately as srcpicked. Note that there is still a complicated mapping between the state of desired and pick and the action represented in the UI: desired == empty, installed == desired : skip desired == empty, installed != desired : uninstall desired == installed, pick == true : reinstall desired == installed, pick == false : keep desired != installed, pick == true : upgrade desired != installed, pick == false : invalid https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=9a590fe9f4b67a6691ab4fb503f5289737668817 commit 9a590fe9f4b67a6691ab4fb503f5289737668817 Author: Jon Turney Date: Tue May 23 22:19:15 2017 +0100 Hoist addScript() etc. up from packageversion to packagemeta We're only interesting in storing scripts and later running them from the desired version as we install it, so despite being stored per packageversion, this is only significant for the desired version. Hoist it up from packageversion to packagemeta. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=a4e8c77b24150cef1ba150a8080cac778c79026a commit a4e8c77b24150cef1ba150a8080cac778c79026a Author: Jon Turney Date: Sat May 20 16:17:44 2017 +0100 Factor out reading installed.db Rather that doing implicitly the first time a packagedb is constructed, do it explicitly at a certain point in time that is early enough. https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/setup.git;h=71042e2a4732f19d687a32fac16d5773ce549c07 commit 71042e2a4732f19d687a32fac16d5773ce549c07 Author: Jon Turney Date: Fri May 5 12:36:42 2017 +0100 Opaque how PackageDepends is stored We want to be more opaque about how the PackageDepends for a packageversion is stored, so rather than exposing a pointer to a PackageDepends object inside class packageversion, access it by value. This also makes us be more explicit about set/get of package depends() Fix some iterations to deal with depends() returning a value rather than a pointer. Also adjust dumpPackageDepends() appropriately Also remove useless debug showing the dependency list before we build it.