From 5f4495e342e94a75b17ceed2fa05d689f050df7b Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Mon, 10 Aug 2015 16:08:21 +0200 Subject: move manual-bit from 'oldlibs' pkg to its dependencies MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit oldlibs used to be in APT::Never-MarkAuto-Sections so that old transition packages can be removed without causing the then (autoinstalled) renamed package to be autoremoved. It isn't ideal through as ideally you want the oldlibs package to be removed after nothing depends on it anymore regardless of if you have once installed it by hand or not – and if you had the package talking over (the dependencies) should carry the manual bit now as they are the real deal now. As an added bonus if the package has no dependencies because it is an oldlibs without a direct replacement you should move away from (like lib1 and lib2 are currently in the archive, but there will hopefully only be lib2 in the release) you get a lib1 marked as auto. If the user still needs the oldlibs package for some reason all he has to do is mark it as manual once as this move is only performed if a installed package changes its section from a not-Move-Autobit-Sections to a Move-Autobit-Sections. --- .../test-apt-move-and-forget-manual-sections | 31 ++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100755 test/integration/test-apt-move-and-forget-manual-sections (limited to 'test/integration/test-apt-move-and-forget-manual-sections') diff --git a/test/integration/test-apt-move-and-forget-manual-sections b/test/integration/test-apt-move-and-forget-manual-sections new file mode 100755 index 000000000..845444f53 --- /dev/null +++ b/test/integration/test-apt-move-and-forget-manual-sections @@ -0,0 +1,31 @@ +#!/bin/sh +set -e + +TESTDIR=$(readlink -f $(dirname $0)) +. $TESTDIR/framework +setupenvironment +configarchitecture 'amd64' + +aptconfig dump --no-empty --format '%v%n' APT::Move-Autobit-Sections > move-autobit.sections +testsuccess grep '^oldlibs$' move-autobit.sections + +buildsimplenativepackage 'libabc' 'amd64' '1' 'stable' '' '' 'libs' +buildsimplenativepackage 'libabc' 'amd64' '2' 'unstable' 'Depends: libdef' '' 'oldlibs' +buildsimplenativepackage 'libdef' 'amd64' '1' 'unstable' '' '' 'libs' +setupaptarchive + +testmarkedauto +testmarkedmanual + +testsuccess aptget install libabc/stable -y +testdpkginstalled 'libabc' +testdpkgnotinstalled 'libdef' + +testmarkedmanual 'libabc' +testmarkedauto + +testsuccess aptget dist-upgrade -y +testdpkginstalled 'libabc' 'libdef' + +testmarkedauto 'libabc' +testmarkedmanual 'libdef' -- cgit v1.2.3