-Sun Dec 24 01:00:59 CST 2000 2000 Adam Heath <doogie@debian.org>
+Sun Dec 24 02:38:38 CST 2000 Adam Heath <doogie@debian.org>
+
+ * methods/disk.install, methods/disk.setup, methods/disk.update,
+ methods/floppy.install, methods/floppy.update, methods/hd.setup,
+ methods/hd.unpack, methods/hd.update: Fix to pass on admindir
+ from dselect to dpkg.
+
+Sun Dec 24 01:00:59 CST 2000 Adam Heath <doogie@debian.org>
* scripts/dpkg-source.pl: Minor tweak so that when patch 2.5.4 is
manually used to apply a diff, it doesn't get applied multiple
dpkg (1.8.0) unstable; urgency=low
+ * Fix dselect methods to pass admindir to dpkg from dselect.
* Minor tweak so that when patch 2.5.4 is manually used to apply a diff,
it doesn't get applied multiple times. Closes: #65021
* Add --nicelevel to start-stop-daemon, to alter a programs priority
while true
do
set +e
- dpkg --predep-package >"$predep"
+ dpkg --admindir "$vardir" --predep-package >"$predep"
rc=$?
set -e
if test $rc = 1; then break; fi
Perhaps you downloaded it with an unexpected name, or something.
In any case, you must find the file(s) and then either place it with
the correct filename(s) (as listed in the Packages file or in
-/var/lib/dpkg/available) and rerun the installation, or upgrade the
+$vardir/available) and rerun the installation, or upgrade the
package by using `dpkg --install --auto-deconfigure'\'' by hand.
";
push(@invoke,$invoke);
}
print "Running dpkg -iB for $package ...\n";
- exec("dpkg","-iB","--",@invoke);
+ exec("dpkg","--admindir",$vardir,"-iB","--",@invoke);
die "failed to exec dpkg: $!\n";
' -- "$p_mountpoint$p_main_binary" "$predep"
done
do
eval 'this_binary=$p_'$f'_binary'
if [ -z "$this_binary" ]; then continue; fi
- echo Running dpkg -iGROEB "$p_mountpoint$this_binary"
- dpkg -iGROEB "$p_mountpoint$this_binary"
+ echo Running dpkg --admindir $vardir -iGROEB "$p_mountpoint$this_binary"
+ dpkg --admindir $vardir -iGROEB "$p_mountpoint$this_binary"
done
echo -n 'Installation OK. Hit RETURN. '
cd "$vardir/methods/disk"
tp=/var/run/ddm$$
-iarch=`dpkg --print-installation-architecture`
+iarch=`dpkg --admindir $vardir --print-installation-architecture`
xit=1
trap '
if [ -z "$this_binary" ]; then continue; fi
if [ "$updatetype" = update ]
then
- dpkg --clear-avail
+ dpkg --admindir $vardir --clear-avail
updatetype=merge
fi
echo Running dpkg --record-avail -R "$p_mountpoint$this_binary"
- dpkg --record-avail -R "$p_mountpoint$this_binary"
+ dpkg --admindir $vardir --record-avail -R "$p_mountpoint$this_binary"
;;
*)
packagesfile="$p_mountpoint$this_packages"
echo -n "Uncompressing $packagesfile ... "
zcat <"$packagesfile" >packages-$f
echo done.
- dpkg --$updatetype-avail packages-$f
+ dpkg --admindir $vardir --$updatetype-avail packages-$f
updatetype=merge
;;
'')
;;
*)
- dpkg --$updatetype-avail "$packagesfile"
+ dpkg --admindir $vardir --$updatetype-avail "$packagesfile"
updatetype=merge
;;
esac
while [ -z "$goconfigure" ]
do
- yet="`dpkg --yet-to-unpack`"
+ yet="`dpkg --admindir $vardir --yet-to-unpack`"
if [ -z "$yet" ]
then
echo '
if mount -rt "$defaultfstype" "$defaultfloppy" "$mountpoint"
then
echo
- dpkg --unpack -GROEB "$mountpoint" || true
+ dpkg --admindir $vardir --unpack -GROEB "$mountpoint" || true
umount "$defaultfloppy"
fi
umount=""
done
fi
-dpkg --configure --pending
+dpkg --admindir $vardir --configure --pending
xit=0
echo "$mountpoint/Packages does not exist.";
return
fi
- if dpkg --merge-avail "$mountpoint/Packages"
+ if dpkg --admindir $vardir --merge-avail "$mountpoint/Packages"
then
success=1
echo '
# You should have received a copy of the GNU General Public
# License along with this script; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
+$vardir = $ARGV[0];
print "Is the partition to install from mounted? [Y] ";
$ans = <STDIN>;
if ($ans =~ /^[Nn]/) {
# Assumedly, the drive is now mounted
-open (STATUS, ">/var/lib/dpkg/methods/hd/hd.status") || die "Can't open hd.status";
+open (STATUS, ">$vardir/methods/hd/hd.status") || die "Can't open hd.status";
do {
print "What is the full path to the 'available' file?\n";
print "This file is found as Packages on the ftp site and CDROM";
# Return associative array of fields from control file $file.
+$vardir = $ARGV[0];
sub slurp
{
local ($file) = @_;
return %ci;
}
-$file = "/var/lib/dpkg/methods/hd/hd.status";
+$file = "$vardir/methods/hd/hd.status";
%info = slurp($file);
-$dpkg = "dpkg --auto --unpack --no-auto-select ";
+$dpkg = "dpkg --admindir $vardir --auto --unpack --no-auto-select ";
$dpkg .= "--refuse downgrade --skip-same-version";
system("$dpkg $info{'debdir'}");
# Return associative array of fields from control file $file.
+$vardir = $ARGV[0];
sub slurp
{
local ($file) = @_;
return %ci;
}
-$file = "/var/lib/dpkg/methods/hd/hd.status";
+$file = "$vardir/methods/hd/hd.status";
%info = slurp($file);
open (IN, "<$info{'avail'}") || die "can't open $info{'avail'}";
-open (OUT, ">/var/lib/dpkg/available") || die "can't open /var/lib/dpkg/available";
+open (OUT, ">$vardir/available") || die "can't open $vardir/available";
print OUT while (<IN>);
close IN;
close OUT;