delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2024/07/21/12:26:45

DKIM-Filter: OpenDKIM Filter v2.11.0 delorie.com 46LGQjKr2098292
Authentication-Results: delorie.com;
dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=ZOLjjoeS
X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 86CBD385DDCB
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1721579204;
bh=PJGYiz/Tk8KdHW26Fl3+lxixGBc53+iLxkQaXFWH82A=;
h=Date:Subject:To:References:Cc:In-Reply-To:List-Id:
List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe:
From:Reply-To:From;
b=ZOLjjoeSSPYAK4twycLZvfGwDzwlMc4d8L4ljfT9jYz0ubiIO0aCDjcaUHoVuurRv
6jI8E6DZLnY8ANDq2s6zlVJqQl9QHQsPU1kKNufeSBsiJbbGWIEYxphCDxB2BayK6k
GuML3Qsv0amYFT1klNwVTjR8hgMI90V52VkyeME4=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 38D83385840C
ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 38D83385840C
ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1721579080; cv=none;
b=aYp1nmjkt/xj56lARF/+4eJ7KudfM5f2kb7ltqAxyaEVDHTJ118gRtALNcv6do8ot831Mt2EkLNbqaR8UsfdxtSbUNXKbiVCXiMCqvGNNr/uqePX5AugYmJ6r0z09gQfrLHpsMd0wGq1JudulJvlkJLXpO5nfqImUl53uIBr5dU=
ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key;
t=1721579080; c=relaxed/simple;
bh=mhVx0DapjtZAYmAfQWRVfVngkhVAMFkcZYnL6pB/Ep0=;
h=Message-ID:Date:MIME-Version:Subject:To:From;
b=FjMGnGY4aJ0TQo+ncUka3TQyi7aUb0Np1Q/pk6hO4g7zYHkZJz6GTyqS70XMcbyieOgWKCYtigeHH+DGwL0M6iUDRhsFC2J7RkjZor8dZBtMLdBD7tTdWmfGgdStPzETWtyjCShwF5eGutVznhTh2poJbGDKrxrauI5KRZFJa7I=
ARC-Authentication-Results: i=1; server2.sourceware.org
X-SNCR-Rigid: 669441F000D06E41
X-Originating-IP: [86.143.43.103]
X-OWM-Source-IP: 86.143.43.103
X-OWM-Env-Sender: jon DOT turney AT dronecode DOT org DOT uk
X-RazorGate-Vade: gggruggvucftvghtrhhoucdtuddrgeeftddrheehgddutdduucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuueftkffvkffujffvgffngfevqffopdfqfgfvnecuuegrihhlohhuthemuceftddunecunecujfgurhepkfffgggfuffvfhfhvegjtgfgsehtjeertddtvdejnecuhfhrohhmpeflohhnucfvuhhrnhgvhicuoehjohhnrdhtuhhrnhgvhiesughrohhnvggtohguvgdrohhrghdruhhkqeenucggtffrrghtthgvrhhnpeevvdekgfffteetueehgfdugefgkeevleejudduheevuedtveejfeevvdevvdfgvdenucfkphepkeeirddugeefrdegfedruddtfeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhephhgvlhhopegludelvddrudeikedruddruddtlegnpdhinhgvthepkeeirddugeefrdegfedruddtfedpmhgrihhlfhhrohhmpehjohhnrdhtuhhrnhgvhiesughrohhnvggtohguvgdrohhrghdruhhkpdhnsggprhgtphhtthhopedvpdhrtghpthhtoheptghorhhnghhoohgusehgmhgrihhlrdgtohhmpdhrtghpthhtoheptgihghifihhnsegthihgfihinhdrtghomhdprhgvvhfkrfephhhoshhtkeeiqddugeefqdegfedquddtfedrrhgrnhhgvgekiedqudegfedrsghttggvnhhtrhgrlhhplhhushdrtghomhdprghuthhhpghushgvrhepjhhonhhtuhhrnhgvhiessghtihhnthgvrhhnvghtrdgtohhmpdhgvghokffrpefiuedpoffvtefjohhsthepsghtphhrughr
ghhotdduvd
X-RazorGate-Vade-Verdict: clean 0
X-RazorGate-Vade-Classification: clean
X-VadeSecure-score: verdict=clean score=0/300, class=clean
Message-ID: <f80cd242-d2ca-49a9-9cfe-4c425a25494c@dronecode.org.uk>
Date: Sun, 21 Jul 2024 17:24:36 +0100
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
Subject: Re: setup: --prune-install appears to be broken
To: David McFarland <corngood AT gmail DOT com>
References: <87bk3v91n6 DOT fsf AT gmail DOT com>
Cc: cygwin AT cygwin DOT com
In-Reply-To: <87bk3v91n6.fsf@gmail.com>
X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00, GIT_PATCH_0,
JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, RCVD_IN_BARRACUDACENTRAL,
RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_PASS,
TXREP autolearn=ham autolearn_force=no version=3.4.6
X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.30
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <https://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Jon Turney via Cygwin <cygwin AT cygwin DOT com>
Reply-To: Jon Turney <jon DOT turney AT dronecode DOT org DOT uk>
Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com>

