This is the mail archive of the cygwin-apps mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: setup: problems with local install


On 05/03/2018 18:34, Ken Brown wrote:
This is a followup to the thread started here:

   https://cygwin.com/ml/cygwin/2018-03/msg00027.html

There are two problems with installing from a local directory.

Thanks very much for looking into these.

2. In several of the views, all packages from setup.ini are listed, even if there is no corresponding archive in the local directory.  What happens is that packagemeta::scan() calls pkg.source()->sites.clear() for such packages, but this information is never used to prevent the package from appearing in the list.

It used to be that such packages would be declared inaccessible, but SolvableVersion::accessible() no longer does this.

Jon, you wrote the following comment in the definition of SolvableVersion::accessible():

"The 'accessible' check used to test if an archive was available locally or from a mirror.  This seems utterly pointless as binary packages which aren't 'accessible' never get to appear in the package list."

Do we need to reinstate the old function of the accessibility check?

I guess I looked at packagemeta::ScanDownloadedFiles() and saw that it was removing versions, and thought everything was good.

I didn't notice accessible() was indirectly how the result of scan() was returned :S

So yeah, I guess putting some complexity back in accessible() would work, or perhaps the attached? (This doesn't do the right thing for a few packages, for reasons I'm still looking into...)

(I also note we have also have another 'erase an element from a vector while we are iterating over it' here, so that needs fixing, as well)

I'm kind of uncertain what the side-effects of this code are when source != IDC_SOURCE_LOCALDIR, or if they are desired? Perhaps it's removing packages which have corrupt local copies or something? It would be clearer to omit the whole thing in that case.

Attachment: 0001-Fix-packagemeta-ScanDownloadedFiles.patch
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]