# ex:ts=8 sw=4:
-# $OpenBSD: Add.pm,v 1.134 2013/12/30 09:02:37 espie Exp $
+# $OpenBSD: Add.pm,v 1.135 2014/01/05 10:24:30 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
my ($plist, $state) = @_;
my $pkgname = $plist->pkgname;
+ if ($state->defines('FW_UPDATE')) {
+ $plist->has('firmware') or
+ OpenBSD::PackingElement::Firmware->add($plist);
+ }
return 0 unless $user_tagged->{$pkgname};
if (!$plist->has('manual-installation') && !$state->{automatic}) {
OpenBSD::PackingElement::ManualInstallation->add($plist);
# ex:ts=8 sw=4:
-# $OpenBSD: Delete.pm,v 1.123 2014/01/02 16:05:42 espie Exp $
+# $OpenBSD: Delete.pm,v 1.124 2014/01/05 10:24:30 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
}
}
}
+ if ($plist->has('firmware')) {
+ if ($state->{interactive}) {
+ if (!$state->confirm("\nDelete firmware $pkgname", 0)) {
+ $state->errsay("NOT deleting #1", $pkgname);
+ return;
+ }
+ }
+ }
$state->{problems} = 0;
validate_plist($plist, $state);
# ex:ts=8 sw=4:
-# $OpenBSD: Update.pm,v 1.155 2013/12/25 15:59:51 espie Exp $
+# $OpenBSD: Update.pm,v 1.156 2014/01/05 10:24:30 espie Exp $
#
# Copyright (c) 2004-2010 Marc Espie <espie@openbsd.org>
#
$state->fatal("can't locate #1", $pkgname);
}
- if ($plist->has('explicit-update') && $state->{allupdates}) {
+ if ($plist->has('explicit-update') && $state->{allupdates} ||
+ $plist->has('firmware') && !$state->defines('FW_UPDATE')) {
$h->{update_found} = $h;
$set->move_kept($h);
return 0;