On 20/06/2024 14:36, David McFarland via Cygwin wrote:

Sorry for the delay in replying to this.

> 
> If I do a base install to a new root:
> 
>      setup-x86_64.exe --root "$(cygpath -wa .cygtest)" --no-admin \
>          --no-shortcuts --no-replaceonreboot --no-version-check \
>          --prune-install --verbose
> 
> And then run the same install again, I get:
> 
[...]

>      Can't happen.  No packagemeta for base
> 
> The "Can't happen" error results in all following transactions being skipped:
> 
>          // Can't happen - throw an exception?
>          {
>            Log (LOG_PLAIN) << "Can't happen.  No packagemeta for "
>                            << pv.Name() << endLog;
>            return;
>          }

Yeah, that's clearly a bug of some sort.

At the very least, if we're not going to terminate there, it probably 
should be a 'continue' rather than a 'return', so we actually process 
the rest of the transactions.

> This results in setup always showing no pending changes, even if you
> have installed additional packages that should be pruned by
> --prune-install, or if setup.ini has different contents.
> 
> The problem seems to be that we use SOLVER_ERASE jobs to remove all
> non-base installed packages, and they take precedence over keeping the
> pseudo-package 'base' installed.

There's something else going on here I don't understand as there are 
other base or basedep packages in that list of things it wants to erase.

> Making the erase jobs weak seems to solve the problem:
> 
> diff --git a/libsolv.cc b/libsolv.cc
> index 3f083a4..95f21a2 100644
> --- a/libsolv.cc
> +++ b/libsolv.cc
> @@ -850,7 +850,7 @@ SolverSolution::tasksToJobs(SolverTasks &tasks, updateMode update, Queue &job)
>             queue_push2(&job, SOLVER_INSTALL | SOLVER_SOLVABLE_PROVIDES, sv.name_id());
>             break;
>           case SolverTasks::taskUninstall:
> -          queue_push2(&job, SOLVER_ERASE | SOLVER_SOLVABLE, sv.id);
> +          queue_push2(&job, SOLVER_ERASE | SOLVER_WEAK | SOLVER_SOLVABLE, sv.id);
>             break;
>           case SolverTasks::taskReinstall:
>             // we don't know how to ask solver for this, so we just add the erase
> 
> However, I'm not sure if this is a good idea. Perhaps it should only be

Thanks very much for attempting to fix this and providing a patch.

But, yeah, that seems like probably the wrong approach.

(for e.g. seems like that's going make us silently ignore removing X at 
the same time as installing something else which depends on X, when we 
really should to indicate a conflict..)


-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019