2 * dpkg - main program for package management
3 * packages.c - common to actions that process packages
5 * Copyright © 1994,1995 Ian Jackson <ijackson@chiark.greenend.org.uk>
6 * Copyright © 2006-2014 Guillem Jover <guillem@debian.org>
7 * Copyright © 2011 Linaro Limited
8 * Copyright © 2011 Raphaël Hertzog <hertzog@debian.org>
10 * This is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
15 * This is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with this program. If not, see <https://www.gnu.org/licenses/>.
27 #include <sys/types.h>
37 #include <dpkg/i18n.h>
38 #include <dpkg/dpkg.h>
39 #include <dpkg/dpkg-db.h>
40 #include <dpkg/pkg-list.h>
41 #include <dpkg/pkg-queue.h>
42 #include <dpkg/string.h>
43 #include <dpkg/options.h>
44 #include <dpkg/db-ctrl.h>
45 #include <dpkg/db-fsys.h>
49 static struct pkginfo
*progress_bytrigproc
;
50 static struct pkg_queue queue
= PKG_QUEUE_INIT
;
52 enum dependtry dependtry
= DEPEND_TRY_NORMAL
;
56 enqueue_package(struct pkginfo
*pkg
)
58 ensure_package_clientdata(pkg
);
59 if (pkg
->clientdata
->enqueued
)
61 pkg
->clientdata
->enqueued
= true;
62 pkg_queue_push(&queue
, pkg
);
66 enqueue_package_mark_seen(struct pkginfo
*pkg
)
69 pkg
->clientdata
->cmdline_seen
++;
75 struct pkg_hash_iter
*iter
;
78 iter
= pkg_hash_iter_new();
79 while ((pkg
= pkg_hash_iter_next_pkg(iter
)) != NULL
) {
80 switch (cipaction
->arg_int
) {
82 if (!(pkg
->status
== PKG_STAT_UNPACKED
||
83 pkg
->status
== PKG_STAT_HALFCONFIGURED
||
86 if (pkg
->want
!= PKG_WANT_INSTALL
&&
87 pkg
->want
!= PKG_WANT_HOLD
)
91 if (!pkg
->trigpend_head
)
93 if (pkg
->want
!= PKG_WANT_INSTALL
&&
94 pkg
->want
!= PKG_WANT_HOLD
)
99 if (pkg
->want
!= PKG_WANT_PURGE
) {
100 if (pkg
->want
!= PKG_WANT_DEINSTALL
)
102 if (pkg
->status
== PKG_STAT_CONFIGFILES
)
105 if (pkg
->status
== PKG_STAT_NOTINSTALLED
)
109 internerr("unknown action '%d'", cipaction
->arg_int
);
111 enqueue_package(pkg
);
113 pkg_hash_iter_free(iter
);
117 enqueue_specified(const char *const *argv
)
121 while ((thisarg
= *argv
++) != NULL
) {
124 pkg
= dpkg_options_parse_pkgname(cipaction
, thisarg
);
125 if (pkg
->status
== PKG_STAT_NOTINSTALLED
&&
126 str_match_end(pkg
->set
->name
, DEBEXT
)) {
127 badusage(_("you must specify packages by their own names, "
128 "not by quoting the names of the files they come in"));
130 enqueue_package_mark_seen(pkg
);
133 if (cipaction
->arg_int
== act_configure
)
134 trigproc_populate_deferred();
138 packages(const char *const *argv
)
140 trigproc_install_hooks();
142 modstatdb_open(f_noact
? msdbrw_readonly
:
143 in_force(FORCE_NON_ROOT
) ? msdbrw_write
:
144 msdbrw_needsuperuser
);
146 pkg_infodb_upgrade();
148 log_message("startup packages %s", cipaction
->olong
);
152 badusage(_("--%s --pending does not take any non-option arguments"),cipaction
->olong
);
157 badusage(_("--%s (without --pending) needs at least one package name argument"),
160 enqueue_specified(argv
);
166 trigproc_run_deferred();
168 modstatdb_shutdown();
173 void process_queue(void) {
174 struct pkg_list
*rundown
;
175 volatile enum action action_todo
;
177 enum pkg_istobe istobe
= PKG_ISTOBE_NORMAL
;
179 if (abort_processing
)
184 switch (cipaction
->arg_int
) {
188 istobe
= PKG_ISTOBE_INSTALLNEW
;
192 istobe
= PKG_ISTOBE_REMOVE
;
195 internerr("unknown action '%d'", cipaction
->arg_int
);
197 for (rundown
= queue
.head
; rundown
; rundown
= rundown
->next
) {
198 ensure_package_clientdata(rundown
->pkg
);
200 /* We have processed this package more than once. There are no duplicates
201 * as we make sure of that when enqueuing them. */
202 if (rundown
->pkg
->clientdata
->cmdline_seen
> 1) {
203 switch (cipaction
->arg_int
) {
205 case act_configure
: case act_remove
: case act_purge
:
206 printf(_("Package %s listed more than once, only processing once.\n"),
207 pkg_name(rundown
->pkg
, pnaw_nonambig
));
210 printf(_("More than one copy of package %s has been unpacked\n"
211 " in this run ! Only configuring it once.\n"),
212 pkg_name(rundown
->pkg
, pnaw_nonambig
));
215 internerr("unknown action '%d'", cipaction
->arg_int
);
218 rundown
->pkg
->clientdata
->istobe
= istobe
;
221 while (!pkg_queue_is_empty(&queue
)) {
222 struct pkginfo
*volatile pkg
;
224 pkg
= pkg_queue_pop(&queue
);
226 continue; /* Duplicate, which we removed earlier. */
228 ensure_package_clientdata(pkg
);
229 pkg
->clientdata
->enqueued
= false;
231 action_todo
= cipaction
->arg_int
;
233 if (sincenothing
++ > queue
.length
* 3 + 2) {
234 /* Make sure that even if we have exceeded the queue since not having
235 * made any progress, we are not getting stuck trying to progress by
236 * trigger processing, w/o jumping into the next dependtry. */
239 if (dependtry
>= DEPEND_TRY_LAST
)
240 internerr("exceeded dependtry %d (sincenothing=%d; queue.length=%d)",
241 dependtry
, sincenothing
, queue
.length
);
242 } else if (sincenothing
> queue
.length
* 2 + 2) {
243 if (dependtry
>= DEPEND_TRY_TRIGGERS
&&
244 progress_bytrigproc
&& progress_bytrigproc
->trigpend_head
) {
245 enqueue_package(pkg
);
246 pkg
= progress_bytrigproc
;
247 progress_bytrigproc
= NULL
;
248 action_todo
= act_configure
;
252 if (dependtry
>= DEPEND_TRY_LAST
)
253 internerr("exceeded dependtry %d (sincenothing=%d, queue.length=%d)",
254 dependtry
, sincenothing
, queue
.length
);
258 debug(dbg_general
, "process queue pkg %s queue.len %d progress %d, try %d",
259 pkg_name(pkg
, pnaw_always
), queue
.length
, sincenothing
, dependtry
);
261 if (pkg
->status
> PKG_STAT_INSTALLED
)
262 internerr("package %s status %d is out-of-bounds",
263 pkg_name(pkg
, pnaw_always
), pkg
->status
);
266 /* Give up on it from the point of view of other packages, i.e. reset
268 pkg
->clientdata
->istobe
= PKG_ISTOBE_NORMAL
;
270 pop_error_context(ehflag_bombout
);
271 if (abort_processing
)
275 push_error_context_jump(&ejbuf
, print_error_perpackage
,
276 pkg_name(pkg
, pnaw_nonambig
));
278 switch (action_todo
) {
280 if (!pkg
->trigpend_head
)
281 ohshit(_("package %.250s is not ready for trigger processing\n"
282 " (current status '%.250s' with no pending triggers)"),
283 pkg_name(pkg
, pnaw_nonambig
), pkg_status_name(pkg
));
286 /* Don't try to configure pkgs that we've just disappeared. */
287 if (pkg
->status
== PKG_STAT_NOTINSTALLED
)
291 /* Do whatever is most needed. */
292 if (pkg
->trigpend_head
)
293 trigproc(pkg
, TRIGPROC_TRY_QUEUED
);
295 deferred_configure(pkg
);
297 case act_remove
: case act_purge
:
298 deferred_remove(pkg
);
301 internerr("unknown action '%d'", cipaction
->arg_int
);
303 m_output(stdout
, _("<standard output>"));
304 m_output(stderr
, _("<standard error>"));
306 pop_error_context(ehflag_normaltidy
);
310 internerr("finished package processing with non-empty queue length %d",
314 /*** Dependency processing - common to --configure and --remove. ***/
317 * The algorithm for deciding what to configure or remove first is as
320 * Loop through all packages doing a ‘try 1’ until we've been round and
321 * nothing has been done, then do ‘try 2’ and ‘try 3’ likewise.
323 * When configuring, in each try we check to see whether all
324 * dependencies of this package are done. If so we do it. If some of
325 * the dependencies aren't done yet but will be later we defer the
326 * package, otherwise it is an error.
328 * When removing, in each try we check to see whether there are any
329 * packages that would have dependencies missing if we removed this
330 * one. If not we remove it now. If some of these packages are
331 * themselves scheduled for removal we defer the package until they
334 * The criteria for satisfying a dependency vary with the various
335 * tries. In try 1 we treat the dependencies as absolute. In try 2 we
336 * check break any cycles in the dependency graph involving the package
337 * we are trying to process before trying to process the package
338 * normally. In try 3 (which should only be reached if
339 * --force-depends-version is set) we ignore version number clauses in
340 * Depends lines. In try 4 (only reached if --force-depends is set) we
341 * say "ok" regardless.
343 * If we are configuring and one of the packages we depend on is
344 * awaiting configuration but wasn't specified in the argument list we
345 * will add it to the argument list if --configure-any is specified.
346 * In this case we note this as having "done something" so that we
347 * don't needlessly escalate to higher levels of dependency checking
358 static enum found_status
359 found_forced_on(enum dependtry dependtry_forced
)
361 if (dependtry
>= dependtry_forced
)
369 * 0: cannot be satisfied.
370 * 1: defer: may be satisfied later, when other packages are better or
371 * at higher dependtry due to --force
372 * will set *fixbytrig to package whose trigger processing would help
373 * if applicable (and leave it alone otherwise).
374 * 2: not satisfied but forcing
375 * (*interestingwarnings >= 0 on exit? caller is to print oemsgs).
378 static enum found_status
379 deppossi_ok_found(struct pkginfo
*possdependee
, struct pkginfo
*requiredby
,
380 struct pkginfo
*removing
, struct deppossi
*provider
,
381 struct pkginfo
**fixbytrig
,
382 bool *matched
, struct deppossi
*checkversion
,
383 int *interestingwarnings
, struct varbuf
*oemsgs
)
385 enum found_status thisf
;
387 if (ignore_depends(possdependee
)) {
388 debug(dbg_depcondetail
," ignoring depended package so ok and found");
392 if (possdependee
== removing
) {
394 varbuf_printf(oemsgs
,
395 _(" Package %s which provides %s is to be removed.\n"),
396 pkg_name(possdependee
, pnaw_nonambig
),
399 varbuf_printf(oemsgs
, _(" Package %s is to be removed.\n"),
400 pkg_name(possdependee
, pnaw_nonambig
));
404 debug(dbg_depcondetail
," removing possdependee, returning %d",thisf
);
407 switch (possdependee
->status
) {
408 case PKG_STAT_UNPACKED
:
409 case PKG_STAT_HALFCONFIGURED
:
410 case PKG_STAT_TRIGGERSAWAITED
:
411 case PKG_STAT_TRIGGERSPENDING
:
412 case PKG_STAT_INSTALLED
:
415 debug(dbg_depcondetail
, " checking package %s provided by pkg %s",
416 checkversion
->ed
->name
, pkg_name(possdependee
, pnaw_always
));
417 if (!pkg_virtual_deppossi_satisfied(checkversion
, provider
)) {
418 varbuf_printf(oemsgs
,
419 _(" Version of %s on system, provided by %s, is %s.\n"),
420 checkversion
->ed
->name
,
421 pkg_name(possdependee
, pnaw_always
),
422 versiondescribe(&provider
->version
, vdew_nonambig
));
423 if (in_force(FORCE_DEPENDS_VERSION
))
424 thisf
= found_forced_on(DEPEND_TRY_FORCE_DEPENDS_VERSION
);
425 debug(dbg_depcondetail
, " bad version");
429 debug(dbg_depcondetail
, " checking non-provided pkg %s",
430 pkg_name(possdependee
, pnaw_always
));
431 if (!versionsatisfied(&possdependee
->installed
, checkversion
)) {
432 varbuf_printf(oemsgs
, _(" Version of %s on system is %s.\n"),
433 pkg_name(possdependee
, pnaw_nonambig
),
434 versiondescribe(&possdependee
->installed
.version
,
436 if (in_force(FORCE_DEPENDS_VERSION
))
437 thisf
= found_forced_on(DEPEND_TRY_FORCE_DEPENDS_VERSION
);
438 debug(dbg_depcondetail
, " bad version");
443 if (possdependee
->status
== PKG_STAT_INSTALLED
||
444 possdependee
->status
== PKG_STAT_TRIGGERSPENDING
) {
445 debug(dbg_depcondetail
," is installed, ok and found");
448 if (possdependee
->status
== PKG_STAT_TRIGGERSAWAITED
) {
449 if (possdependee
->trigaw
.head
== NULL
)
450 internerr("package %s in state %s, has no awaited triggers",
451 pkg_name(possdependee
, pnaw_always
),
452 pkg_status_name(possdependee
));
456 (possdependee
->clientdata
&&
457 possdependee
->clientdata
->istobe
== PKG_ISTOBE_INSTALLNEW
))) {
459 varbuf_printf(oemsgs
,
460 _(" Package %s which provides %s awaits trigger processing.\n"),
461 pkg_name(possdependee
, pnaw_nonambig
),
464 varbuf_printf(oemsgs
,
465 _(" Package %s awaits trigger processing.\n"),
466 pkg_name(possdependee
, pnaw_nonambig
));
468 debug(dbg_depcondetail
, " triggers-awaited, no fixbytrig");
471 /* We don't check the status of trigaw.head->pend here, just in case
472 * we get into the pathological situation where Triggers-Awaited but
473 * the named package doesn't actually have any pending triggers. In
474 * that case we queue the non-pending package for trigger processing
475 * anyway, and that trigger processing will be a noop except for
476 * sorting out all of the packages which name it in Triggers-Awaited.
478 * (This situation can only arise if modstatdb_note success in
479 * clearing the triggers-pending status of the pending package
480 * but then fails to go on to update the awaiters.) */
481 *fixbytrig
= possdependee
->trigaw
.head
->pend
;
482 debug(dbg_depcondetail
,
483 " triggers-awaited, fixbytrig '%s', defer",
484 pkg_name(*fixbytrig
, pnaw_always
));
487 if (possdependee
->clientdata
&&
488 possdependee
->clientdata
->istobe
== PKG_ISTOBE_INSTALLNEW
) {
489 debug(dbg_depcondetail
," unpacked/halfconfigured, defer");
491 } else if (!removing
&& in_force(FORCE_CONFIGURE_ANY
) &&
492 !skip_due_to_hold(possdependee
) &&
493 !(possdependee
->status
== PKG_STAT_HALFCONFIGURED
)) {
494 notice(_("also configuring '%s' (required by '%s')"),
495 pkg_name(possdependee
, pnaw_nonambig
),
496 pkg_name(requiredby
, pnaw_nonambig
));
497 enqueue_package(possdependee
);
502 varbuf_printf(oemsgs
,
503 _(" Package %s which provides %s is not configured yet.\n"),
504 pkg_name(possdependee
, pnaw_nonambig
),
507 varbuf_printf(oemsgs
, _(" Package %s is not configured yet.\n"),
508 pkg_name(possdependee
, pnaw_nonambig
));
511 debug(dbg_depcondetail
, " not configured/able");
517 varbuf_printf(oemsgs
,
518 _(" Package %s which provides %s is not installed.\n"),
519 pkg_name(possdependee
, pnaw_nonambig
),
522 varbuf_printf(oemsgs
, _(" Package %s is not installed.\n"),
523 pkg_name(possdependee
, pnaw_nonambig
));
526 debug(dbg_depcondetail
, " not installed");
531 debug(dbg_depcondetail
, " returning %d", thisf
);
532 (*interestingwarnings
)++;
538 breaks_check_one(struct varbuf
*aemsgs
, enum dep_check
*ok
,
539 struct deppossi
*breaks
, struct pkginfo
*broken
,
540 struct pkginfo
*breaker
, struct deppossi
*virtbroken
)
542 struct varbuf depmsg
= VARBUF_INIT
;
544 debug(dbg_depcondetail
, " checking breaker %s virtbroken %s",
545 pkg_name(breaker
, pnaw_always
),
546 virtbroken
? virtbroken
->ed
->name
: "<none>");
548 if (breaker
->status
== PKG_STAT_NOTINSTALLED
||
549 breaker
->status
== PKG_STAT_CONFIGFILES
)
551 if (broken
== breaker
) return;
552 if (!versionsatisfied(&broken
->installed
, breaks
)) return;
553 /* The test below can only trigger if dep_breaks start having
554 * arch qualifiers different from “any”. */
555 if (!archsatisfied(&broken
->installed
, breaks
))
557 if (ignore_depends(breaker
)) return;
558 if (virtbroken
&& ignore_depends(&virtbroken
->ed
->pkg
))
560 if (virtbroken
&& !pkg_virtual_deppossi_satisfied(breaks
, virtbroken
))
563 varbufdependency(&depmsg
, breaks
->up
);
564 varbuf_end_str(&depmsg
);
565 varbuf_printf(aemsgs
, _(" %s (%s) breaks %s and is %s.\n"),
566 pkg_name(breaker
, pnaw_nonambig
),
567 versiondescribe(&breaker
->installed
.version
, vdew_nonambig
),
568 depmsg
.buf
, gettext(statusstrings
[breaker
->status
]));
569 varbuf_destroy(&depmsg
);
572 varbuf_printf(aemsgs
, _(" %s (%s) provides %s.\n"),
573 pkg_name(broken
, pnaw_nonambig
),
574 versiondescribe(&broken
->installed
.version
, vdew_nonambig
),
575 virtbroken
->ed
->name
);
576 } else if (breaks
->verrel
!= DPKG_RELATION_NONE
) {
577 varbuf_printf(aemsgs
, _(" Version of %s to be configured is %s.\n"),
578 pkg_name(broken
, pnaw_nonambig
),
579 versiondescribe(&broken
->installed
.version
, vdew_nonambig
));
580 if (in_force(FORCE_DEPENDS_VERSION
))
583 if (force_breaks(breaks
)) return;
584 *ok
= DEP_CHECK_HALT
;
588 breaks_check_target(struct varbuf
*aemsgs
, enum dep_check
*ok
,
589 struct pkginfo
*broken
, struct pkgset
*target
,
590 struct deppossi
*virtbroken
)
592 struct deppossi
*possi
;
594 for (possi
= target
->depended
.installed
; possi
; possi
= possi
->rev_next
) {
595 if (possi
->up
->type
!= dep_breaks
) continue;
596 breaks_check_one(aemsgs
, ok
, possi
, broken
, possi
->up
->up
, virtbroken
);
601 breakses_ok(struct pkginfo
*pkg
, struct varbuf
*aemsgs
)
603 struct dependency
*dep
;
604 struct deppossi
*virtbroken
;
605 enum dep_check ok
= DEP_CHECK_OK
;
607 debug(dbg_depcon
, " checking Breaks");
609 breaks_check_target(aemsgs
, &ok
, pkg
, pkg
->set
, NULL
);
611 for (dep
= pkg
->installed
.depends
; dep
; dep
= dep
->next
) {
612 if (dep
->type
!= dep_provides
) continue;
613 virtbroken
= dep
->list
;
614 debug(dbg_depcondetail
, " checking virtbroken %s", virtbroken
->ed
->name
);
615 breaks_check_target(aemsgs
, &ok
, pkg
, virtbroken
->ed
, virtbroken
);
621 * Checks [Pre]-Depends only.
624 dependencies_ok(struct pkginfo
*pkg
, struct pkginfo
*removing
,
625 struct varbuf
*aemsgs
)
627 /* Valid values: 2 = ok, 1 = defer, 0 = halt. */
629 /* Valid values: 0 = none, 1 = defer, 2 = withwarning, 3 = ok. */
630 enum found_status found
, thisf
;
631 int interestingwarnings
;
632 bool matched
, anycannotfixbytrig
;
633 struct varbuf oemsgs
= VARBUF_INIT
;
634 struct dependency
*dep
;
635 struct deppossi
*possi
, *provider
;
636 struct pkginfo
*possfixbytrig
, *canfixbytrig
;
639 debug(dbg_depcon
,"checking dependencies of %s (- %s)",
640 pkg_name(pkg
, pnaw_always
),
641 removing
? pkg_name(removing
, pnaw_always
) : "<none>");
643 anycannotfixbytrig
= false;
645 for (dep
= pkg
->installed
.depends
; dep
; dep
= dep
->next
) {
646 if (dep
->type
!= dep_depends
&& dep
->type
!= dep_predepends
) continue;
647 debug(dbg_depcondetail
," checking group ...");
649 interestingwarnings
= 0;
650 varbuf_reset(&oemsgs
);
652 possfixbytrig
= NULL
;
653 for (possi
= dep
->list
; found
!= FOUND_OK
&& possi
; possi
= possi
->next
) {
654 struct deppossi_pkg_iterator
*possi_iter
;
655 struct pkginfo
*pkg_pos
;
657 debug(dbg_depcondetail
," checking possibility -> %s",possi
->ed
->name
);
658 if (possi
->cyclebreak
) {
659 debug(dbg_depcondetail
," break cycle so ok and found");
665 possi_iter
= deppossi_pkg_iter_new(possi
, wpb_installed
);
666 while ((pkg_pos
= deppossi_pkg_iter_next(possi_iter
))) {
667 thisf
= deppossi_ok_found(pkg_pos
, pkg
, removing
, NULL
,
668 &possfixbytrig
, &matched
, possi
,
669 &interestingwarnings
, &oemsgs
);
672 if (found
== FOUND_OK
)
675 deppossi_pkg_iter_free(possi_iter
);
677 if (found
!= FOUND_OK
) {
678 for (provider
= possi
->ed
->depended
.installed
;
679 found
!= FOUND_OK
&& provider
;
680 provider
= provider
->rev_next
) {
681 if (provider
->up
->type
!= dep_provides
)
683 debug(dbg_depcondetail
, " checking provider %s",
684 pkg_name(provider
->up
->up
, pnaw_always
));
685 if (!deparchsatisfied(&provider
->up
->up
->installed
, provider
->arch
,
687 debug(dbg_depcondetail
, " provider does not satisfy arch");
690 thisf
= deppossi_ok_found(provider
->up
->up
, pkg
, removing
, provider
,
691 &possfixbytrig
, &matched
, possi
,
692 &interestingwarnings
, &oemsgs
);
693 if (thisf
== FOUND_DEFER
&& provider
->up
->up
== pkg
&& !removing
) {
694 /* IOW, if the pkg satisfies its own dep (via a provide), then
695 * we let it pass, even if it isn't configured yet (as we're
703 debug(dbg_depcondetail
," found %d",found
);
704 if (thisf
> found
) found
= thisf
;
706 if (in_force(FORCE_DEPENDS
)) {
707 thisf
= found_forced_on(DEPEND_TRY_FORCE_DEPENDS
);
710 debug(dbg_depcondetail
, " rescued by force-depends, found %d", found
);
713 debug(dbg_depcondetail
, " found %d matched %d possfixbytrig %s",
715 possfixbytrig
? pkg_name(possfixbytrig
, pnaw_always
) : "-");
716 if (removing
&& !matched
) continue;
719 anycannotfixbytrig
= true;
723 varbuf_add_str(aemsgs
, " ");
724 varbuf_add_pkgbin_name(aemsgs
, pkg
, &pkg
->installed
, pnaw_nonambig
);
725 varbuf_add_str(aemsgs
, _(" depends on "));
726 varbufdependency(aemsgs
, dep
);
727 if (interestingwarnings
) {
728 /* Don't print the line about the package to be removed if
729 * that's the only line. */
730 varbuf_end_str(&oemsgs
);
731 varbuf_add_str(aemsgs
, _("; however:\n"));
732 varbuf_add_varbuf(aemsgs
, &oemsgs
);
734 varbuf_add_str(aemsgs
, ".\n");
739 canfixbytrig
= possfixbytrig
;
741 anycannotfixbytrig
= true;
742 if (ok
> DEP_CHECK_DEFER
)
743 ok
= DEP_CHECK_DEFER
;
748 internerr("unknown value for found '%d'", found
);
751 if (ok
== DEP_CHECK_HALT
&&
752 (pkg
->clientdata
&& pkg
->clientdata
->istobe
== PKG_ISTOBE_REMOVE
))
753 ok
= DEP_CHECK_DEFER
;
754 if (!anycannotfixbytrig
&& canfixbytrig
)
755 progress_bytrigproc
= canfixbytrig
;
757 varbuf_destroy(&oemsgs
);
758 debug(dbg_depcon
,"ok %d msgs >>%.*s<<", ok
, (int)aemsgs
->used
, aemsgs
->buf
);